You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[RFE] Allow Approle and LDAP/AD Auth Mechanisms for AWX/Hashicorp Vault Token Integration #5076
Currently, only static tokens are allowed as the inputs to integrate Hashicorp Vault with AWX. Customer wants the following:
For Approle:
Input approle_id (which exists on the Hashicorp Vault side) in a Vault Signed SSH and Vault Secrets credential. The resultant output of this will be the Secret Token being filled in and returned from the API call to Hashicorp Vault.
Docs >>>>> https://www.vaultproject.io/docs/auth/approle.html
For AD/LDAP:
Input username and password (AD/LDAP integration exists on the Hashicorp Vault side) in a Vault Signed SSH and Vault Secrets credential. The resultant output of this will be the Secret Token being filled in and returned from the API call to Hashicorp Vault.
Docs >>>>> https://www.vaultproject.io/docs/auth/ldap.html
Each time the credential is used, this API call should be made and the secret token should be updated. This will allow for short-lived TTLs on secret tokens and reduces the amount of manual effort to update secret tokens.
Reacted by sky-joker, But4ler, mruireis, Louis Tiches, e11it, Ishwar Kanse, Jason Simons, trestylez, Alexandre Bortoluzzi, blaisemichel and 3 more
This one is somewhat complex. The AppRole piece should fit in pretty easily but the LDAP part requires that hashicorp vault be configured to use LDAP for auth, which means running a few commands in the container and having it use the existing Red Hat Directory Server. We would also either need to make this a separate class or use it function scope since it would alter the configuration of the vault significantly.
Flow would look like this for the LDAP portion
Provision the Vault deployment
Create a user with a name matching one in the LDAP directory
Create a secret that this user has access to
Execute the command inside the container to enable ldap auth
Execute a command delivering a JSON payload with LDAP config info
Create the credential in tower using the ldap creds
Pull the secret
Gotchas to worry about:
Exposure of LDAP Credentials, since we're storing them statically here.
Creates an additional dependency for the external directory server
Error handling for invalid LDAP creds
Make sure it's an invalid username and not an invalid password. Don't want to get the account locked.
Error handling for locked accounts (The default behavior for LDAP directories is usually to lock an account if 5 failed logins happen).
This could be replicated by just having a locked account in the directory and using it in a test.
I also think this might be a good issue for someone to pair up with me on because it touches a couple of external systems that a lot of QE folks haven't touched yet.
The prior comment stands - part of the subject of this issue had a pull request that was merged (AppRole)... there has been no changes for LDAP auth, so it remains open.
Activity
kawsark commentedon Mar 6, 2020
PR: #6220
Testing steps: https://github.com/kawsark/awx-approle-ansible
ItayZviCohen commentedon Apr 20, 2020
Really want this feature to exist. I'm working for a very large corporation and what we did is to store Vault credential as a custom secret.
Tioborto commentedon Apr 22, 2020
+1
Fredki2 commentedon Apr 22, 2020
+1
kdelee commentedon Jul 27, 2020
@one-t could you take a look at this sometime
one-t commentedon Jul 27, 2020
This one is somewhat complex. The AppRole piece should fit in pretty easily but the LDAP part requires that hashicorp vault be configured to use LDAP for auth, which means running a few commands in the container and having it use the existing Red Hat Directory Server. We would also either need to make this a separate class or use it function scope since it would alter the configuration of the vault significantly.
Flow would look like this for the LDAP portion
Gotchas to worry about:
one-t commentedon Jul 27, 2020
I also think this might be a good issue for someone to pair up with me on because it touches a couple of external systems that a lot of QE folks haven't touched yet.
one-t commentedon Aug 5, 2020
Putting this back in needs_devel, there are unmerged PRs - #6158 #6159
ryanpetrello commentedon Nov 25, 2020
@wenottingham is this a near-term priority that we should track more closely as an enhancement in the next major release?
wenottingham commentedon Nov 30, 2020
The approle bits were already merged, it is just LDAP/AD which is not.
Tioborto commentedon Feb 12, 2021
Hi @wenottingham, @ryanpetrello , any idea about the resolution of this topic ? please
wenottingham commentedon Feb 12, 2021
The prior comment stands - part of the subject of this issue had a pull request that was merged (AppRole)... there has been no changes for LDAP auth, so it remains open.
Show inventory source POST in OPTIONS for inventory admins (ansible#5076
Show inventory source POST in OPTIONS for inventory admins (ansible#5076