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

AJP support does not respect the specs. breaks with SSL

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • core

      According to this bug https://issues.apache.org/bugzilla/show_bug.cgi?id=39658 an the mod_jk documentation, ssl_key_size attribute is passed as an integer.
      Winstone parses it as a string and generates a stack trace.

      Steps to reproduce:
      1. Start jenkins in standalone mode with AJP activated on some port
      2. Setup a reverse proxy on apache on a virtualhost which has ssl configured
      3. navigate to https://rproxy.address/jenkins

      Results

      • Apache returns an "Internal error"
      • /var/log/jenkins/jenkins.log is filled with EOFException stack such as this one
        java.io.EOFException
        at java.io.DataInputStream.readFully(DataInputStream.java:197)
        at java.io.DataInputStream.readFully(DataInputStream.java:169)
        at winstone.ajp13.Ajp13IncomingPacket.readString(Ajp13IncomingPacket.java:244)
        at winstone.ajp13.Ajp13IncomingPacket.readString(Ajp13IncomingPacket.java:231)
        at winstone.ajp13.Ajp13IncomingPacket.parsePacket(Ajp13IncomingPacket.java:168)
        at winstone.ajp13.Ajp13Listener.allocateRequestResponse(Ajp13Listener.java:184)
        at winstone.RequestHandlerThread.run(RequestHandlerThread.java:67)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
        at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
        at java.util.concurrent.FutureTask.run(FutureTask.java:166)
        at winstone.BoundedExecutorService$1.run(BoundedExecutorService.java:77)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
        at java.lang.Thread.run(Thread.java:636)

      Expected behaviour:
      A jenkins page, like when using http

          [JENKINS-13703] AJP support does not respect the specs. breaks with SSL

          Simon Poirier added a comment -

          here is a patch based on the specs on the mod_proxy_ajp page https://httpd.apache.org/docs/2.2/mod/mod_proxy_ajp.html

          Simon Poirier added a comment - here is a patch based on the specs on the mod_proxy_ajp page https://httpd.apache.org/docs/2.2/mod/mod_proxy_ajp.html

          Jesse Glick added a comment -

          Seems a duplicate of JENKINS-5753.

          Jesse Glick added a comment - Seems a duplicate of JENKINS-5753 .

          Code changed in jenkins
          User: Fritz Elfert
          Path:
          src/java/winstone/ajp13/Ajp13IncomingPacket.java
          http://jenkins-ci.org/commit/winstone/f5ee736f2e3acb8516ec30c00ee308d6601fe966
          Log:

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Fritz Elfert Path: src/java/winstone/ajp13/Ajp13IncomingPacket.java http://jenkins-ci.org/commit/winstone/f5ee736f2e3acb8516ec30c00ee308d6601fe966 Log: Fix JENKINS-13703

            Unassigned Unassigned
            simpoir Simon Poirier
            Votes:
            5 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: