<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic wsse:InvalidSecurity in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376639#M184546</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have tried to implement a small PHP script for submitting ideas to xPD 2.0. First phase is successful (idea is submitted and guid retrieved). But when I try to upload an attachent using different webservice I get this error message:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;wsse:InvalidSecurity. 00E000C4EA35007A0000035700001077000412CCC9797F64 : WS Security can only be applied on a SOAP document.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas why my second soap call is failing?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here are both scripts for you:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;submit.php (this works)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[code]&lt;/P&gt;&lt;P&gt;&amp;lt;?php&lt;/P&gt;&lt;P&gt;$title       = $_POST['title'];&lt;/P&gt;&lt;P&gt;$description = $_POST['description'];&lt;/P&gt;&lt;P&gt;$source      = $_POST['source'];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$client = new SoapClient('our_server/WSxPDService/WSxPDServiceConfig?wsdl', &lt;/P&gt;&lt;P&gt;                          array('login' =&amp;gt; "xxx", 'password' =&amp;gt; "xxx", 'style'    =&amp;gt; SOAP_DOCUMENT));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$header = array("description"     =&amp;gt; $description,&lt;/P&gt;&lt;P&gt;                "owner"           =&amp;gt; "xxx",&lt;/P&gt;&lt;P&gt;                "title"           =&amp;gt; $title,&lt;/P&gt;&lt;P&gt;                "guid"            =&amp;gt; "",&lt;/P&gt;&lt;P&gt;                "source"          =&amp;gt; $source,&lt;/P&gt;&lt;P&gt;                "author"          =&amp;gt; "xxx",&lt;/P&gt;&lt;P&gt;                "protectionLevel" =&amp;gt; "Normal",&lt;/P&gt;&lt;P&gt;                "relatedInsights" =&amp;gt; "",&lt;/P&gt;&lt;P&gt;                "relatedFacts"    =&amp;gt; ""&lt;/P&gt;&lt;P&gt;           );&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $result = $client-&amp;gt;createIdea(array("header" =&amp;gt; $header));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;} catch (SoapFault $exception) {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       die("&amp;lt;b&amp;gt;Idea submission failed!&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;" . $exception-&amp;gt;content);&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$guid = $result-&amp;gt;Response;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;include("attachment.inc");&lt;/P&gt;&lt;P&gt;?&amp;gt;&lt;/P&gt;&lt;P&gt;[/code]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;submitAttachment.php (this does not work)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[code]&lt;/P&gt;&lt;P&gt;&amp;lt;?php&lt;/P&gt;&lt;P&gt;$guid       = $_POST['guid'];&lt;/P&gt;&lt;P&gt;$name       = $_POST['name'];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$attachment = $_FILES['attachment']['tmp_name'];&lt;/P&gt;&lt;P&gt;$contents   = file_get_contents($attachment); &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$client = new SoapClient('our_server/WSxPDExternalIdeaAttachment/EIAttachmentConfig?wsdl ', array('login' =&amp;gt; "xxx", 'password' =&amp;gt; "xxx"));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $result = @$client-&amp;gt;addIdeaAttachment( $guid, $name, $contents );&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;} catch (SoapFault $exception) {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       die("&amp;lt;b&amp;gt;Attachment upload failed!&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;" . $exception-&amp;gt;faultcode . ". " . $exception-&amp;gt;faultstring . "&amp;lt;br&amp;gt;&amp;lt;b&amp;gt;" . var_dump($exception));&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Header("Location: addAttachments.php?guid=$guid");&lt;/P&gt;&lt;P&gt;exit;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;?&amp;gt;&lt;/P&gt;&lt;P&gt;[/code]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Br,&lt;/P&gt;&lt;P&gt;Johannes&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 02 May 2006 12:50:04 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-05-02T12:50:04Z</dc:date>
    <item>
      <title>wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376639#M184546</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have tried to implement a small PHP script for submitting ideas to xPD 2.0. First phase is successful (idea is submitted and guid retrieved). But when I try to upload an attachent using different webservice I get this error message:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;wsse:InvalidSecurity. 00E000C4EA35007A0000035700001077000412CCC9797F64 : WS Security can only be applied on a SOAP document.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas why my second soap call is failing?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here are both scripts for you:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;submit.php (this works)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[code]&lt;/P&gt;&lt;P&gt;&amp;lt;?php&lt;/P&gt;&lt;P&gt;$title       = $_POST['title'];&lt;/P&gt;&lt;P&gt;$description = $_POST['description'];&lt;/P&gt;&lt;P&gt;$source      = $_POST['source'];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$client = new SoapClient('our_server/WSxPDService/WSxPDServiceConfig?wsdl', &lt;/P&gt;&lt;P&gt;                          array('login' =&amp;gt; "xxx", 'password' =&amp;gt; "xxx", 'style'    =&amp;gt; SOAP_DOCUMENT));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$header = array("description"     =&amp;gt; $description,&lt;/P&gt;&lt;P&gt;                "owner"           =&amp;gt; "xxx",&lt;/P&gt;&lt;P&gt;                "title"           =&amp;gt; $title,&lt;/P&gt;&lt;P&gt;                "guid"            =&amp;gt; "",&lt;/P&gt;&lt;P&gt;                "source"          =&amp;gt; $source,&lt;/P&gt;&lt;P&gt;                "author"          =&amp;gt; "xxx",&lt;/P&gt;&lt;P&gt;                "protectionLevel" =&amp;gt; "Normal",&lt;/P&gt;&lt;P&gt;                "relatedInsights" =&amp;gt; "",&lt;/P&gt;&lt;P&gt;                "relatedFacts"    =&amp;gt; ""&lt;/P&gt;&lt;P&gt;           );&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $result = $client-&amp;gt;createIdea(array("header" =&amp;gt; $header));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;} catch (SoapFault $exception) {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       die("&amp;lt;b&amp;gt;Idea submission failed!&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;" . $exception-&amp;gt;content);&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$guid = $result-&amp;gt;Response;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;include("attachment.inc");&lt;/P&gt;&lt;P&gt;?&amp;gt;&lt;/P&gt;&lt;P&gt;[/code]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;submitAttachment.php (this does not work)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[code]&lt;/P&gt;&lt;P&gt;&amp;lt;?php&lt;/P&gt;&lt;P&gt;$guid       = $_POST['guid'];&lt;/P&gt;&lt;P&gt;$name       = $_POST['name'];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$attachment = $_FILES['attachment']['tmp_name'];&lt;/P&gt;&lt;P&gt;$contents   = file_get_contents($attachment); &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$client = new SoapClient('our_server/WSxPDExternalIdeaAttachment/EIAttachmentConfig?wsdl ', array('login' =&amp;gt; "xxx", 'password' =&amp;gt; "xxx"));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $result = @$client-&amp;gt;addIdeaAttachment( $guid, $name, $contents );&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;} catch (SoapFault $exception) {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;       die("&amp;lt;b&amp;gt;Attachment upload failed!&amp;lt;/b&amp;gt;&amp;lt;br&amp;gt;" . $exception-&amp;gt;faultcode . ". " . $exception-&amp;gt;faultstring . "&amp;lt;br&amp;gt;&amp;lt;b&amp;gt;" . var_dump($exception));&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Header("Location: addAttachments.php?guid=$guid");&lt;/P&gt;&lt;P&gt;exit;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;?&amp;gt;&lt;/P&gt;&lt;P&gt;[/code]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Br,&lt;/P&gt;&lt;P&gt;Johannes&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 May 2006 12:50:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376639#M184546</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-02T12:50:04Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376640#M184547</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Johannes,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;could you tell us a bit more about your system landscape? What exct version of PHP and WebAS are you running on including Service Packs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Gregor&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 02 May 2006 20:36:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376640#M184547</guid>
      <dc:creator>gregorw</dc:creator>
      <dc:date>2006-05-02T20:36:42Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376641#M184548</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Gregor,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PHP version is 5.1.2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We are running on Web AS Java 7.00 SP 5 (Ramp-Up product)with Portal 7.00 and xPD 2.0 SP1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First I thought this could be some kind of authrorization thing but those settings should be similar to the service which is working.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's the soap request which is sent to the webservice.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;?xml version="1.0" encoding="UTF-8"?&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;SOAP-ENV:Body&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;SOAP-ENV:addIdeaAttachment&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;ideaGuid&amp;gt;d0cc4480-da69-11da-be20-00e000c4ea35&amp;lt;/ideaGuid&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;name&amp;gt;debug_settings.jpg&amp;lt;/name&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;content&amp;gt;/9j/4AAQ... //skip rest of content // ...AL1FFFAH/2Q==&amp;lt;/content&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/SOAP-ENV:addIdeaAttachment&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/SOAP-ENV:Body&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/SOAP-ENV:Envelope&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Br,&lt;/P&gt;&lt;P&gt;Johannes&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 May 2006 06:07:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376641#M184548</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-03T06:07:15Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376642#M184549</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the WSDL would be helpful as well. does the WSDL define style as 'document'?&lt;/P&gt;&lt;P&gt;i suppose there is a style problem. maybe the WSDL says rpc, or it's just the style = SOAP_DOCUMENT declararion missing in the constructor of your client.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;anton&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 May 2006 07:27:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376642#M184549</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-03T07:27:48Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376643#M184550</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Anton,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There's only one style called 'mime' available. Then there's standard and SAP version of that. I have tried both.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried to change the constructor like this (no success):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[code]&lt;/P&gt;&lt;P&gt;$client = new SoapClient('http://xxxx:50200/WSxPDExternalIdeaAttachment/EIAttachmentConfig?wsdl', &lt;/P&gt;&lt;P&gt;array('login' =&amp;gt; "xxx", 'password' =&amp;gt; "xxx", "style" =&amp;gt; 'mime'));&lt;/P&gt;&lt;P&gt;[/code]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's the standard wsdl for you:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;!--            Generated by WSDLDefinitionsParser    --&amp;gt;&amp;lt;wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" name="WSxPDExternalIdeaAttachmentWsd" targetNamespace="urn:WSxPDExternalIdeaAttachmentWsd" xmlns:bns0="urn:WSxPDExternalIdeaAttachmentWsd/EIAttachmentConfig/mime" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:import location="./bindings/EIAttachmentConfig_mime.wsdl" namespace="urn:WSxPDExternalIdeaAttachmentWsd/EIAttachmentConfig/mime"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:service name="WSxPDExternalIdeaAttachment"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:port name="EIAttachmentConfigPort_Mime" binding="bns0:EIAttachmentConfigBinding"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;soap:address location="http://xxxx:50200/WSxPDExternalIdeaAttachment/EIAttachmentConfig?style=mime"/&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/wsdl:port&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:service&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/wsdl:definitions&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bindings:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;!--            Generated by WSDLDefinitionsParser    --&amp;gt;&amp;lt;wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="urn:WSxPDExternalIdeaAttachmentWsd/EIAttachmentConfig/mime" xmlns:prt0="urn:WSxPDExternalIdeaAttachmentWsd/WSxPDExternalIdeaAttachmentVi/rpc_enc" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/"&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:import location="../porttypes/EIAttachmentConfig_WSxPDExternalIdeaAttachmentVi_rpc_enc.wsdl" namespace="urn:WSxPDExternalIdeaAttachmentWsd/WSxPDExternalIdeaAttachmentVi/rpc_enc"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:binding name="EIAttachmentConfigBinding" type="prt0:WSxPDExternalIdeaAttachmentVi_Rpc_enc"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="rpc"/&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:operation name="addIdeaAttachment"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;soap:operation soapAction=""/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:input&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;soap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:WSxPDExternalIdeaAttachmentVi"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;/mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;mime:content part="content" type="application/octetstream"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;/mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/wsdl:input&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:output&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;soap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:WSxPDExternalIdeaAttachmentVi"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;/mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/wsdl:output&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:fault name="com.sap.xapps.xpd.webservices.exception.BOCreateException"&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;soap:fault use="encoded" name="com.sap.xapps.xpd.webservices.exception.BOCreateException" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/wsdl:fault&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/wsdl:operation&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:operation name="getIdeaCategories"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;soap:operation soapAction=""/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:input&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;soap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:WSxPDExternalIdeaAttachmentVi"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/wsdl:input&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:output&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;soap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:WSxPDExternalIdeaAttachmentVi"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;/mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/wsdl:output&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/wsdl:operation&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:operation name="submitIdea"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;soap:operation soapAction=""/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:input&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;soap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:WSxPDExternalIdeaAttachmentVi"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;/mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/wsdl:input&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:output&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;soap:body use="encoded" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:WSxPDExternalIdeaAttachmentVi"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;/mime:part&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/mime:multipartRelated&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/wsdl:output&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:fault name="com.sap.xapps.xpd.webservices.exception.BOCreateException"&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;soap:fault use="encoded" name="com.sap.xapps.xpd.webservices.exception.BOCreateException" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/wsdl:fault&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/wsdl:operation&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:binding&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/wsdl:definitions&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Porttypes:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;!--            Generated by WSDLDefinitionsParser    --&amp;gt;&amp;lt;wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:ns1="urn:com.sap.xapps.xpd.webservices.exception" xmlns:ns0="http://www.w3.org/2001/XMLSchema" xmlns:ns3="urn:com.sap.xapps.xpd.webservices.data" targetNamespace="urn:WSxPDExternalIdeaAttachmentWsd/WSxPDExternalIdeaAttachmentVi/rpc_enc" xmlns:tns="urn:WSxPDExternalIdeaAttachmentWsd/WSxPDExternalIdeaAttachmentVi/rpc_enc" xmlns:ns2="urn:java/lang"&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:types&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:java/lang" xmlns:tns="urn:java/lang" elementFormDefault="qualified"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;xs:complexType name="ArrayOfString"&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;xs:complexContent&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:restriction xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" base="soapenc:Array"&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;xs:attribute ref="soapenc:arrayType" wsdl:arrayType="xs:string[]" nillable="true"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;/xs:restriction&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/xs:complexContent&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/xs:complexType&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/xs:schema&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:com.sap.xapps.xpd.webservices.exception" xmlns:tns="urn:com.sap.xapps.xpd.webservices.exception" elementFormDefault="qualified"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;xs:complexType name="BOCreateException"&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;xs:sequence&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="message" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/xs:sequence&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/xs:complexType&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/xs:schema&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="urn:com.sap.xapps.xpd.webservices.data" xmlns:tns="urn:com.sap.xapps.xpd.webservices.data" elementFormDefault="qualified" xmlns:s0="urn:java/lang"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;xs:import namespace="urn:java/lang"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;xs:complexType name="ExternalIdea"&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;xs:sequence&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="title" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="description" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="classification" type="s0:ArrayOfString" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="externalAuthor" type="tns:ExternalAuthor" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/xs:sequence&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/xs:complexType&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;xs:complexType name="ExternalAuthor"&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;xs:sequence&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="name" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="email" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="phone" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="country" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="zip" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="state" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="city" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;          &amp;lt;xs:element name="street" type="xs:string" nillable="true" minOccurs="0"/&amp;gt;&lt;/P&gt;&lt;P&gt;        &amp;lt;/xs:sequence&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;/xs:complexType&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/xs:schema&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:types&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:message name="addIdeaAttachmentIn"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="ideaGuid" type="ns0:string"/&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="name" type="ns0:string"/&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="content" type="ns0:base64Binary"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:message&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:message name="addIdeaAttachmentOut"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="Response" type="ns0:boolean"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:message&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:message name="addIdeaAttachment_com.sap.xapps.xpd.webservices.exception.BOCreateException"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="addIdeaAttachment_com.sap.xapps.xpd.webservices.exception.BOCreateException" type="ns1:BOCreateException"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:message&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:message name="getIdeaCategoriesIn"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:message name="getIdeaCategoriesOut"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="Response" type="ns2:ArrayOfString"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:message&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:message name="submitIdeaIn"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="idea" type="ns3:ExternalIdea"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:message&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:message name="submitIdeaOut"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="Response" type="ns0:string"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:message&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:message name="submitIdea_com.sap.xapps.xpd.webservices.exception.BOCreateException"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:part name="submitIdea_com.sap.xapps.xpd.webservices.exception.BOCreateException" type="ns1:BOCreateException"/&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:message&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;wsdl:portType name="WSxPDExternalIdeaAttachmentVi_Rpc_enc"&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:operation name="addIdeaAttachment"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:input message="tns:addIdeaAttachmentIn"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:output message="tns:addIdeaAttachmentOut"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:fault name="com.sap.xapps.xpd.webservices.exception.BOCreateException" message="tns:addIdeaAttachment_com.sap.xapps.xpd.webservices.exception.BOCreateException"/&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/wsdl:operation&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:operation name="getIdeaCategories"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:input message="tns:getIdeaCategoriesIn"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:output message="tns:getIdeaCategoriesOut"/&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/wsdl:operation&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;wsdl:operation name="submitIdea"&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:input message="tns:submitIdeaIn"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:output message="tns:submitIdeaOut"/&amp;gt;&lt;/P&gt;&lt;P&gt;      &amp;lt;wsdl:fault name="com.sap.xapps.xpd.webservices.exception.BOCreateException" message="tns:submitIdea_com.sap.xapps.xpd.webservices.exception.BOCreateException"/&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;/wsdl:operation&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/wsdl:portType&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/wsdl:definitions&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Br,&lt;/P&gt;&lt;P&gt;Johannes&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Johannes Mitronen&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 May 2006 08:12:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376643#M184550</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-03T08:12:28Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376644#M184551</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I thought your error message refrred to the SOAP style property which is either DOCUMENT or RPC. E.g. your SOAP message is of RPC style. But that doesn't seem to be the problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Maybe the problem is that NW doesn't support WS Security for SOAP with attachments (see &amp;lt;a href="http://help.sap.com/saphelp_erp2005/helpdata/en/31/a6d13f83a14d21e10000000a1550b0/content.htm"&amp;gt;help.sap.com&amp;lt;/a&amp;gt;)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Client and server platform needed to implement the standard WSA 1.1 (see &amp;lt;a href="http://www.oasis-open.org/committees/download.php/16672/wss-v1.1-spec-os-SwAProfile.pdf"&amp;gt;this&amp;lt;/a&amp;gt;) which was only approved on Feb. 1st, 2006)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I wish some of the dev people of SAP peeked into our discussions more frequently to clarify actual problems which are hard to judge by us users by trial and error only.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;anton&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 May 2006 09:05:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376644#M184551</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-03T09:05:51Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376645#M184552</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Anton,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did some further investigation under this issue. I decided to try to send raw request directly to server without using SoapClient class.  I changed the script as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[code]&lt;/P&gt;&lt;P&gt;&amp;lt;?php&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$guid       = $_POST['guid'];&lt;/P&gt;&lt;P&gt;$name       = $_POST['name'];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;$attachment   = $_FILES['attachment']['tmp_name'];&lt;/P&gt;&lt;P&gt;$contents   = file_get_contents($attachment); &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;server&lt;/P&gt;&lt;P&gt;$fp = fsockopen("www.foo.bar", 50200, $errno, $errstr, 30);&lt;/P&gt;&lt;P&gt;if (!$fp) {&lt;/P&gt;&lt;P&gt;   echo "$errstr ($errno)&amp;lt;br /&amp;gt;\n";&lt;/P&gt;&lt;P&gt;} else {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $boundary = "MIME_boundary";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $msg  = "--$boundary\r\n";   &lt;/P&gt;&lt;P&gt;   $msg .= "Content-type: text/xml; charser=UFT-8\r\n";&lt;/P&gt;&lt;P&gt;   $msg .= "Content-Transfer-Encoding: 8bit\r\n";&lt;/P&gt;&lt;P&gt;   $msg .= "Content-ID: &amp;lt;" . $hash . "xml&amp;gt;\r\n\r\n";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $msg .= "&amp;lt;?xml version=\"1.0\" ?&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;SOAP-ENV:Envelope xmlns:SOAP-ENV=\"http://schemas.xmlsoap.org/soap/envelope/\"&lt;/P&gt;&lt;P&gt;             xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"&lt;/P&gt;&lt;P&gt;            xmlns:xs=\"http://www.w3.org/2001/XMLSchema\"&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;SOAP-ENV:Body SOAP-ENV:encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'&amp;gt; &lt;/P&gt;&lt;P&gt;            &amp;lt;ns1:addIdeaAttachment xmlns:ns1='urn:WSxPDExternalIdeaAttachmentVi'&amp;gt; &lt;/P&gt;&lt;P&gt;            &amp;lt;ideaGuid xsi:type='xs:string'&amp;gt;$guid&amp;lt;/ideaGuid&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;name xsi:type='xs:string'&amp;gt;$name&amp;lt;/name&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;content href='cid:" . $hash . "attachment'&amp;gt;&amp;lt;/content&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;/ns1:addIdeaAttachment&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;/SOAP-ENV:Body&amp;gt;&lt;/P&gt;&lt;P&gt;            &amp;lt;/SOAP-ENV:Envelope&amp;gt;\r\n\r\n";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $msg .= "--$boundary\r\n";    &lt;/P&gt;&lt;P&gt;   $msg .= "Content-type: application/octetstream\r\n";&lt;/P&gt;&lt;P&gt;   $msg .= "Content-Transfer-Encoding: binary\r\n";&lt;/P&gt;&lt;P&gt;   $msg .= "Content-ID: &amp;lt;" . $hash . "attachment&amp;gt;\r\n\r\n";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $msg .= "$contents\r\n";&lt;/P&gt;&lt;P&gt;   $msg .= "&lt;DEL&gt;$boundary&lt;/DEL&gt;";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $length = strlen($msg); &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $head  = "POST /WSxPDExternalIdeaAttachment/EIAttachmentConfig?style=mime HTTP/1.1\r\n";&lt;/P&gt;&lt;P&gt;   $head .= "Host: &lt;A href="www.foo.bar:50200\r\n&amp;quot;" target="test_blank"&gt;www.foo.bar:50200\r\n"&lt;/A&gt;;&lt;/P&gt;&lt;P&gt;   $head .= "Content-Type: multipart/related; type=text/xml; boundary=$boundary\r\n";&lt;/P&gt;&lt;P&gt;   $head .= "Connection: close\r\n";&lt;/P&gt;&lt;P&gt;   $head .= "Authorization: Basic " . base64_encode("xxx:xxx") . "\r\n";&lt;/P&gt;&lt;P&gt;   $head .= "Content-Length: $length\r\n";&lt;/P&gt;&lt;P&gt;   $head .= "SOAPAction: \"\"\r\n";&lt;/P&gt;&lt;P&gt;   $head .= "\r\n";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   $out = $head . $msg;&lt;/P&gt;&lt;P&gt;   &lt;/P&gt;&lt;P&gt;   fwrite($fp, $out);&lt;/P&gt;&lt;P&gt;   while (!feof($fp)) {&lt;/P&gt;&lt;P&gt;       echo fgets($fp, 128);&lt;/P&gt;&lt;P&gt;   }&lt;/P&gt;&lt;P&gt;   fclose($fp);&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;?&amp;gt;&lt;/P&gt;&lt;P&gt;[/code]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now the message which is sent to the server looks like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;POST /WSxPDExternalIdeaAttachment/EIAttachmentConfig?style=mime HTTP/1.1&lt;/P&gt;&lt;P&gt;Host: &lt;A href="www.foo.bar:50200" target="test_blank"&gt;www.foo.bar:50200&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Content-Type: multipart/related; type=text/xml; boundary=MIME_boundary&lt;/P&gt;&lt;P&gt;Connection: close&lt;/P&gt;&lt;P&gt;Authorization: Basic eHBkX2lkZWE6eHBkX2lkZWE=&lt;/P&gt;&lt;P&gt;Content-Length: 967&lt;/P&gt;&lt;P&gt;SOAPAction: ""&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--MIME_boundary&lt;/P&gt;&lt;P&gt;Content-type: text/xml; charser=UFT-8&lt;/P&gt;&lt;P&gt;Content-Transfer-Encoding: 8bit&lt;/P&gt;&lt;P&gt;Content-ID: &amp;lt;9dd3ecb681xml&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;?xml version="1.0" ?&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xs="http://www.w3.org/2001/XMLSchema"&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;SOAP-ENV:Body SOAP-ENV:encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;ns1:addIdeaAttachment xmlns:ns1='urn:WSxPDExternalIdeaAttachmentVi'&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;ideaGuid xsi:type='xs:string'&amp;gt;ae85b9f0-db5a-11da-a2b2-00e000c4ea35&amp;lt;/ideaGuid&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;name xsi:type='xs:string'&amp;gt;nootit.txt&amp;lt;/name&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;content href='cid:9dd3ecb681attachment'&amp;gt;&amp;lt;/content&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/ns1:addIdeaAttachment&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/SOAP-ENV:Body&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/SOAP-ENV:Envelope&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--MIME_boundary&lt;/P&gt;&lt;P&gt;Content-type: application/octetstream&lt;/P&gt;&lt;P&gt;Content-Transfer-Encoding: binary&lt;/P&gt;&lt;P&gt;Content-ID: &amp;lt;9dd3ecb681attachment&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;...file content... &lt;/P&gt;&lt;P&gt;&lt;DEL&gt;MIME_boundary&lt;/DEL&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I'm getting this response back:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTTP/1.1 200 OK&lt;/P&gt;&lt;P&gt;Connection: close&lt;/P&gt;&lt;P&gt;Set-Cookie: JSESSIONID=(J2EE23521500)ID0020989350DB22113200698559606145End; Version=1; Domain=.foo.bar; Path=/&lt;/P&gt;&lt;P&gt;Set-Cookie: saplb_*=(J2EE23521500)23521550; Version=1; Path=/&lt;/P&gt;&lt;P&gt;Server: SAP J2EE Engine/7.00&lt;/P&gt;&lt;P&gt;Content-Type: text/xml; charset=UTF-8&lt;/P&gt;&lt;P&gt;Date: Thu, 04 May 2006 10:44:35 GMT&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" &amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;SOAP-ENV:Body&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;rpl:addIdeaAttachmentResponse xmlns:rpl='urn:WSxPDExternalIdeaAttachmentVi'&amp;gt;&lt;/P&gt;&lt;P&gt;    &amp;lt;rpl:Response SOAP-ENV:encodingStyle='http://schemas.xmlsoap.org/soap/encoding/' xsi:type='xs:boolean'&amp;gt;true&amp;lt;/rpl:Response&amp;gt;&lt;/P&gt;&lt;P&gt;  &amp;lt;/rpl:addIdeaAttachmentResponse&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/SOAP-ENV:Body&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/SOAP-ENV:Envelope&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Looks fine but oly problem is that the attachment is not found when I open the corresponding idea on xPD. J2EE logs doesn't show anything suspicious...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any ideas why this could happen? One thing which comes to my mind is that I'm submitting the idea in the first phase using webservice WSxPDService and then I'm calling a different service WSxPDExternalIdeaAttachment to upload attachments. Does this make any sense to you?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Br,&lt;/P&gt;&lt;P&gt;Johannes&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Johannes Mitronen&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 May 2006 11:15:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376645#M184552</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-04T11:15:35Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376646#M184553</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;maybe it's just that your mime boundary declaration is wrong?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Content Type: [...] boundary="MIME_boundary"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;whereas the real boundary is&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--MIME_boundary&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'll look into it deeper a little later.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;anton&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 May 2006 13:45:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376646#M184553</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-04T13:45:48Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376647#M184554</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Anton,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;mime boundary should be fine. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did some more testing. It seems that when I test this webservice on Web Service Navigator it does not work either (same result, no attachment found).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will open a customer message. Thank you for your help!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Br,&lt;/P&gt;&lt;P&gt;Johannes&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 May 2006 06:39:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376647#M184554</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-05-05T06:39:02Z</dc:date>
    </item>
    <item>
      <title>Re: wsse:InvalidSecurity</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376648#M184555</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Johannes, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;have you been able to clarify the InvalidSecurity issue? &lt;/P&gt;&lt;P&gt;If yes, how? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I´m facing the same Problem with the message "WS Security can only be applied on a SOAP document" although security profile "None" is applied to the webservice. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Gabi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 Aug 2007 10:30:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/wsse-invalidsecurity/m-p/1376648#M184555</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-08-13T10:30:58Z</dc:date>
    </item>
  </channel>
</rss>

