Closed pludi closed 3 years ago
Thanks for the report @pludi ! Could you create reproducer files for this? This sounds like a limitation of the underlying keepass-rs dependency and it probably should be addressed there. Still, we might want to add a test for this scenario in here.
Had to gzip
them to get past GitHubs filter.
Test1.kdbx.gz, Password: Test1
Test2.kdbx.gz, Password: Test2
Hmm, works for me but takes 5 minutes or so with RUSTFLAGS="-C target-cpu=native"
. From my debugging, it looks like it has a very high number of transformation_rounds
in the headers of the files, so it runs the encryption very often. This needs to be addressed in keepass-rs
, so I have opened issue 25.
@pludi maybe you want to re-check with version 1.0.1
now. It should have the rustflags set already. It's still slow but I could at least use it on your test files. I have added the test files to the tests as well now, to see that they can be opened.
Ran it after compiling with the optimization RUSTFLAGS
you've posted:
time ~/git/personal/keepass-diff/target/release/keepass-diff --password-a Test1 --password-b Test2 Test1.kdbx Test2.kdbx
- [Root, Test1]
+ [Root, Test2]
~/git/personal/keepass-diff/target/release/keepass-diff --password-a Test1 5,61s user 0,00s system 99% cpu 5,610 total
Quite a lot better :+1:
Okay, I will close this now, the tests run way better in the newest version, with the flags set in .cargo/config.toml
.
What is happening
When comparing databases with at least 1 having a KDBX 3.1 DB format,
keepass-diff
apparently enters an infinite loopWhat should happen
Output of the differences.
Steps to reproduce
keepass-diff
without any special optionsVersions used
keepass-diff
: 1.0.0cargo
/rustc
: 1.41.0