Skip to content
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

Cache users #11

Closed
froque opened this issue Jan 3, 2023 · 2 comments
Closed

Cache users #11

froque opened this issue Jan 3, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@froque
Copy link
Member

froque commented Jan 3, 2023

Dbeaver uses multiple connections at the same time, leading to multiple requests to Vault and multiple temporary users created.

Additionally, this is a problem for read replica databases that may not process new users in time and reject the authentication

@froque
Copy link
Member Author

froque commented Jan 3, 2023

Vault response is

curl --header "X-Vault-Token: aaaaaaa" https://example.com/v1/database/creds/readonly
{
    "request_id": "43f5a069-a414-b4df-d49b-242161516dfe",
    "lease_id": "zzzzzzzz",
    "renewable": true,
    "lease_duration": 1209600,
    "data": {
        "password": "yyyyyy",
        "username": "xxxxxx"
    },
    "wrap_info": null,
    "warnings": null,
    "auth": null
}

lease_duration is in seconds

@froque
Copy link
Member Author

froque commented Jan 4, 2023

fixed in #12

@froque froque closed this as completed Jan 4, 2023
@froque froque added the enhancement New feature or request label Jan 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant