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

PluginManager.installPlugin() is failing with invalid crumb issue

    XMLWordPrintable

    Details

    • Similar Issues:
    • Released As:
      acceptance-test-harness:1.72

      Description

      Using PluginManager.installPlugin() in test to install a very specific version of a plugin is broken with:

      java.io.IOException: Failed to upload plugin: HTTP/1.1 403 Forbidden

      I know that this method is deprecated, but I don't see any replacement to install a specific (old) version of a plugin. @WithPlugins() is installing a newer version, and same behavior for{{ PluginManager.installPlugins()}}.

      I have reproduced it with a test, I am going to push a PR with that test just after, I can try to fix it but I am not sure on how to add the crumb to the HTTP request so any hint or help are welcome there.

      If you think that this method can be replaced with something else as a workaround please tell me also.

      I know that I can disable the crumb verification as a workaround but I wish to have it working fine with the crumb enabled.

      PR is here https://github.com/jenkinsci/acceptance-test-harness/pull/572

        Attachments

          Activity

          ajard A. Jard created issue -
          ajard A. Jard made changes -
          Field Original Value New Value
          Description Using PluginManager.installPlugin() in test to install a very specific version of a plugin is broken with:
          {code:java}
          java.io.IOException: Failed to upload plugin: HTTP/1.1 403 Forbidden{code}
          I know that this method is deprecated, but I don't see any replacement to install a specific (old) version of a plugin. {color:#172b4d}{{@WithPlugins()}}{color} is installing a newer version, and same behavior for{{{color:#172b4d} PluginManager.installPlugins(){color}}}.

          I have reproduced it with a test, I am going to push a PR with that test just after, I can try to fix it but I am not sure on how to add the crumb to the HTTP request so any hint or help are welcome there.

          If you think that this method can be replaced with something else as a workaround please tell me also.

          I know that I can disable the crumb verification as a workaround but I wish to have it working fine with the crumb enabled.
          Using PluginManager.installPlugin() in test to install a very specific version of a plugin is broken with:
          {code:java}
          java.io.IOException: Failed to upload plugin: HTTP/1.1 403 Forbidden{code}
          I know that this method is deprecated, but I don't see any replacement to install a specific (old) version of a plugin. {color:#172b4d}{{@WithPlugins()}}{color} is installing a newer version, and same behavior for{{{color:#172b4d} PluginManager.installPlugins(){color}}}.

          I have reproduced it with a test, I am going to push a PR with that test just after, I can try to fix it but I am not sure on how to add the crumb to the HTTP request so any hint or help are welcome there.

          If you think that this method can be replaced with something else as a workaround please tell me also.

          I know that I can disable the crumb verification as a workaround but I wish to have it working fine with the crumb enabled.

          PR is here https://github.com/jenkinsci/acceptance-test-harness/pull/572
          Hide
          ajard A. Jard added a comment -
          Show
          ajard A. Jard added a comment - PR is merged and released as acceptance-test-harness:1.72 https://github.com/jenkinsci/acceptance-test-harness/releases/tag/acceptance-test-harness-1.72
          ajard A. Jard made changes -
          Assignee Oliver Gond┼ża [ olivergondza ] A. Jard [ ajard ]
          ajard A. Jard made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          ajard A. Jard made changes -
          Status In Progress [ 3 ] In Review [ 10005 ]
          ajard A. Jard made changes -
          Released As acceptance-test-harness:1.72
          Resolution Fixed [ 1 ]
          Status In Review [ 10005 ] Resolved [ 5 ]

            People

            Assignee:
            ajard A. Jard
            Reporter:
            ajard A. Jard
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: