[Firebird-devel] [FB-Tracker] Created: (CORE-5824) Segmentation fault during install on Linux
Segmentation fault during install on Linux -- Key: CORE-5824 URL: http://tracker.firebirdsql.org/browse/CORE-5824 Project: Firebird Core Issue Type: Bug Components: Engine Affects Versions: 3.0.3 Environment: Ubuntu 14.04, any bitness Reporter: Dimitry Sibiryakov Attachments: bt.txt.bz2 During install gsec crash with segmentation fault error. Backtraces of all threads is attached. It looks like engine gets unloaded while service thread is not finished yet. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://tracker.firebirdsql.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] FBJava plugin issues
On 14/05/2018 09:21, Chmakov, Vladimir wrote: > > Hello, > > > > We are testing FBJava plugin to see how well it suits our purposes. > For the testing we use example provided with the package. It works > well when deployed directly into the DB. However, when JAR is placed > externally, org.firebirdsql.fbjava.examples.fbjava_example example. > FbLogger stops working. The same happening with our own packages. Is > there something that we are missing or doing wrong? > > > > What is meant "placed externally"? Where? Adriano -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
10.05.2018 19:23, Adriano dos Santos Fernandes wrote: On 10/05/2018 13:12, Vlad Khorsun via Firebird-devel wrote: I guess the question is about the case when users have historical data and need to apply old time zone rule to the old data and new timezone rule to the new data. Is it possible\make sence to add a datetime field with "valid from" mark ? Or something like that, some kind of version mark. I really don't understood what you mean. Please give more practical example. Look how MSK time zone was changed at 2014.10.26 https://www.timeanddate.com/time/zone/russia/moscow I think about something like this: ID NameValid from Offset ... MSK 2011.03.27 02:00+4 ... MSK 2014.10.26 02:00+3 Is it makes sence ? Regards, Vlad -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
[Firebird-devel] FBJava plugin issues
Hello, We are testing FBJava plugin to see how well it suits our purposes. For the testing we use example provided with the package. It works well when deployed directly into the DB. However, when JAR is placed externally, org.firebirdsql.fbjava.examples.fbjava_example example. FbLogger stops working. The same happening with our own packages. Is there something that we are missing or doing wrong? Thanks, Vlad -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdotFirebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
On 14/05/2018 10:24, Dimitry Sibiryakov wrote: > > It doesn't need to be DDL. Stored procedures in timezone package > should be enough. > > What are packages for if even developers don't want to use them?.. > > If by developers you mean core team, for example: - Do not improve the hell of not having a system schema. - Some others limitations that system functions, for example, no overloads (or variant type) to accept same function name with different argument types. - Do not do same thins that were being doing in another way, in a new way. Adriano -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Key holder is not used if keyCallback() returned 0
On 05/14/18 15:58, Dimitry Sibiryakov wrote: 14.05.2018 14:28, Alex Peshkoff via Firebird-devel wrote: Number of combination growth as N^2 at least. Writing of separate plugins for each possible use case is... boring. What combinations? Key holder may need to establish connection to client or may not. I see 2 cases here. Ok, you are right, it is not N^2, just N*2. A keyholder that pass-through key directly from application. A keyholder that contain key itself. A keyholder that contain encrypted key and require passphrase from application. A keyholder that reads key from predefined file. A keyholder that reads key from file defined from application. A keyholder that reads key from predefined file and require passphrase from application A keyholder that reads key from file defined by application and require passphrase. Add here more places where key can be stored in and you'll get snowball. When you must write each of these plugins or put all plugins into single module and add records about each of them into plugins.conf (because otherwise it won't work) or explain to an ordinary user how to configure this zoo for each encrypted database separately, you will feel pity that CORE-4482 is never going to be implemented. I certainly agree that there may be a lot of types of key holders but I've just said that some key holders may need tp talk to client, others - not. What about particular kinds of KH certainly we can have an unlimited number of them - just generate new private/public keys pair for data exchange or treat each password as separate kind of KH. :-) But I do not see how is it related with generic part of data exchange rules when transferring a key. PPS. Also I can't imagine people having 7 types of KH on single server :) -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
14.05.2018 14:55, Vlad Khorsun via Firebird-devel wrote: Can I register a new rule for time zones without updating Firebird and the backup/restore process? If so, is there a DLL syntax for registering a new time zone rule? This is interesting and valid question (as for me). With such possibility Lester could add missed historical rules, i think. It doesn't need to be DDL. Stored procedures in timezone package should be enough. What are packages for if even developers don't want to use them?.. -- WBR, SD. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
On 14/05/18 14:02, Adriano dos Santos Fernandes wrote: So he updates original db and ICU and have what he wants. That only works if TZ is installed using the backzone data, and as you have seen this is not the case. The real world solution for this IS TZDist ... and you would simply patch any locally cached data from that. -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rainbow Digital Media - http://rainbowdigitalmedia.co.uk -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
On 14/05/18 13:55, Vlad Khorsun via Firebird-devel wrote: Can I register a new rule for time zones without updating Firebird and the backup/restore process? If so, is there a DLL syntax for registering a new time zone rule? This is interesting and valid question (as for me). With such possibility Lester could add missed historical rules, i think. One of the items on my back burner is a Firebird powered TZDist service which would provide versioned sets of rules and the check facility for individual timezones. The data would simply be a Firebird database ... The problem as always is lack of time due to trying to play catchup with all the other non-BC changes being made to the whole infrastructure! I'm documenting the notes on this service on the http://timedb.co.uk site which is where it is intended to host it. But local copies of the data would allow off-line use and TSDist would then provide patch updates to that data without needing to retransmit the whole TZ database every time! -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rainbow Digital Media - http://rainbowdigitalmedia.co.uk -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
On 14/05/2018 09:30, Lester Caine wrote: > On 14/05/18 13:22, Adriano dos Santos Fernandes wrote: >>> Can I register a new rule for time zones without updating Firebird and >>> the backup/restore process? >>> If so, is there a DLL syntax for registering a new time zone rule? >>> >> Serious, you want resgister custom time zones rules? > > I read that simply as if TZ add new timezones how are the ones hard > coded in Firebird updated ... > As I said previously, this can be flexibilized and put in a file. The time zone list inside Firebird code is only to have fixed IDs for each time zone string. Adriano -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
On 14/05/2018 09:55, Vlad Khorsun via Firebird-devel wrote: > >> Can I register a new rule for time zones without updating Firebird >> and the backup/restore process? >> If so, is there a DLL syntax for registering a new time zone rule? > > This is interesting and valid question (as for me). With such > possibility > Lester could add missed historical rules, i think. > And I see no problem for him, if this is real world issue, I'm certainly that anyone even did tools to help do it with the original or the ICU use of the original db. So he updates original db and ICU and have what he wants. Adriano -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Key holder is not used if keyCallback() returned 0
14.05.2018 14:28, Alex Peshkoff via Firebird-devel wrote: Number of combination growth as N^2 at least. Writing of separate plugins for each possible use case is... boring. What combinations? Key holder may need to establish connection to client or may not. I see 2 cases here. Ok, you are right, it is not N^2, just N*2. A keyholder that pass-through key directly from application. A keyholder that contain key itself. A keyholder that contain encrypted key and require passphrase from application. A keyholder that reads key from predefined file. A keyholder that reads key from file defined from application. A keyholder that reads key from predefined file and require passphrase from application A keyholder that reads key from file defined by application and require passphrase. Add here more places where key can be stored in and you'll get snowball. When you must write each of these plugins or put all plugins into single module and add records about each of them into plugins.conf (because otherwise it won't work) or explain to an ordinary user how to configure this zoo for each encrypted database separately, you will feel pity that CORE-4482 is never going to be implemented. -- WBR, SD. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
On 14/05/18 13:22, Adriano dos Santos Fernandes wrote: Can I register a new rule for time zones without updating Firebird and the backup/restore process? If so, is there a DLL syntax for registering a new time zone rule? Serious, you want resgister custom time zones rules? I read that simply as if TZ add new timezones how are the ones hard coded in Firebird updated ... -- Lester Caine - G8HFL - Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk Rainbow Digital Media - http://rainbowdigitalmedia.co.uk -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-odbc-devel] reading the just generated identity throws an exception
Our problem is that we use ADO in our hole application. We have many places like this in our code: ADODB::_RecordsetPtr prs = NULL; CREATEINSTANCE(prs, ADODB::Recordset); prs->CursorLocation = ADODB::adUseClient; prs->Properties->Item["Update Resync"]->Value = (long)ADODB::adResyncAll; prs->Open(_bstr_t("SELECT * FROM TestTable WHERE 1=0"), (IDispatch *)m_pConnection, ADODB::adOpenKeyset, ADODB::adLockOptimistic, ADODB::adCmdText); prs->AddNew(); prs->Fields->Item["Name"]->Value = "Some Text"; prs->Update(); long id = (long)prs->Fields->Item["ID"]->Value; // throws an DB_E_DELETEDROW prs->Close(); prs = NULL; Is there a way to use INSERT RETURNING in ADO? Michael von Boetticher -Ursprüngliche Nachricht- Von: Dimitry Sibiryakov [mailto:s...@ibphoenix.com] Gesendet: Montag, 14. Mai 2018 12:48 An: firebird-odbc-devel@lists.sourceforge.net Betreff: Re: [Firebird-odbc-devel] reading the just generated identity throws an exception 14.05.2018 12:46, Michael von Boetticher wrote: > I need to know the generated ID for further actions in other subtables. > Has somebody the same issue and even better - a solution for this? Use INSERT RETURNING. -- WBR, SD. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Firebird-odbc-devel mailing list Firebird-odbc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-odbc-devel -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Firebird-odbc-devel mailing list Firebird-odbc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-odbc-devel
Re: [Firebird-devel] Key holder is not used if keyCallback() returned 0
On 05/14/18 13:15, Dimitry Sibiryakov wrote: 14.05.2018 11:57, Alex Peshkoff via Firebird-devel wrote: If key holder is expected to work with both types of keys secrtainly it should try to talk to client. One written only for use of non-client keys should not. Wjat a problem? Number of combination growth as N^2 at least. Writing of separate plugins for each possible use case is... boring. What combinations? Key holder may need to establish connection to client or may not. I see 2 cases here. c) Key plugin is refused by application as a fake one. It's normal error from server's POV. I'm even not sure is it good idea to notify fake plugin that it's attack was detected ;-) Ok, but how can application inform server that this key holder is wrong? Return empty reply. This empty sting will be passed to key holder which can return 1 and still be in use. I see no code in the server that would recognize empty string returned from callback as "switch to the next key holder" instruction. Because it's not servers job to decide try remaining holders or not. Server completely trusts key holders regarding it. If some key holder answered 'yes, I can provide keys' it's enough. BTW, empty reply (why do you call it string? that's not string but binary data) is a definite sign of problems at the client side or network. When delivery or other problems happen reply is empty, and it may be generated by basic FB software. But client when it recognizes key holder can send non-empty data containing any message. For example: hey, I understood your request but for some reasons (appears fake, just wrong, etc.) will not send you a key. I want to emphasize once more - this is information for key holder plugin running, server itself knows nothing except an answer from current key holder which is just a flag meaning continue with next key holder or not. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-odbc-devel] reading the just generated identity throws an exception
14.05.2018 12:46, Michael von Boetticher wrote: I need to know the generated ID for further actions in other subtables. Has somebody the same issue and even better - a solution for this? Use INSERT RETURNING. -- WBR, SD. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Firebird-odbc-devel mailing list Firebird-odbc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-odbc-devel
[Firebird-odbc-devel] reading the just generated identity throws an exception
Version: 3.0.3 32Bit ODB driver: 2.0.5 32 Bit I'm migrating a C++ App from MS-Access to Firebird 3.0. With MS-Access I used the identity column as primary key for table joining. Firebird gives the possibility to create a similar table with: CREATE TABLE TestTable (ID INTEGER GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY, Name VARCHAR(50)); The whole app is written with ADO, so I'd like to use the firebird ODBC. But here occurs the following problem: reading the just generated identity throws an exception, I didn't have with MS-Access. ADODB::_RecordsetPtr prs = NULL; CREATEINSTANCE(prs, ADODB::Recordset); prs->CursorLocation = ADODB::adUseClient; prs->Properties->Item["Update Resync"]->Value = (long)ADODB::adResyncAll; prs->Open(_bstr_t("SELECT * FROM TestTable WHERE 1=0"), (IDispatch *)m_pConnection, ADODB::adOpenKeyset, ADODB::adLockOptimistic, ADODB::adCmdText); prs->AddNew(); prs->Fields->Item["Name"]->Value = "Some Text"; prs->Update(); long id = (long)prs->Fields->Item["ID"]->Value; // throws an DB_E_DELETEDROW prs->Close(); prs = NULL; I need to know the generated ID for further actions in other subtables. Has somebody the same issue and even better - a solution for this? Michael von Boetticher -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Firebird-odbc-devel mailing list Firebird-odbc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/firebird-odbc-devel
Re: [Firebird-devel] Key holder is not used if keyCallback() returned 0
14.05.2018 11:57, Alex Peshkoff via Firebird-devel wrote: If key holder is expected to work with both types of keys secrtainly it should try to talk to client. One written only for use of non-client keys should not. Wjat a problem? Number of combination growth as N^2 at least. Writing of separate plugins for each possible use case is... boring. c) Key plugin is refused by application as a fake one. It's normal error from server's POV. I'm even not sure is it good idea to notify fake plugin that it's attack was detected ;-) Ok, but how can application inform server that this key holder is wrong? Return empty reply. This empty sting will be passed to key holder which can return 1 and still be in use. I see no code in the server that would recognize empty string returned from callback as "switch to the next key holder" instruction. -- WBR, SD. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Key holder is not used if keyCallback() returned 0
On 05/10/18 18:36, Dimitry Sibiryakov wrote: 10.05.2018 17:20, Alex Peshkoff via Firebird-devel wrote: BTW, is there a way to distinguish cases when a) ICryptKeyCallback::callback() returned zero because application key not needed b) Application callback is not set Both cases are normal - return non-zro here. Not in the case if an application callback is required for keyholder to work. c) Key plugin is refused by application as a fake one. In this case it's good to raise an error in status parameter. How? ICryptKeyCallback::callback() has no status parameter. Sorry - I've meant first interface you've asked about. I meant the case when user application don't want to work with _this_ key holder and want server to try a next one if available. No matter what key holders are installed application is using same way to decide will it talk to key holder talking to it currently - and the ony criteria is _can_ it talk to such key holder or not. If it can continue conversation with key holder it sends next portion of data, if not - send empty reply with zero length. If conversation is not complete (and therefore key is not transfered) next key holder will be tried by server. Returning to your cases: a) ICryptKeyCallback::callback() returned zero because application key not needed Well written key holder will not try to talk to client at all if it already has a key... b) Application callback is not set Server does not know in advance is there callback at client or not. I.e. it will anyway send request to client and get empty answer from it. I agree that something might be optimized here knowing the reason of error return (next KeyHolders might get error as an answer at once). May be in next protocol version... c) Key plugin is refused by application as a fake one. It's normal error from server's POV. I'm even not sure is it good idea to notify fake plugin that it's attack was detected ;-) -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel
Re: [Firebird-devel] Virtual table for time zones
Adriano dos Santos Fernandeswrote Thu, 10 May 2018 18:21:49 +0300: Hi! I want to create a virtual table that lists available time zones. For now there is RDB$ (non-virtual), MON$ (virtual, but all about monitoring), SEC$ (security plugin). What prefix should TIME_ZONES have? Adriano I'm wondering how the time zones will be updated? Will they be distributed as a separate file in Firebird? Can I register a new rule for time zones without updating Firebird and the backup/restore process? If so, is there a DLL syntax for registering a new time zone rule? -- Simonov Denis -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel