-
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
Gate sync overview route for users without access #27320
Gate sync overview route for users without access #27320
Conversation
CI Results: failed ❌ |
Build Results: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work! A couple change requests, and I'm wondering with the ent tests failing -- were you running against an enterprise backend?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Beautiful, thank you!
51bf477
into
ui/VAULT-27608/hide-secrets-sync-when-no-access
…issions (#27262) * intial changes, haven't tested client counts or done test coverage * client count rename getter to clairfy * fix has-permission api-paths * wip * wip * fix: explicitly refresh vault.cluster model to re-fetch activatedFeatures after actication * tests: fix # of assertions for verifying that activation was called * tests: tidy overview-test * add additional api permission path and move fetch back to application * add test coverage for the service * cleanup * remove test that checked for upsell without license or on community * small comment change * welp missed component getter * flaky test fix * flaky test * small nit changes from pr reviews * add defaults to sync mirage handler * Gate sync overview route for users without access (#27320) * routes: add redirect if user does not have access to sync * tests: verify redirect on sync overview page happens * tests: organize tests modules to ensure enterprise is explicitly set up * add type enterprise required now because we do a check for this first * fix oss test --------- Co-authored-by: Noelle Daley <[email protected]>
🛠️ Description
Adds a secondary layer of protection to the Sync overview page, ensuring users can't access the page by pasting the URL directly.
🔗 Links
Follow up to https://github.com/hashicorp/vault/pull/27262/files
📸 Screenshots
Ent tests pass locally except for unrelated replication / kv tests

🏗️ How to Build and Test the Change
🚫 Using an OSS cluster, verify you cannot directly access
http://localhost:4200/ui/vault/sync/secrets/overview
.✅ Using an ENT cluster, verify you can access
http://localhost:4200/ui/vault/sync/secrets/overview
(and see "sync" in the sidebar).