Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-46031

URLTrigger plugin does not work with NTLM authentication using Username and Password

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • urltrigger-plugin
    • None

      If you have a proxy around your instance and use NTLM authentication with a username and password, the URL trigger plugin is unable to reach external URLs with the following stacktrace

      2017-07-17 11:36:00.823+0000 [id=619]   INFO    o.a.c.h.HttpMethodDirector#processProxyAuthChallenge: Failure authenticating with NTLM <any realm>@$PROXY_HOST
      2017-07-17 11:36:00.827+0000 [id=619]   WARNING o.j.lib.xtrigger.AbstractTrigger#reportError: Polling failed
      java.io.IOException: Stream closed
          at java.io.BufferedInputStream.getInIfOpen(BufferedInputStream.java:159)
          at java.io.BufferedInputStream.available(BufferedInputStream.java:410)
          at org.apache.commons.httpclient.ContentLengthInputStream.available(ContentLengthInputStream.java:213)
          at java.io.FilterInputStream.available(FilterInputStream.java:168)
          at org.apache.commons.httpclient.AutoCloseInputStream.available(AutoCloseInputStream.java:143)
          at java.io.BufferedInputStream.available(BufferedInputStream.java:410)
          at java.io.FilterInputStream.available(FilterInputStream.java:168)
          at com.sun.jersey.api.client.ClientResponse.hasEntity(ClientResponse.java:458)
      Caused: com.sun.jersey.api.client.ClientHandlerException
          at com.sun.jersey.api.client.ClientResponse.hasEntity(ClientResponse.java:469)
          at com.sun.jersey.client.apache.ApacheHttpClientHandler.handle(ApacheHttpClientHandler.java:182)
      Caused: com.sun.jersey.api.client.ClientHandlerException
          at com.sun.jersey.client.apache.ApacheHttpClientHandler.handle(ApacheHttpClientHandler.java:189)
          at com.sun.jersey.api.client.Client.handle(Client.java:648)
          at com.sun.jersey.api.client.WebResource.handle(WebResource.java:670)
          at com.sun.jersey.api.client.WebResource.get(WebResource.java:191)
          at org.jenkinsci.plugins.urltrigger.URLTrigger.checkIfModifiedEntryForHttpOrHttpsURL(URLTrigger.java:229)
          at org.jenkinsci.plugins.urltrigger.URLTrigger.checkIfModifiedEntry(URLTrigger.java:217)
          at org.jenkinsci.plugins.urltrigger.URLTrigger.checkIfModified(URLTrigger.java:200)
          at org.jenkinsci.lib.xtrigger.AbstractTrigger$Runner.run(AbstractTrigger.java:202)
          at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
          at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
          at java.lang.Thread.run(Thread.java:745)
      2017-07-17 11:45:00.807+0000 [id=619]   INFO    o.a.c.h.a.AuthChallengeProcessor#selectAuthScheme: ntlm authentication scheme selected
      2017-07-17 11:45:00.807+0000 [id=619]   SEVERE  o.a.c.h.HttpMethodDirector#executeConnect: Credentials cannot be used for NTLM authentication: org.apache.commons.httpclient.UsernamePasswordCredentials
      org.apache.commons.httpclient.auth.InvalidCredentialsException: Credentials cannot be used for NTLM authentication: org.apache.commons.httpclient.UsernamePasswordCredentials
      

      Jenkins now allows for NTLM authentication since the fix for https://issues.jenkins-ci.org/browse/JENKINS-1920 and the URL trigger plugin should use the same proxy configuration.

            gbois Gregory Boissinot
            ataylor Alex Taylor
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: