[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Ftpapi] Fwd: HTTP API Question



Hi Julius/Thomas,

Finally we figured out that there is an issue with the user name which is not having adequate authority. So it's failing. 

Thank you for your inputs. 

Regards,
Vino.

On Thu, May 24, 2018 at 7:27 AM, Julius Kaj <Kaj.Julius@xxxxxx> wrote:

The X-Backside-Transport: FAIL FAIL response could indicate that there is an “XML firewall” involved and that the 401 error is not really correct.

https://stackoverflow.com/questions/37953782/what-does-x-backside-transport-header-do

 

 

It could simply mean that your XML syntax or your http headers aren’t correct. Perhaps you’re sending a SOAP 1.0 message and a SOAP 1.1 message is expected or something like that.

 

Fra: ftpapi-bounces@lists.scottklement.com [mailto:ftpapi-bounces@lists.scottklement.com] På vegne af Vino
Sendt: 24. maj 2018 01:14
Til: FTPAPI/HTTPAPI mailing list
Emne: Re: [Ftpapi] Fwd: HTTP API Question

 

Hi Scott/Thomas,

 

All the credentials are correct. Can i use special character "@" in the password. Still i am getting the error, 

 

recvresp(): entered

HTTP/1.1 401 Unauthorized

Content-Type: text/xml

WWW-Authenticate: Basic realm=login

X-Backside-Transport: FAIL FAIL

Connection: close

 

 

SetError() #13: HTTP/1.1 401 Unauthorized

recvresp(): end with 401

recvdoc parms: identity 0

interpret_auth(): entered

SetError() #36: This page requires a user-id & password

http_close(): entered

 

Thanks.

 

Regards,

Vino.

 

On Wed, May 23, 2018 at 10:50 AM, Vino <vinomails@xxxxxxxxx> wrote:

Hi Thomas,

 

Thanks a lot for the guidance. Find the below log. I feel that the authentication designed as Login. That may be the issue. I will check on that. 

 

 

recvresp(): entered

HTTP/1.1 401 Unauthorized

Content-Type: text/xml

WWW-Authenticate: Basic realm=login

X-Backside-Transport: FAIL FAIL

Connection: close

 

 

SetError() #13: HTTP/1.1 401 Unauthorized

recvresp(): end with 401

recvdoc parms: identity 0

interpret_auth(): entered

SetError() #36: This page requires a user-id & password

http_close(): entered

 

 

 

Regards,

Vino.

 

 

On Wed, May 23, 2018 at 1:55 AM, Amit Sharma <sharma.amit0904@xxxxxxxxx> wrote:

I was about say the same as what Thomas suggested. Turn on the debug mode in program before you do basic authentication. That will give you all the details.




On Wednesday, May 23, 2018, Thomas Raddatz <thomas.raddatz@xxxxxx> wrote:
> Vino,
>
>  
>
> in addition to Scott’s response I suggest to post a debug log, that we can see the http headers passed between the client and server.
>
>  
>
> If you cannot post a debug log, you can check the log by yourself like this:
>
>  
>
> Disable statement http_setauth(), enable the debug log with http_debug(*on: path_to_debug_log) and call the web service. Look for "HTTP/1.1 401 Unauthorized". A few lines below you should find the "WWW-Authenticate" header. That header is returned by the server to inform the client about the supported (required) authentication scheme. If the header is "WWW-Authenticate: Basic" then the server expects BASIC authentication.
>
>  
>
> POST /PMR/services/Namespaces HTTP/1.1
>
> Host: 10.214.128.57:8080
>
> User-Agent: http-api/1.38
>
> Content-Length: 1100
>
> Content-Type: text/xml; charset=utf-8
>
> SOAPAction:
>
>  
>
>  
>
> sendraw(): entered
>
> <?xml version="1.0" encoding="utf-8"?><soapenv:Envelope>...</soapenv:Envelope>
>
> recvresp(): entered
>
> HTTP/1.1 401 Unauthorized
>
> Server: Apache-Coyote/1.1
>
> WWW-Authenticate: Basic realm="Basic Authentication"
>
> Content-Type: text/html;charset=utf-8
>
> Content-Length: 954
>
> Date: Tue, 27 Feb 2018 13:32:10 GMT
>
>  
>
>  
>
> SetError() #13: HTTP/1.1 401 Unauthorized
>
> recvresp(): end with 401
>
> recvdoc parms: identity 954
>
> interpret_auth(): entered
>
> SetError() #36: This page requires a user-id & password
>
>  
>
> Enable statement http_setauth() and call the server again. Search the debug log for "Authorization: Basic". That is the header send by HTTP API to the server to authenticate the client. The string following "Authorization: Basic" is the user name and password concatenated by a colon and encoded to Base64. You can decode the Base64 string "RG9uYWxkOkR1Y2s=" at https://www.base64decode.org/ to see the user name and password. For example, "RG9uYWxkOkR1Y2s=" decodes to "Donald:Duck" where "Donald" is the user name and "Duck" the password.
>
>  
>
> POST /PMR/services/Namespaces HTTP/1.1
>
> Host: 10.214.128.57:8080
>
> User-Agent: http-api/1.38
>
> Content-Length: 1100
>
> Authorization: Basic RG9uYWxkOkR1Y2s=
>
> Content-Type: text/xml; charset=utf-8
>
>  
>
> Do the decoded user name and password match the values that you passed to http_setauth()?
>
>  
>
> Thomas.
>
>  
>
> Von: ftpapi-bounces@lists.scottklement.com [mailto:ftpapi-bounces@lists.scottklement.com] Im Auftrag von Vino
> Gesendet: Montag, 21. Mai 2018 19:39
> An: ftpapi@xxxxxxxxxxxxxxxxxxxxxx
> Betreff: [Ftpapi] Fwd: HTTP API Question
>
>  
>
> Hi Team,
>
>  
>
> I need to send SOAP request as a XML file to another server with basic authentication. I am little confused which procedures to use for authentication and send xml file. 
>
>  
>
> Please advise. 
>
>  
>
> Thanks.
>
>  
>
> Regards,
>
> Vino.
>
>  
>
> --
> IMPORTANT NOTICE:
> This email is confidential, may be legally privileged, and is for the intended recipient only. Access, disclosure, copying, distribution, or reliance on any of it by anyone else is prohibited and may be a criminal offence. Please delete if obtained in error and email confirmation to the sender.

--

Many Thanks,

Amit Sharma

0450201285

 

--
_______________________________________________
Ftpapi mailing list
Ftpapi@xxxxxxxxxxxxxxxxxxxxxx
http://scottklement.com/mailman/listinfo/ftpapi

 

 


--
_______________________________________________
Ftpapi mailing list
Ftpapi@xxxxxxxxxxxxxxxxxxxxxx
http://scottklement.com/mailman/listinfo/ftpapi


-- 
_______________________________________________
Ftpapi mailing list
Ftpapi@xxxxxxxxxxxxxxxxxxxxxx
http://scottklement.com/mailman/listinfo/ftpapi