-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Race condition in approle login with identical role-id #3746
Comments
We are also facing same issue. Any update on this? |
@patelpu94 What version of Vault? |
Vault version 0.9.0 but we are using app-id/user-id instead of approle. |
@patelpu94 It's actually a race condition in Identity, so it affects all auth backends. The fix above should handle it in all cases though! |
Even with Upgraded Vault 0.9.4 we saw this issue. And it does not complain about it until Vault is restarted. And it does not elect the leader. |
@patelpu94 Are you facing this issue during the upgrade or have you already been using 0.9.4? I ask this because, if the conflicting entities in question are created before the upgrade, it is possible that the fix won't have an effect on the outcome that you are facing. The fix only tries to avoid racy duplications, but doesn't clean up the already created conflicting entities. On the other hand, if you were already using 0.9.4 and that the entities in question were created after the upgrade, then we'll have to see why this is happening. Are you able to bring up Vault at all, or are you completely stuck? If you are able to bring up Vault, manually clearing the entities that are conflicting and recreating them might be a good way forward. If you happen to have a way to consistently reproduce this, it would help us a lot. |
This is using 0.9.4 we are been running for awhile and not during upgrade. We were able to use the Vault after we removed one at a time entry from vault/logical/xxxx/packer/buckets/YYYY |
We faced the same problem running 0.9.4 and deleting vault/logical/xxxx/packer/buckets/YYYY solved it. |
Environment:
Vault v0.9.0 ('bdac1854478538052ba5b7ec9a9ec688d35a3335')
Vault Config File:
Startup Log Output:
Expected Behavior:
Approle
/auth/approle/login
should always succeed given a valid role-id and secret-id.Actual Behavior:
Login returns 500 response with error message like
alias "6701e7da-142f-12a9-22cf-ebf5b343414d" in already tied to a different entity "a29c7397-516b-2595-8c36-ff8ca0af7edd"
.Steps to Reproduce:
Perform multiple logins to an approle within μsec from one another. I am unable to estimate threshold at which this race condition is encountered (could be between 1 and 1000 μsec).
Logging from my client implementation (all values below are generated for issue reporting purpose):
Important Factoids:
Occurs periodically in my test environment (two concurrent login client requests). I assume this is tied to network jitter on my loopback interface. Cannot be reproduced if a random sleep (up to 1s) is introduced between login requests.
Appears to be related with transaction alias sanity checking.
References:
The text was updated successfully, but these errors were encountered: