File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
fluss-common/src/main/java/org/apache/fluss/security/auth/sasl/authenticator
fluss-rpc/src/test/java/org/apache/fluss/rpc/netty/authenticate Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -144,7 +144,7 @@ public byte[] evaluateResponse(byte[] token) throws AuthenticationException {
144144 (PrivilegedExceptionAction <byte []>) () -> saslServer .evaluateResponse (token ));
145145 } catch (Exception e ) {
146146 throw new AuthenticationException (
147- String .format ("Failed to evaluate SASL response,reason is %s" , e .getMessage ()));
147+ String .format ("Failed to evaluate SASL response: %s" , e .getMessage ()));
148148 }
149149 }
150150
Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ void testClientWrongPassword() {
8080 assertThatThrownBy (() -> testAuthentication (clientConfig ))
8181 .cause ()
8282 .isExactlyInstanceOf (AuthenticationException .class )
83- .hasMessage ("Authentication failed: Invalid username or password" );
83+ .hasMessageContaining ("Authentication failed: Invalid username or password" );
8484 }
8585
8686 @ Test
@@ -140,7 +140,7 @@ void testServerMechanismWithListenerAndMechanism() throws Exception {
140140 assertThatThrownBy (() -> testAuthentication (clientConfig , serverConfig ))
141141 .cause ()
142142 .isExactlyInstanceOf (AuthenticationException .class )
143- .hasMessage ("Authentication failed: Invalid username or password" );
143+ .hasMessageContaining ("Authentication failed: Invalid username or password" );
144144 clientConfig .setString (
145145 "client.security.sasl.jaas.config" ,
146146 "org.apache.fluss.security.auth.sasl.plain.PlainLoginModule required username=\" bob\" password=\" bob-secret\" ;" );
@@ -175,7 +175,7 @@ void testSimplifyUsernameAndPassword() throws Exception {
175175 assertThatThrownBy (() -> testAuthentication (clientConfig ))
176176 .cause ()
177177 .isExactlyInstanceOf (AuthenticationException .class )
178- .hasMessage ("Authentication failed: Invalid username or password" );
178+ .hasMessageContaining ("Authentication failed: Invalid username or password" );
179179 clientConfig .setString ("client.security.sasl.password" , "alice-secret" );
180180 testAuthentication (clientConfig );
181181 }
You can’t perform that action at this time.
0 commit comments