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

Cannot connect without INFO permission #5270

Closed
moreinhardt opened this issue Oct 5, 2022 · 2 comments
Closed

Cannot connect without INFO permission #5270

moreinhardt opened this issue Oct 5, 2022 · 2 comments
Labels

Comments

@moreinhardt
Copy link

Describe the bug
I don't understand why this GUI needs permission to run INFO on the redis server just to connect.

To Reproduce
Steps to reproduce the behavior:

  1. Configure ACLs to remove the permission to run INFO from the user you use to connect. In this example I disallow all dangerous and admin commands. The former includes the INFO command.
ACL SETUSER default on >mypassword +@all -@dangerous -@admin
  1. Try to connect to the server using RESP.app.
  2. While the actual connection is established the GUI just freezes and after some time I get a pop-up with the message Cannot connect to server 'localhost 6379'. Check log for details.. I never see any keys. The RESP.app log shows:
Connection: localhost 6379 > connected
Connection: localhost 6379 > [runCommand] AUTH *******
Connection: localhost 6379 > [runCommand] PING
Connection: localhost 6379 > [runCommand] INFO ALL
Connection: Cannot refresh server info: NOPERM this user has no permissions to run the 'info' command

Expected behavior
I can connect to the server and interact normally with the keys. Just not see any server infos. Maybe I'm just missing a setting where I can disable this INFO ALL call?

Environment (please complete the following information):

  • OS & version: Ubuntu 20.04
  • Redis-Server version: 7.0.5
@moreinhardt moreinhardt added the bug label Oct 5, 2022
@uglide uglide closed this as completed in 04585b2 Oct 5, 2022
@uglide
Copy link
Collaborator

uglide commented Oct 5, 2022

@moreinhardt Thanks for the bug report. Your point is valid and RESP.app should be able to operate with the blocked INFO command. Fix was added and will be released as part of the 2022.5 version.

PS: Your ACL command is not correct. You need to add allkeys to be able to read keys in RESP.app

@moreinhardt
Copy link
Author

Wow! This is an insanely fast response, thank you! 😃

PS: Your ACL command is not correct. You need to add allkeys to be able to read keys in RESP.app

Actually, according to these docs the default user can access all keys per default. So I didn't need to add allkeys or ~*. 🤔

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

No branches or pull requests

2 participants