Uploaded image for project: 'Bamboo Data Center'
  1. Bamboo Data Center
  2. BAM-19712

SCP task with ssh key authentication doesn't work if passphrase is empty

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Low Low
    • 6.4.1
    • 6.3.0, 6.4.0
    • SCP and SSH tasks
    • None

      Error occurred while running Task 'Copy' of type com.atlassian.bamboo.plugins.bamboo-scp-plugin:scptask.
      23-Feb-2018 13:24:03 java.lang.NullPointerException
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.plugins.scp.SSHKeyProvider.<init>(SSHKeyProvider.java:26)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.plugins.scp.ScpTask.execute(ScpTask.java:257)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.plugins.scp.ScpTask.run(ScpTask.java:120)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.plugins.scp.ScpTask.execute(ScpTask.java:106)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.task.TaskExecutorImpl.lambda$executeTasks$1(TaskExecutorImpl.java:281)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.task.TaskExecutorImpl.executeTaskWithPrePostActions(TaskExecutorImpl.java:224)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.task.TaskExecutorImpl.executeTasks(TaskExecutorImpl.java:281)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.task.TaskExecutorImpl.execute(TaskExecutorImpl.java:112)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.build.pipeline.tasks.ExecuteBuildTask.call(ExecuteBuildTask.java:71)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.executeBuildPhase(DefaultBuildAgent.java:203)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:175)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.lambda$waitAndPerformBuild$0(BuildAgentControllerImpl.java:122)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.variable.CustomVariableContextImpl.withVariableSubstitutor(CustomVariableContextImpl.java:185)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:117)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:126)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:48)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:26)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:17)
      23-Feb-2018 13:24:03 at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:41)
      23-Feb-2018 13:24:03 at java.lang.Thread.run(Thread.java:748)
      

      Workaround

      Use Shared credentials authentication

            [BAM-19712] SCP task with ssh key authentication doesn't work if passphrase is empty

            Monique Khairuliana (Inactive) made changes -
            Workflow Original: Bamboo Workflow 2016 v1 - Restricted [ 2636815 ] New: JAC Bug Workflow v3 [ 3385752 ]
            Status Original: Resolved [ 5 ] New: Closed [ 6 ]
            Owen made changes -
            Symptom Severity Original: Major [ 14431 ] New: Severity 2 - Major [ 15831 ]
            Jeremy Owen made changes -
            Regular Expression New: java\.lang\.NullPointerException[\s\S]{1,200}com\.atlassian\.bamboo\.plugins\.scp\.SSHKeyProvider
            Affects Version/s New: 6.4.0 [ 77308 ]
            Jeremy Owen made changes -
            Affects Version/s Original: 6.4.0 [ 77308 ]
            Jeremy Owen made changes -
            Affects Version/s New: 6.4.0 [ 77308 ]
            Krystian Brazulewicz made changes -
            Remote Link New: This issue links to "BDEV-13473 (Atlassian JIRA Extranet - Special Projects)" [ 356206 ]

            Imo Klabun added a comment -

            Had the same issue after upgrading from 6.2.x. The new plugin solved the issue.

            Imo Klabun added a comment - Had the same issue after upgrading from 6.2.x. The new plugin solved the issue.

            Interesting. We encountered this issue only now after upgrading our Bamboo Server installation from v6.3 to v6.4. Are you proposing we should have been seeing this already?

            Can confirm the attached add-on does resolve the issue for us. Thank you!

            Valters Jansons added a comment - Interesting. We encountered this issue only now after upgrading our Bamboo Server installation from v6.3 to v6.4. Are you proposing we should have been seeing this already? Can confirm the attached add-on does resolve the issue for us. Thank you!
            Alexey Chystoprudov made changes -
            Attachment New: bamboo-scp-plugin-6.4.3.jar [ 309941 ]

            Alexey Chystoprudov added a comment - - edited

            It's broken since 6.3.0. Replace existing bamboo-scp-plugin-6.4.2.jar with attached bamboo-scp-plugin-6.4.3.jar for Bamboo 6.4.0

            Alexey Chystoprudov added a comment - - edited It's broken since 6.3.0. Replace existing bamboo-scp-plugin-6.4.2.jar with attached bamboo-scp-plugin-6.4.3.jar for Bamboo 6.4.0

              achystoprudov Alexey Chystoprudov
              achystoprudov Alexey Chystoprudov
              Affected customers:
              1 This affects my team
              Watchers:
              6 Start watching this issue

                Created:
                Updated:
                Resolved: