Fix Vault namespace handling for AppRole authentication#18
Merged
sumedhe merged 3 commits intowso2-extensions:masterfrom Apr 29, 2026
Merged
Fix Vault namespace handling for AppRole authentication#18sumedhe merged 3 commits intowso2-extensions:masterfrom
sumedhe merged 3 commits intowso2-extensions:masterfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR ensures the configured HashiCorp Vault namespace is applied consistently to both secret reads and AppRole authentication, so AppRole login targets the intended non-root namespace.
Changes:
- Apply the configured namespace at the
VaultConfiglevel for secret reads. - Apply the configured namespace at the
VaultConfiglevel for AppRole login. - Normalize (trim) the namespace and skip namespace configuration when not provided.
Comments suppressed due to low confidence (1)
src/main/java/org/wso2/carbon/securevault/hashicorp/repository/HashiCorpSecretRepository.java:204
- The exception message in this secret-read path says "Error retrieving service token using AppRole", which is misleading when
logical.read(path)fails. Please update it to describe the actual operation (reading a secret) and ideally include the relevant path/alias for easier troubleshooting.
} catch (VaultException e) {
throw new HashiCorpVaultException("Error retrieving service token using AppRole", e);
}
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Oshanath
approved these changes
Apr 28, 2026
sumedhe
approved these changes
Apr 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose