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.
Fixes
This pull request fixes #2180
Description
Added support for using shared credentials across multiple witsml servers when using oAuth with azure.
Credential Ids
input when editing a server. Only people with theadmin
role will be able to edit this when oAuth is enabled.CredentialIds
to the server objects. This is stored along with the rest of the server object in the database.CredentialId
toServerCredentials
. This will be populated with from the name of the keyvault secret. For examplesharedCredentials
from the secret with namewitsmlcreds--sharedCredentials--Host
CredentialIds
is specified, it will match the credentialIds to find the credentials. If it is not specified, it will use the Uri. This way you don't have to make any changes in the application or the keyvault after this PR has been merged.Testing these changes can be a bit difficult unless you are using oAuth with system-user secrets in Azure. I have tested it as thorough as possible (with oAuth), but I only had one system user to test it on.
NOTE: If you "degrade" from these changes to one without
CredentialIds
, theCredentialIds
field might have to be removed from the database.If you are reviewing this PR, please use some time to think about if I have managed to keep the credentials secure. You still need to have the
admin
role to changeCredentialIds
, and you still need to have a role that overlaps with the server roles in order to actually use the credentials.Type of change
Impacted Areas in Application
Checklist:
Communication
Code quality
Test coverage
Further comments