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

1.15.x web ui kv quick action search depth limited to 1 level #23979

Closed
rjhornsby opened this issue Nov 2, 2023 · 7 comments
Closed

1.15.x web ui kv quick action search depth limited to 1 level #23979

rjhornsby opened this issue Nov 2, 2023 · 7 comments

Comments

@rjhornsby
Copy link
Contributor

Describe the bug
The new 1.15.x web ui has some neat features - including the quick actions on the dashboard view. However, when you try to use this to search beyond the top-level path, the UI always says "no results found"

To Reproduce
Steps to reproduce the behavior:

  1. Create a kv secret at a depth of greater than the top level, ie recipes/cookie
  2. Use the web UI's quick action to search kv for the path to that secret
  3. The UI will only recognize the top-level path recipes/ and if you try typing any further it will always say "no results found"

Expected behavior
The UI prompts for a path, and should be able to search/show results beyond only the top level

Environment:

  • Vault Server Version: 1.15.1

Additional context

As described in #23978, this seems to be part of a more generalized thing with vault where while vault 100% supports path-based logic, parts of vault forget or ignore this and either hardcode a specific path depth or otherwise assume everything is at the root of whatever you're working in.

@hashishaw
Copy link
Contributor

Unfortunately this is a limitation with the component we use to surface the suggestions. We'll add this to our backlog for enhancements to consider in the future.

@rjhornsby
Copy link
Contributor Author

Unfortunately this is a limitation with the component we use to surface the suggestions. We'll add this to our backlog for enhancements to consider in the future.

With all due respect, this isn't a feature request for a future enhancement. It's a bug.

At least at the presentation layer (API, web UI, or CLI), Vault's fundamental design for storage and data access is a hierarchical directory-like tree structure. A feature or component that doesn't support these paths at depth > 1 or hardcodes/expects a specific number of path components is by definition broken because it can't handle or ignores the tree structure. Instead, here it incorrectly states "no results found" - this statement is provably not true.

Whether the UI component in question is misbehaving because of specific bug or limited capabilities, the result is the same - this part of the UI is broken. It's not much different than any other file (or generic tree-like) browser - ie Windows Explorer, Finder, shell completion, etc - stopping you after the top level and saying "no results found". We would 100% say that is broken behavior.

@Monkeychip
Copy link
Contributor

Hi @rjhornsby. I'm trying to reproduce your issue and I may be misunderstanding. There was a change in 1.15 to the KV secret engines search behavior. Most notable, it no longer searches as you type. You must hit enter or click on the search button to perform a search. However, I am still able to search for a nested secret. See screen cast attached. The secret in question is beep/bop/boop.

Screen.Recording.2023-11-30.at.3.38.23.PM.mov

@rjhornsby
Copy link
Contributor Author

rjhornsby commented Dec 1, 2023

Yeah, I think we're talking about two different parts of the UI. I believe the "Quick actions" part of the dashboard is new in 1.15.x.

At the top level, as you are typing, Vault presents an interactively filtered list of items at this level. However, here we can see that the UI is not descending this search into the path, despite the trailing /:

Screenshot 2023-11-30 at 20 14 24

If you hit <enter> at this point, it locks in the "search":

Screenshot 2023-11-30 at 20 12 38

There's no obvious way to descend beyond the top level path - either interactively with the search filtering or by hitting <enter> to get it to search the new current path.

@Monkeychip
Copy link
Contributor

@rjhornsby Thank you for the details! You're correct I was in a different part of the app 🙈. As mentioned by @chelshaw the current component we use for this filtering does not allow us to search beyond the first level of a secret's directory. However, there is work being done that might solve this issue. We've made a ticket to incorporate that new work and are aiming to have that work done for 1.16.0 (we will not be able to backport it to a minor release for 1.15.x). I'll update the ticket here when/if that work is merged and this problem can be tackled. Thanks again for the issue!

@rjhornsby
Copy link
Contributor Author

we will not be able to backport it to a minor release for 1.15.x

No objections to that. We're happy to upgrade to 1.16 when the time comes. Thanks for keeping us updated.

@Monkeychip
Copy link
Contributor

@rjhornsby this will be added in 1.16.0. Here's a link to the WIP PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants