StackExchange / StackExchange/StackExchange.Redis
Comma in strong password incompatible with connection string format
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 6.2k
- Forks
- 1.6k
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 43
Description
We have an auto-provisioned Redis instance in a cloud environment. The password we're provided is generated for us, is very long, and has a lot of special characters... including, sometimes, commas.
We then have systems that try to attach to Redis using a connection string. Unfortunately, the way SE.Redis parses connection strings based on comma delimiters, it means if our generated password has a comma in it, then part of the password gets interpreted as another host. Exception messages have stuff like this buried in them: SocketFailure on *9?9pi?aK__6fAKSH:6379/Subscription (where *9?9pi?aK__6fAKSH is the half of the password after the comma).
Looking through the parsing code it doesn't appear there's a way to escape commas. That might be a good addition to help in edge cases like this.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the connection-string parsing entry point and the existing password handling, then reproduce the issue with a Redis password containing a comma. Done means comma-containing passwords are parsed without treating the remaining password text as another host, with the behavior covered by tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, redis
- Domain
- backend, databases
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100