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
Get "Different logins in connect and attach packets - client library error" when DENY to create database using valid pair login+password of user who was granted this privilege [CORE4820] #5117
Comments
Modified by: @pavel-zotovAttachment: trace-when-choose-NOT-to-create-database-as-user-john.zip [ 12750 ] |
Commented by: @pavel-zotov It looks like user who was granted to create database can do that only when he first connect to some existent database: C:\TEMP>isql localhost/3333:e30 -user sysdba -pas masterke C:\TEMP>isql localhost/3333:e30 -user john -pas 123 USERJOHN Used firebird.conf:AuthClient = Legacy_Auth,Srp,Win_Sspi
|
Modified by: @AlexPeshkoffassignee: Alexander Peshkov [ alexpeshkoff ] |
Commented by: @AlexPeshkoff Pavel, first of all re # ./isql localhost:employee -user sysdba -pas masterke At the same time you can see that error is not reproduced any more. Please recheck yourself with any snapshot after fix for CORE4811 - I had to enhance CREATE DATABASE statement when implementing it and looks like this issue is also gone. |
Commented by: @pavel-zotov > recheck yourself with any snapshot after fix for CORE4811 Checked on WI-T3.0.0.31855 - all works OK, rollback of transaction and new database creation works fine, no such confusing messages. |
Modified by: @AlexPeshkoff |
Commented by: @AlexPeshkoff Sooner of all has gone when fixing CORE4811 |
Modified by: @AlexPeshkoffstatus: Open [ 1 ] => Resolved [ 5 ] resolution: Cannot Reproduce [ 5 ] Fix Version: 3.0 Beta 2 [ 10586 ] |
Modified by: @pcisarstatus: Resolved [ 5 ] => Closed [ 6 ] |
Submitted by: @pavel-zotov
Is related to CORE4811
Attachments:
trace-when-choose-NOT-to-create-database-as-user-john.zip
On WI-T3.0.0.31845
C:\TEMP>isql localhost/3333:e30 -user sysdba -pas masterke
Database: localhost/3333:e30, User: sysdba
SQL> drop user john; commit;
SQL> revoke all on all from john;
SQL> commit;
SQL>
C:\TEMP>isql localhost/3333:e30 -user sysdba -pas masterke
Database: localhost/3333:e30, User: sysdba
SQL> create or alter user john password '123';
SQL> revoke all on all from john;
Warning: ALL on ALL is not granted to JOHN.
SQL> grant create database to john;
SQL> create database 'localhost/3333:c:\temp\e30n.fdb' user 'john' password '123';
Commit current transaction (y/n)?n
Rolling back work.
Statement failed, SQLSTATE = 28000
Your user name and password are not defined. Ask your database administrator to set up a Firebird login.
-Different logins in connect and attach packets - client library error
SQL>
On LI-T3.0.0.31842
$ /opt/fb30ss/bin/isql localhost/3333:e30
Database: localhost/3333:e30
SQL> drop user john; commit;
Statement failed, SQLSTATE = HY000
record not found for user: JOHN
SQL> revoke all on all from john;
Warning: ALL on ALL is not granted to JOHN.
SQL> commit;
SQL> exit;
$ /opt/fb30ss/bin/isql localhost/3333:e30 -user sysdba -pas masterke
Database: localhost/3333:e30, User: sysdba
SQL> create or alter user john password '123';
SQL> revoke all on all from john;
Warning: ALL on ALL is not granted to JOHN.
SQL> grant create database to john;
SQL> create database 'localhost/3333:/var/db/fb30/e30n.fdb' user 'john' password '123';
Commit current transaction (y/n)?n
Rolling back work.
Statement failed, SQLSTATE = 28000
Your user name and password are not defined. Ask your database administrator to set up a Firebird login.
-Different logins in connect and attach packets - client library error
SQL>
Trace shows that after pressing 'n' (as answer to rollback Tx) user `john` actually DOES some actions - see attach:
2015-05-30T15:10:29.6710 (4092:01FD3B60) FAILED CREATE_DATABASE
localhost/3333:c:\temp\e30n.fdb (ATT_0, JOHN, NONE, <internal>)
2015-05-30T15:10:29.6710 (4092:01FD3B60) ERROR AT JProvider::createDatabase
localhost/3333:c:\temp\e30n.fdb (ATT_0, JOHN, NONE, <internal>)
335544375 : unavailable database
2015-05-30T15:10:29.6710 (4092:01FD3B60) TRACE_FINI
SESSION_2
PS. Why I get "Your user name and password are not defined" if I decided only NOT to *start* 'CREATE DATABASE' statement and wanted to return to SYSDBA session ?
The text was updated successfully, but these errors were encountered: