Skip to content

[Messenger] [Redis] Allow authentication with user and password #43124

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

Merged
merged 1 commit into from
Sep 24, 2021

Conversation

GaryPEGEOT
Copy link
Contributor

Q A
Branch? 5.3
Bug fix? yes
New feature? no
Deprecations? no
Tickets
License MIT
Doc PR N/A

Allow to authenticate on Redis with user and password, instead of only password

@GaryPEGEOT GaryPEGEOT requested a review from sroze as a code owner September 21, 2021 14:01
@carsonbot carsonbot added this to the 5.3 milestone Sep 21, 2021
@carsonbot carsonbot changed the title [Messenger][Redis] Allow authentication with user and password [Messenger] [Redis] Allow authentication with user and password Sep 21, 2021
@derrabus
Copy link
Member

Is 4.4 affected by this bug as well?

@GaryPEGEOT
Copy link
Contributor Author

Is 4.4 affected by this bug as well?

File did not exists in 4.4 !

@GaryPEGEOT GaryPEGEOT requested a review from jderusse September 21, 2021 22:24
@derrabus
Copy link
Member

File did not exists in 4.4 !

That was not my question. 😉 Messenger 4.4 did have support for Redis and the logic was eventually moved to the file you're fixing here.

@fabpot
Copy link
Member

fabpot commented Sep 22, 2021

I suppose the code was in src/Symfony/Component/Messenger/Transport/RedisExt/Connection.php in 4.4.

@GaryPEGEOT
Copy link
Contributor Author

Ok, my bad! should backport the PR to 4.4 as well @fabpot ?

@chalasr
Copy link
Member

chalasr commented Sep 22, 2021

Please rebase on 4.4 and do the change on that file, yes. We will take care of applying the patch to the new location when merging up.

@GaryPEGEOT
Copy link
Contributor Author

@chalasr I've changed the base branch & files :)

@chalasr chalasr force-pushed the fix/messenger-redis-auth branch from e8a034e to 5a6bf50 Compare September 24, 2021 09:45
@chalasr
Copy link
Member

chalasr commented Sep 24, 2021

Thank you @GaryPEGEOT.

@chalasr chalasr merged commit c9275a9 into symfony:4.4 Sep 24, 2021
@GaryPEGEOT GaryPEGEOT deleted the fix/messenger-redis-auth branch September 24, 2021 10:45
This was referenced Sep 28, 2021
chalasr added a commit that referenced this pull request Oct 24, 2021
…llfa)

This PR was merged into the 4.4 branch.

Discussion
----------

[Messenger] Fix Redis Transport when username is empty

| Q             | A
| ------------- | ---
| Branch?       | 4.4
| Bug fix?      | yes
| New feature?  | no
| Deprecations? | no
| Tickets       | Fix #43306
| License       | MIT
| Doc PR        | n/a

Checking the username and the password with `isset` is not enough. We also need to check they're not empty strings.
This fixes the BC break introduced by #43124.

See also https://3v4l.org/iASnE

Commits
-------

cd66b8c [Messenger] Fix Redis Transport when username is empty
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants