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
Can't connect to the FB 3 server with AuthServer = Legacy_Auth. [JDBC460] #499
Comments
Commented by: @mrotteveel Which Firebird version are you using, if Firebird 3.0.0, make sure that the user **only** exists for Legacy_Auth. |
Commented by: John Kilin (johnkilin) Server Version LI-V6.3.1.32609 Firebird 3.0 OK, i check but why i have no problem when connect by fbclient or jaybird 2.2.11? |
Commented by: John Kilin (johnkilin) I try "the user **only** exists for Legacy_Auth" I still get the error. |
Commented by: @mrotteveel I will see if I can reproduce this, because I realize that I have recently only tested it with AuthServer=Srp,Legacy_Auth, and not with only AuthServer=Legacy_Auth. |
Commented by: @mrotteveel I can reproduce it when AuthServer=Legacy_Auth, but it works OK when AuthServer=Srp,Legacy_Auth. I'll need to investigate this further, but changing to AuthServer=Srp,Legacy_Auth (and restarting Firebird) is the workaround. The reason it works fine with Jaybird 2.2.11 is that Jaybird 2.2.11 and earlier only supports wire protocol version 10 and the legacy legacy authentication (not a typo), while Jaybird 3 has a fundamentally rewritten implementation to support wire protocol versions 10, 11, 12, and 13. For version 13 (Firebird 3), the method of authentication has also changed significantly to support multiple authentication plugins, and it looks like Jaybird is doing something wrong there when Firebird does not have Srp in the list of supported authentication plugins. |
Modified by: @mrotteveelVersion: Jaybird 3.0.0-beta-1 [ 10801 ] Fix Version: Jaybird 3.0 [ 10440 ] Version: Jaybird 3.0 [ 10440 ] => |
Commented by: John Kilin (johnkilin) I get by Wireshark the attach packets: jaybird 3.0.0 It's very different. |
Commented by: John Kilin (johnkilin) And yes with AuthServer=Srp,Legacy_Auth no errors. |
Commented by: @mrotteveel I found the problem. When adding the authentication information to the DPB, the authentication bytes were always converted to a hexadecimal string, but this only has to happen for the SRP authentication data, and not for legacy auth. This works OK when both Srp and Legacy_Auth are enabled on the server, because then the legacy auth is done in an authentication continuation packet, and not through the DPB. The differences you observed in the attach packets is because Jaybird will always use DPB version 2 with wire protocol 13, but fbclient will initially start with DPB version 1, and only upgrade to DPB version 2 if it is really necessary, and the order of DPB items and actual DPB items in the packet differ. I will probably release a beta-2 later this (or next) week. Let me know if you want a snapshot for testing. |
Modified by: @mrotteveelFix Version: Jaybird 3.0.0-beta-2 [ 10802 ] |
Commented by: John Kilin (johnkilin) Thanks! I'll wait for the beta-2. |
Modified by: @mrotteveelstatus: Resolved [ 5 ] => Closed [ 6 ] |
Submitted by: John Kilin (johnkilin)
I try to connect with Jaybird-3.0.0-beta-1-JDK_1.8 to the FB 3 server with configuration parameters:
AuthServer = Legacy_Auth
UserManager = Legacy_UserManager
and receive error:
Caused by: java.sql.SQLException: Your user name and password are not defined. Ask your database administrator to set up a Firebird login. [SQLState:28000, ISC error code:335544472]
at org.firebirdsql.gds.ng.FbExceptionBuilder$Type$1.createSQLException(FbExceptionBuilder.java:479)
at org.firebirdsql.gds.ng.FbExceptionBuilder.toFlatSQLException(FbExceptionBuilder.java:293)
at org.firebirdsql.gds.ng.wire.AbstractWireOperations.readStatusVector(AbstractWireOperations.java:132)
at org.firebirdsql.gds.ng.wire.AbstractWireOperations.processOperation(AbstractWireOperations.java:196)
at org.firebirdsql.gds.ng.wire.AbstractWireOperations.readOperationResponse(AbstractWireOperations.java:155)
at org.firebirdsql.gds.ng.wire.version13.V13WireOperations.authReceiveResponse(V13WireOperations.java:105)
at org.firebirdsql.gds.ng.wire.version10.V10Database.authReceiveResponse(V10Database.java:566)
at org.firebirdsql.gds.ng.wire.version10.V10Database.attachOrCreate(V10Database.java:110)
at org.firebirdsql.gds.ng.wire.version10.V10Database.attach(V10Database.java:80)
at org.firebirdsql.jca.FBManagedConnection.<init>(FBManagedConnection.java:148)
at org.firebirdsql.jca.FBManagedConnectionFactory.createManagedConnection(FBManagedConnectionFactory.java:520)
at org.firebirdsql.jca.FBStandAloneConnectionManager.allocateConnection(FBStandAloneConnectionManager.java:65)
at org.firebirdsql.jdbc.FBDataSource.getConnection(FBDataSource.java:117)
at org.firebirdsql.jdbc.FBDriver.connect(FBDriver.java:137)
Commits: 61164a7 9557371 0a4b6de
The text was updated successfully, but these errors were encountered: