Skip to content

Commit f3f3013

Browse files
authored
Docs: improvement for #2103 & #1795 (#2225)
This adds a bit of info on required command permissions to connect.
1 parent 7293213 commit f3f3013

File tree

2 files changed

+22
-1
lines changed

2 files changed

+22
-1
lines changed

docs/Configuration.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,27 @@ The above is equivalent to (in the connection string):
170170
$INFO=,$SELECT=use
171171
```
172172

173+
Redis Server Permissions
174+
---
175+
If the user you're connecting to Redis with is limited, it still needs to have certain commands enabled for the StackExchange.Redis to succeed in connecting. The client uses:
176+
- `AUTH` to authenticate
177+
- `CLIENT` to set the client name
178+
- `INFO` to understand server topology/settings
179+
- `ECHO` for heartbeat.
180+
- (Optional) `SUBSCRIBE` to observe change events
181+
- (Optional) `CONFIG` to get/understand settings
182+
- (Optional) `CLUSTER` to get cluster nodes
183+
- (Optional) `SENTINEL` only for Sentinel servers
184+
- (Optional) `GET` to determine tie breakers
185+
- (Optional) `SET` (_only_ if `INFO` is disabled) to see if we're writable
186+
187+
For example, a common _very_ minimal configuration ACL on the server (non-cluster) would be:
188+
```bash
189+
-@all +@pubsub +@read +echo +info
190+
```
191+
192+
Note that if you choose to disable access to the above commands, it needs to be done via the `CommandMap` and not only the ACL on the server (otherwise we'll attempt the command and fail the handshake). Also, if any of the these commands are disabled, some functionality may be diminished or broken.
193+
173194
twemproxy
174195
---
175196

docs/Server.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ There are multiple ways of running redis on windows:
1313

1414
- [Memurai](https://www.memurai.com/) : a fully supported, well-maintained port of redis for Windows (this is a commercial product, with a free developer version available, and free trials)
1515
- previous to Memurai, MSOpenTech had a Windows port of linux, but this is no longer maintained and is now very out of date; it is not recommended, but: [here](https://www.nuget.org/packages/redis-64/)
16-
- WSL/WSL2 : on Windows 10, you can run redis for linux in the Windows Subsystem for Linux; note, however, that WSL may have some significant performance implications, and WSL2 appears as a *different* machine (not the local machine), due to running as a VM
16+
- WSL/WSL2 : on Windows 10+, you can run redis for linux in the Windows Subsystem for Linux; note, however, that WSL may have some significant performance implications, and WSL2 appears as a *different* machine (not the local machine), due to running as a VM
1717

1818
## Docker
1919

0 commit comments

Comments
 (0)