Commit graph

12 commits

Author SHA1 Message Date
b051b923fd Show entropy to the user when inserting a password
Seems like according to the formula used (`E = L * log2(R)`, where `E` is the ntropy, `L` is the password length and `R` is the quantity of unique characters), a good value is a entropy higher than 60.

This is shown by using two distinct colors when rendering the entropy (dark orange when is lower than 60, and light green when is higher than 60).

Even though entropy is quite important, it would be more useful to take into account dictionaries when calculating the entropy, because raw bruteforce attacks are somewhat mitigated with the usage of a KDF.

Related #1
2023-03-06 00:03:41 +01:00
f4b5a0541d Improve security of encrypted notes
Closes #1.

The password is hashed using Argon2, with the salt being `SHA256(password)`. The output hash is then encoded using hex.

The password-checking function checks if the "note database" is encrypted using the plain password (and returns it) or if it is encrypted using the hashed+salted password (and returns the value). This allows older databases to work properly.

A migration path may be added in the future.
2023-03-05 17:35:04 +01:00
e40c076202 Add "Expectations" to the readme 2023-03-04 14:22:24 +01:00
fcdbfbc932 Implement "hide notes" and "show notes", retry on failed password and minor fixes
* implemented "hide notes"
* implemented "show notes" (internally "unhide")
* improved the title and metadata renderer to use enums and return values instead of callbacks
* added system to retry on password fails (adds `native-dialog` dep for convenience)
2023-03-02 22:40:36 +01:00
19fe7a4ef5 Move App creation into its impl 2023-02-27 18:57:20 +01:00
e839770c9a Add ScrollArea to notes container 2023-02-27 17:19:09 +01:00
b599f628de Sort notes my newest, save note ID in the Note struct, add ID-based note removal
This adds a weird callback-based system to properly update the state once a note is removed.

This system isn't very nice, and it can be quite messy, but I'll improve it in the future
2023-02-27 16:57:00 +01:00
88dd8f034f Add more spacing in the password prompt phase 2023-02-27 15:36:35 +01:00
d801350eb2 Use password TextEdit to hide the password 2023-02-27 15:35:44 +01:00
e1dc5f2d36 Remove terminal when executing 2023-02-27 15:31:17 +01:00
159bf20447 Add readme 2023-02-27 15:28:19 +01:00
4abecc7971 Initial release
This is an initial release, I'm aware that this doesn't have the best structure and that there's lots of copying, but performance isn't relevant right now
2023-02-27 15:22:30 +01:00