Skip to content

Replaced the encryption with age #67

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

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

raphaelahrens
Copy link
Contributor

The old encryption protocol has some flaws.

In this commit the encryption is replaced by the age library.

The old encryption protocol has some flaws.

In this commit the encryption is replaced by the age library.
@raphaelahrens
Copy link
Contributor Author

raphaelahrens commented Mar 4, 2025

BTW this is about #35

What is currently missing is how to deal with old encrypted files.
Maybe an alternative tool to decrypt the old files?
maybe it would also be a good idea to have some form of version header, so that this issue does not come up with future changes.

Further could this change also fix #63.
I also found an issue if you run

tuckr encrypt g1 ~/first.txt
tuckr encrypt g1 ~/second.txt

It is possible to use different passwords for the same group (g1).

This later is an issue when running

tuckr decrypt g1

Since there you can only give one password and this just fails as soon as the password was wrong.
I have not tested this with the old code.

@RaphGL
Copy link
Owner

RaphGL commented Mar 4, 2025

What is currently missing is how to deal with old encrypted files.
Maybe an alternative tool to decrypt the old files?
maybe it would also be a good idea to have some form of version header, so that this issue does not come up with future changes.

Yeah, having a header and a tool to port over would be great. We could also provide a single release warning when people attempt to use secrets asking them to port over and maybe provide a link to the tool.

It is possible to use different passwords for the same group (g1).

Yeah, secrets is not as developed as the other parts. Symlinks have been consuming most of my time on the project. If you feel like trying to tackle it feel free to do so, otherwise just create an issue and me or someone else will handle it later.

@@ -20,3 +20,4 @@ sha2 = "0.10"
sys-locale = "0.3.2"
tabled = {version = "0.10", features = ["color"]}
zeroize = "1.5"
age = "0.11"
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You forgot to remove chacha20poly1305 and sha2 as dependencies

@RaphGL
Copy link
Owner

RaphGL commented Mar 4, 2025

by the way, just as a heads up, don't worry too much about internationalization for now.
I'll go over every output string in the program and make sure it's translated properly before I ship the next tagged release

@RaphGL
Copy link
Owner

RaphGL commented Apr 1, 2025

By the way I haven't attempted to merge your PR because you have it marked as a draft. But there doesn't seem to be any work going on in this. Should I merge?

@raphaelahrens
Copy link
Contributor Author

Sorry, I got a bit distracted.😅

The main reason for it being a draft is that there are the questions on

  • how to deal with backwards compatibility and
  • how to handle the password mishandling.

If you want/can finish it, that is fine with me.
If you want me to do it just say so.

@RaphGL
Copy link
Owner

RaphGL commented Apr 1, 2025

I'm fine with it either way tbh. But if you want me to do it it's gonna be a while before it's all implemented, since I wanna improve the symlink handling first and I'm working on the filetree-refactor so I can try and fix the longest standing issues in the project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants