webMethods

webMethods

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

Getting "Connection Reset" error instead of 401 on multipart HTTP

  • 1.  Getting "Connection Reset" error instead of 401 on multipart HTTP

    Posted Fri August 23, 2024 07:43 AM

    10.15

    Hi,

    I am making a multipart HTTP call with a Bearer Token. When I use the right token I don’t have any problems. I can send a pdf file with that call.

    My problems start if I use the wrong Bearer Token. Everything works normally if I send a request with the wrong Token via Postman. I can see the HTTP code as 401, the response as JSON, and also header values without an issue.

    When I make the same request from 10.15 webMethods server via “pub.client:http” it throws “com.wm.net.NetException: [ISC.0064.9306] Connection was closed during read” or “com.wm.app.b2b.server.ServiceException: java.net.SocketException: Connection reset” error.

    I changed the log level to “Trace” for Integration Server and attached the related piece of logs here.
    server.log (11.1 KB)

    As I understand from the logs, I am getting 401 in the first place but then the webMethods server makes another call, this time it uses NTLM for authorization then it gets 401 again but this time I see WWW-Authenticate: NTLM in the response header and probably it causes the issue.

    I am unsure why it retries after it gets 401 and where this NTLM is coming from. I can provide further info if needed.

    Are there any suggestions to solve this?

    Many thanks in advance.


    #API-Management
    #Integration-Server-and-ESB
    #Service-Designer
    #webMethods
    #Adapters-and-E-Standards
    #B2B-Integration


  • 2.  RE: Getting "Connection Reset" error instead of 401 on multipart HTTP

    Posted Fri August 23, 2024 03:16 PM

    Your query is not pretty clear, but check out this setting if it makes some difference.

    watt.net.http401.retryWithoutCookie

    Controls whether Integration Server retries HTTP requests without a cookie header. Set the parameter to false to prevent the pub.client:http service from retrying a request without a cookie header when Integration Server receives HTTP 401 as the response. The default is true.

    Note:
    The watt.net.http401.retryWithoutCookie parameter is introduced for PIE-76895 in IS_10.15_Core_Fix1.


    #Adapters-and-E-Standards
    #B2B-Integration
    #Integration-Server-and-ESB
    #Service-Designer
    #API-Management
    #webMethods


  • 3.  RE: Getting "Connection Reset" error instead of 401 on multipart HTTP

    Posted Mon August 26, 2024 07:26 AM

    Hi Sandeep,

    Thanks for your answer. I set “watt.net.http401.retryWithoutCookie” as false but the result is the same. I also set false to " watt.net.http401.throwException" to disable getting exceptions after I got 401 but it also didn’t help.

    Regards,
    Mustafa


    #API-Management
    #webMethods
    #Service-Designer
    #Adapters-and-E-Standards
    #Integration-Server-and-ESB
    #B2B-Integration


  • 4.  RE: Getting "Connection Reset" error instead of 401 on multipart HTTP

    Posted Wed September 25, 2024 02:21 PM

    service: pub.client:http has parameter of: followRedirect
    try to use no when you call it.


    #webMethods
    #Integration-Server-and-ESB
    #Service-Designer
    #API-Management
    #Adapters-and-E-Standards
    #B2B-Integration