diff options
Diffstat (limited to 'internal/config/README.md')
| -rw-r--r-- | internal/config/README.md | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/internal/config/README.md b/internal/config/README.md index dbb8760..7deb38f 100644 --- a/internal/config/README.md +++ b/internal/config/README.md | |||
| @@ -90,12 +90,25 @@ auth: | |||
| 90 | # Timestamp window in seconds for replay protection | 90 | # Timestamp window in seconds for replay protection |
| 91 | timestamp_window: 60 | 91 | timestamp_window: 60 |
| 92 | 92 | ||
| 93 | # Allowed npubs (optional, whitelist) | 93 | # Allowed npubs for read operations (optional, whitelist) |
| 94 | # If empty, all valid signatures are accepted | 94 | # If empty, all valid signatures are accepted for reads |
| 95 | # Use npub format only (e.g., npub1...) | 95 | # Use npub format only (e.g., npub1...) |
| 96 | allowed_npubs: [] | 96 | allowed_npubs_read: [] |
| 97 | |||
| 98 | # Allowed npubs for write operations (optional, whitelist) | ||
| 99 | # If empty, all valid signatures are accepted for writes | ||
| 100 | # Use npub format only (e.g., npub1...) | ||
| 101 | allowed_npubs_write: [] | ||
| 102 | |||
| 103 | # Example use cases: | ||
| 104 | # - Public relay: allowed_npubs_write (only some can publish), empty read (everyone can read) | ||
| 105 | # - Private relay: both lists populated (restricted read and write) | ||
| 106 | # - Open relay: both lists empty (everyone can read and write) | ||
| 107 | # | ||
| 97 | # Example: | 108 | # Example: |
| 98 | # allowed_npubs: | 109 | # allowed_npubs_read: |
| 110 | # - npub1a2b3c4d5e6f... | ||
| 111 | # allowed_npubs_write: | ||
| 99 | # - npub1a2b3c4d5e6f... | 112 | # - npub1a2b3c4d5e6f... |
| 100 | 113 | ||
| 101 | # Skip authentication for these methods | 114 | # Skip authentication for these methods |
| @@ -222,7 +235,8 @@ Complex types: | |||
| 222 | 235 | ||
| 223 | ```bash | 236 | ```bash |
| 224 | # Lists (comma-separated, npub format) | 237 | # Lists (comma-separated, npub format) |
| 225 | export MUXSTR_AUTH_ALLOWED_NPUBS="npub1...,npub1...,npub1..." | 238 | export MUXSTR_AUTH_ALLOWED_NPUBS_READ="npub1...,npub1..." |
| 239 | export MUXSTR_AUTH_ALLOWED_NPUBS_WRITE="npub1..." | ||
| 226 | 240 | ||
| 227 | # Durations | 241 | # Durations |
| 228 | export MUXSTR_SERVER_READ_TIMEOUT="30s" | 242 | export MUXSTR_SERVER_READ_TIMEOUT="30s" |
