nthdimtech / signet-base

Signet firmware and device interface library
https://www.crowdsupply.com/nth-dimension/signet
GNU General Public License v3.0
15 stars 7 forks source link

keepass import: hierarchy indent increases for each sibling group #25

Closed tuxlifan closed 6 years ago

tuxlifan commented 6 years ago

When importing my .kdbx (which I had converted with keepassxc from an old .kdb) the indent is increasing with each sibling group instead of only for subgroups.

This happens with firmware versions 1.2.1 and 1.2.4 signet-desktop-client version 0.9.9 (compiled from tarball)

In the attached (redacted) screenshot I tried to mark the wrong additional indentation on the left with orange. Additionally, the import does not handle groups with slashes in the name correctly and on one occasion has an unusual ordering of entries and subgroup, both marked with orange vertical bars. Each of the darker colored bars beneath lighter colored one represents an entry in the group (i.e. it would appear in keepassxc in the right pane when the lighter colored group is selected in the tree view in the left pane; in the right half of the screenshot the colored dots represent those entries (but some are omitted for brevity)). Also, the colored bars are cut at an arbitrary length to protect the data but I tried to leave them in approximate relation to better show the hierarchical structure.

Please let me know if you want me to try to create some minimal toy example without real data.

bug-keepass_hierarchy

nthdimtech commented 6 years ago

Thank you for the detailed information. I've fixed the primary issue of the incorrect relationships. The code was repeatedly appending to the same path instead of using a new variable for each sibling.

This issue is actually purely a client issue so it belongs in signet-desktop-client. The firmware is only involved once the client starts submitting "upload entry" requests and it has no context of where the data came from.

The issue of not handling "/" characters correctly is a known issue (at least to me). Each entry has a filesystem like path using "/" as a separator. I currently escape "/" as "//" in the data but the GUI doesn't yet detect it. I'll put in a fix for this soon.

tuxlifan commented 6 years ago

Ah, you beat me to it while writing this :) I had just realized that this issue might rather belong to signet-desktop-client.

I've attached a simple test database for future use. The password is "test".

simpletest.tar.gz

nthdimtech commented 6 years ago

I've fixed the "/" escapement issue now. The simpletest sample seems to import correctly. I'll wait for your confirmation to close.

tuxlifan commented 6 years ago

My entries with slashes are indeed now displayed correctly. Thanks