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
Advanced Sync / Merge #17
Comments
Hi Mark, first of all, great work with your KeePass oriented app for iOS/MacOS, any predictions whether that feature could be implemented ? that would greatly help with choosing your app as the only one for a solution with e.g. self-hosted nextcloud in order to safely sync keepass master db between multiple platforms |
Thank you @jacek-1! This feature is a bit of a tough one. I think the window for issues here is probably reasonably small for a lot of users. It is also dependent on a few features that need to be implemented first.
I think there are probably some other features that take precedence before this, so I think I'd really struggle to give you an ETA, but if pressed, I'd say in the next 3-6 months, hopefully sooner. You could always open your databases in 'Read-Only' mode if you're concerned about overwriting a newer edit for the moment. This way Strongbox can/will not write back to storage. |
perfectly fine with it, thanks for giving details. |
It would be really nice to have this. I switched to your (paid) product due to one of your competitors failing to do this. As a forgetful guy, and app(s) without transparency it's very easy to lose passwords when things change on both sides. I lost numerous passwords in my database do to your competitor apparently deciding to save blindly, not caring that the hosted file may have been changed. In these cases the product didn't update it's cached copy (and didn't notify that it failed) which would have included the updated passwords, and then overwrote with old data along with the one entry I added from my device. |
That's fair. I'd like to get this done, but it's a little back on the roadmap at the moment, basically because it's a reasonably big dev task. Hopefully I'll be able to get to this in the next couple of months. |
That's fine, just adding my 'vote of support' and giving a use case where it might be more important to more users. Keep up the good work! |
I’ll become a paid customer as soon as this is implemented and working. |
Hey @mmcguill - Do you have any news about the schedule of this feature? |
Hi @Slummi - I'm afraid not... It has slipped back on the roadmap as other problems and support issues consume resources. I would hope to have something here within the next 3-6 months, but unfortunately it is hard to put a good estimate on this because it's quite a niche feature with a heavy development load |
We are becoming more and more mobile these days so I find myself editing on mobile devices far more than traditional desktops. So being able to edit and then sync from mobile is a top 3 feature need for me. Thanks! |
Short question, because you recently started implementing of advanced sync: Are you still planning to support UUID sync for KeePass databses and maybe also lock files (for read-only access, if a database has been opened by another application)? |
Hi @Slummi, Yes, this is coming in the next few weeks. The first priority was supporting the ability to detect conflict situations and background syncing... This is pretty much done now barring some initial bugs/problems that need to be ironed out. The next stage is to offer the ability to "Merge" the local/remote copies (optionally automatically without asking). This is the "UUID Sync" I assume you're speaking about. It's a big feature (complex algorithm to get right). As to Locking Files, I don't see this as connected to the Advanced Sync feature and I'm not sure how it would work. How would Strongbox detect that the database has been opened by another app? Why would you want need this feature if you have the "Merge/UUID Sync" function? |
Hi @strongbox-mark Yes, merging the local/remote copies is what I mean with UUID sync. I just wanted to know, if it's still on the roadmap. Locking files was just an idea, because it's an (optional) available function of KeePass, if you don't use the sync feature. Here is some information about locking files:
Source: https://keepass.info/news/n120105_2.18.html (KeePass 2.18 change log) And the KeePass documentation about multi-user features: https://keepass.info/help/base/multiuser.html |
Got it. Yeah, I don't think the lock file is a runner for Strongbox. With all the different storage cloud providers and permissions issues of listing/checking for the existence of a lock file it would be more hassle than I think it's worth... Merge/Sync should have you covered in the next few weeks :) |
Hi @strongbox-mark, Is it intended that, when comparing a KeePass 2 4.0 and a KeePass 2 3.1 database, the message comes that the comparison is only partially supported? In the current test scenario (comparison of a 3.1 DB with a 4.0 DB) the simple comparison says that the database is 97.2% different (completely different databases compared), while the comparison for merging says that the databases are identical. |
The "Compare Partially Supported" message is also displayed when you compare two KeePass 2 4.0 databases that have different settings (e.g. encryption, key derivation). I guess that you check too many database attributes. Format version should be enough. |
Hi @Slummi - This looks to be a bug alright, it should only happen if you use different master credentials for the databases. Do you have a different master passwords on these databases? If so, you could test by setting the second master password to the same as the first. To any other followers of this issue, you can now start using the Advanced Sync feature in 1.51.2 available on the App Store. |
Hi @strongbox-mark - You're right. That message is displayed when the master credentials are different. But what do the master credentials have to do with the KeePass format. During this test I found two other bugs.
|
Yeah, long story but your first question and 2nd point are related. Your 1st point sounds like a bug though too... |
That's very interesting @Shad0wHawk. Some questions:
|
If I copy the database without saving and compare then they are identical. If I make any changes that result in a save, this issue occurs where it detects differences in the auto type value. I’ve noticed it also states the attachments are different even though they haven’t been changed either. This only applies to entries with an attachment. The auto type discrepancy only applies to entries with an auto type string. I’m using 1.51.2 so the latest version. |
I didn’t answer your last question in my last post. The compare correctly detected the attribute that changed for the entry that was changed except it also included the auto type change which is not accurate. |
Can you tell me:
|
In general, I use the Windows Keepass app, iOS Strongbox and MacOS Strongbox apps to update the database. This test database was last updated in Strongbox on iOS to test the comparison feature. Prior to that it was updated using Keepass 2.47 on Windows. To create a local copy, I long pressed the source database in Strongbox and made a copy. If I compare at this point, they are the same. If I then update one of the databases (source or target), I get the large delta I mentioned previously. I do use the auto type feature in Windows, MacOS and iOS. Both databases use the same credentials. If I open, edit, and save both the original database and the copy on Strongbox, the compare doesn’t show the auto type and attachment deltas. The auto type and attachment deltas seem to occur if I compare a database that was edited in Strongbox with a database that was last saved in Keepass for Windows. |
That's "weird"... Your answer to question 2 is very unexpected and so I just want to be absolutely 100% definite about it. You are 100% sure that your original database (before your test edit) was last saved/edited by Strongbox? |
I updated my last comment with additional info. It was last saved using Keepass 2.47 for Windows. My database resides in OneDrive and syncs between applications and devices. Sometimes I use Keepass to edit and save, other times Strongbox. I’ve never had any issues with this method until now. |
Yeah, that's exactly what I thought. This looks like a slight difference between how KeePass on Windows serializes out and how Strongbox does. I should be able to reproduce this and eliminate the spurious diff. Thanks @Shad0wHawk |
I hope that helps. Hopefully you get it figured out. I really like the compare functionality and plan on using it once this issue is resolved. Thanks for all of your hard work implementing this feature. |
For sure, very helpful. There's alway some teething issues like this with new features, especially one this complex. We'll get there. |
I just realized these changes show up under the “History will Change” section if I select Compare and Merge instead of Simple Compare. So maybe this only impacts the historical entries in some way. Or maybe that means the a historical item will be created for those entries. It’s interesting that I get substantially different results if I use Simple Compare (59.7% delta—800+ records delta) versus Compare and Merge (52.3% delta—700+ records delta). Another interesting tidbit is that if I compare and merge the two databases and then recompare, only the true changes (1 record) merged, with those auto type entries still showing a delta that isn’t resolved. |
@Slummi - Your issues should be fixed now with the release of 1.51.4 - could you verify? @Shad0wHawk - Your issues should also be fixed with that release - could you check? |
Hi @strongbox-mark, Looks good! Changing the master credentials works again in 1.51.4 and you have to enter the credentials for the second database if they are different. There's also no message that comparision is partially supported if the database format is the same, but the credentials are different. One suggestion for improvment: |
Great, yeah for sure, I agree with you on the improvement suggestion, keep an eye out for that in the next release. |
I just tested it and it works as expected. The false positives are no longer showing. Nice job fixing that so quickly. I agree with @Slummi about being able to go back a screen in the comparison. I noticed that as well and had the same thought. |
That's great thanks @Shad0wHawk - I'm going to close this one out, please open new issues if necessary. Edit: Blog Post up here: https://strongboxsafe.com/updates/advanced-sync-and-auto-merge-ios/ |
KeePass sync involves comparing the database before writing changes back to it. Comparing records by UUID and timestamp, and then taking the latest entry, and moving the older staler entry to History. This allows for multiple editors to work on the Database and avoid sync conflicts.
It would involve comparing the XML documents, and so applies only to KeePass 2 Databases. It also depends on the History feature which needs to be implemented separately. More info:
https://keepass.info/help/v2/sync.html
The text was updated successfully, but these errors were encountered: