5 Replies Latest reply on Oct 17, 2018 2:41 AM by Ranganath Samudrala

    BAO : REST Adapter : Unable to use Secure Variable

    Sanket Mhatre
      Share This:

      Hi,

       

      I am using BAO REST Adapter 20.17.01.00, and in that , I need to use below Header for basic authentication.

      {

         "headers": {

            "authorization": {

               "type": "basic",

               "user-name": "XXX",

               "password": "<Secure password from Module Configuration>"

            }

         }

      }

       

      I am using above Header structure in the Header section of  :AutoPilot-AD-Utilities:REST:Post , however, if I provide password as a from secure module configuration item, then it gives an error as

      [adapter response=

      <rest-adapter-response>

        <metadata>

        <status>error</status>

        </metadata>

        <status-line>

        <code>10000</code>

        <reason>Message[summary={0} : Invalid data found in the REST request. Failed to process the request., detail=javax.xml.bind.UnmarshalException - with linked exception: [Exception [EclipseLink-25004] (Eclipse Persistence Services - 2.5.0.v20130507-3faac2b): org.eclipse.persistence.exceptions.XMLMarshalException Exception Description: An error occurred unmarshalling the document Internal Exception: MissingTokenException(inserted [@-1,0:0='<missing ':'>',<23>,1:228] at "http://www.w3.org/2001/04/xmlenc#Content")]]</reason>

        </status-line>

      </rest-adapter-response>

       

       

      Can someone please help , if I am doing something incorrect?

       

      Thanks,

      Sanket