Skip to content

Prefix Path not working for IBM Cloud Secrets Manager #347

@Kalchschmidt-Marvin

Description

@Kalchschmidt-Marvin

Jenkins and plugins versions report

Environment

Jenkins: 2.492.2
OS: Linux - 6.8.0-52-generic
Java: 17.0.11 - Eclipse Adoptium (OpenJDK 64-Bit Server VM)

credentials:1413.va_51c53703df1
credentials-binding:687.v619cb_15e923f
hashicorp-vault-plugin:371.v884a_4dd60fb_6
...

What Operating System are you using (both controller, and any agents involved in the problem)?

Reproduction steps

  1. Navigate to Manage Jenkins > Credentials > System > Global credentials
  2. Click +Add Credential
  3. Select Kind -> Vault-Username-Password Credential
  4. Select Scope -> Global
  5. Set Prefix Path -> ibmcloud/kv
  6. Set Path to <SECRET_GROUP_ID>/<SECRET_NAME_OR_ID>
  7. Specify Username and Password keys
  8. Set K/V Engine Version -> 2
  9. Set some ID
  10. Click Test Secret Vault retrieval button

Expected Results

Successfully retrieved username <MY_USERNAME> and the password

Actual Results

FAILED to retrieve username key: com.datapipe.jenkins.vault.exception.VaultPluginException: Key username could not be found in path <SECRET_GROUP_ID>/<SECRET_NAME_OR_ID>

Note: prefix path is not added to path

Anything else?

When specifying Path as ibmcloud/kv/<SECRET_GROUP_ID>/<SECRET_NAME_OR_ID> and leaving Prefix Path either empty or setting it to ibmcloud/kv in the credential definition (it's also specified in the Plugin settings though), the call is successful!
I just don't think that's the expected behaviour.

Are you interested in contributing a fix?

I believe adopting the IBM Cloud Secrets Manager will be a big task and necessary to create a smooth interaction with the HashiCorp Vault Jenkins plugin and I don't have the required expertise for this. I would still very much appreciate your support

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions