+1
Under review

Do not open database on start

Grigory Mazkevich 10 years ago updated by Alex Jenter 10 years ago 9
Pre-req:
1. CintaNotes with auto-start enabled
2. DB file inside crypto-container
Case:
If CintaNotes auto-start option enabled, program shows error "DB file not exists" because crypto-container is not mounted.
It would be better to open database on first window show instead.

Finally, my proposal is change CintaNotes start behavior a bit to make possible case: start user session, mount crypto-volume, then press HotKey and do not have any errors.
main-window error startup external
Hello Grigory,
Thanks for the idea! Have you tried some delayed start options, so that CintaNotes only starts when the crypto container is already mounted? (The most primitive thing to do would be write a bat file that would mount the container first, and then run CintaNotes, but there are better alternatives, e.g. using the Task Scheduler).
I can recommend "startup delayer": http://www.r2.com.au/page/products/show/startup-de...
which I find to be very useful anyway.
Guys, thank you for the proposal, but I prefer minimal set of tools on the PC and GUI instead of old console way. ;) So, I mount my volumes manually when they required.
You can see the behavior I described in KeePass tool (popular password storage tool). It starts minimized to tray and shows login screen only on first use and then open DB file. I think it is good way: acquire resources only when they are required and free asap.
BTW, if you plan to implement whole-DB/per-record encryption you will need to implement similar behavior anyway. Records must not stay decrypted in memory all the time.
Ok, I understand your concerns about manual mounting. But there's one thing which bugs me here: suppose CN is run without db, and than the user presses Ctrl+F12 to clip text - without opening the app.. what should happen then? If logon screen appears, it will be unexpected for the user - s/he just wants to save some text, not access encrypted data.
Hello Alex, lets see what happens on clipping hot-key:
CN tries to open DB.
If DB not available or encrypted - show DB open/selection dialog inside disabled note edit dialog. Like the web-sites do when they need auth before post message: keep message faded on background and show auth form on top.
If DB not encrypted and available - just open it and add note.
Well the setting "show editor after clipping" might not be activated. But otherwise you have a point, maybe displaying the logon dialog is not that bad, at least the user knows he has the notebook encrypted.
BTW when should the notebook be encrypted again, what do you think? When CN is minimized to tray? I doubt that the notebook should be freely accessible till the next reboot.. Maybe after an inactivity timeout? Do you know how other apps deal with this? Thanks
As I know, most used case is lock by time-out.
Time-out is long enough to track active user. It means cache hit reset counter again.
One more time-out case if global user inactivity: no mouse movement, no keyboard events.
Also possible:
* Emergency lock (by hot-key);
* Desktop/Hibernate/etc lock. Win+L locks Desktop, but also flush data and sync DB. This case is not simple because some crypto-tools can force encrypted volumes unmount the same time. But some workarounds are possible to prevent data loss. At least you can try to keep encrypted DB in memory until storage appears again.
 * Lock on CN minimize, etc
Check the KeePass - Tools - Options - Security to see different options.

May be you do not need them all now. At least the "delayed DB open" feature can be implemented w/o all above. ;)
Grigory, thanks a lot for your input. We'll definitely take it on board when it comes to implementation of whole DB encryption. Regarding the "delayed DB open" feature, let's see if it gets people's votes.