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

[BUG][Workspace] Permission check failed with empty workspace array #6528

Closed
Hailong-am opened this issue Apr 18, 2024 · 0 comments
Closed
Labels
bug Something isn't working untriaged

Comments

@Hailong-am
Copy link
Collaborator

Describe the bug

when doing permission check, it will filter workspace list and verify there at least have 1 workspace user have permission, otherwise it will throw exception.

The bug is that, if we pass an empty array, that will go through this check and throw exception.

https://github.com/opensearch-project/OpenSearch-Dashboards/blob/main/src/plugins/workspace/server/saved_objects/workspace_saved_objects_client_wrapper.ts#L469-L490

To Reproduce
Steps to reproduce the behavior:

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Expected behavior
A clear and concise description of what you expected to happen.

OpenSearch Version
main

Dashboards Version
main

Plugins

workspace

Screenshots

If applicable, add screenshots to help explain your problem.

Host/Environment (please complete the following information):
main

Additional context

Add any other context about the problem here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working untriaged
Projects
None yet
Development

No branches or pull requests

1 participant