Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Issue #293 Unit tests demonstrating that BATCH mode redis client does not properly authenticate #292

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

noahlz
Copy link

@noahlz noahlz commented Nov 3, 2021

I'm investigating an issue similar to Issue #282 and decided to add a unit test that demonstrates how the RedisClientPool supports Authentication.

… container is being set up properly with a password
@noahlz
Copy link
Author

noahlz commented Nov 3, 2021

[info] SecurePoolSpec:
[info] redis pools with authentication
[info] - should be able to connect as normal
[info] ad-hoc clients connecting to a secure redis server
[info] - should be rejected for no password
[info] - should be rejected for wrong password

@noahlz noahlz changed the title Issue #282 added unit test demonstrating that Pools support passwords (with some refactoring) Issue #293 Unit tests demonstrating that BATCH mode redis client does not properly authenticate Nov 3, 2021
@noahlz
Copy link
Author

noahlz commented Nov 3, 2021

[info] SecureBatchedPipelineSpec:
[info] a redis client in batch mode connecting to a password-protected redis instance
[info] - should be able to connect to the instance *** FAILED ***
[info]   An unexpected java.lang.Exception was thrown. (PipelineSpec.scala:388)
[info] - should be rejected when it is not initialized with a password
[info] - should be rejected when it is initialized with an incorrect password
[info] com.redis.SecureBatchedPipelineSpec *** ABORTED ***
[info]   java.lang.Exception: NOAUTH Authentication required.
[info]   at com.redis.Reply$$anonfun$errReply$1.applyOrElse(RedisProtocol.scala:132)
[info]   at com.redis.Reply$$anonfun$errReply$1.applyOrElse(RedisProtocol.scala:131)
[info]   at scala.runtime.AbstractPartialFunction.apply(AbstractPartialFunction.scala:35)
[info]   at com.redis.Reply$$anonfun$singleLineReply$1.applyOrElse(RedisProtocol.scala:77)
[info]   at com.redis.Reply$$anonfun$singleLineReply$1.applyOrElse(RedisProtocol.scala:77)
[info]   at scala.PartialFunction$OrElse.apply(PartialFunction.scala:266)
[info]   at com.redis.Reply$$anonfun$integerReply$1.applyOrElse(RedisProtocol.scala:67)
[info]   at com.redis.Reply$$anonfun$integerReply$1.applyOrElse(RedisProtocol.scala:67)
[info]   at scala.PartialFunction$OrElse.apply(PartialFunction.scala:266)
[info]   at com.redis.Reply.receive(RedisProtocol.scala:152)
[info]   ...

@noahlz
Copy link
Author

noahlz commented Nov 3, 2021

These unit tests expose #293

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

Successfully merging this pull request may close these issues.

1 participant