u/Frozenjob

git-remote-pqcrypt: Git remote helper and CLI tool for encrypted repository storage

I wanted my private projects to be accessible trough github on multiple different devices and have the ability to share access to other people, while at the same time having it encrypted at rest so github couldnt use it for AI training.

The first tool I found for this was gcrypt. It was missing support for anything other than PGP, written entirely in bash, lacked CLI tooling and it is dormant with last update being in 2024 and one of the biggest problem of all pushes being treated as force pushes with high chance of accidental data loss.

So I built an experimental where the binary acts both as a git remote helper and a unified CLI for key generation, user management and repository initialization, and supports local, (optional SFTP) and Git-backed storage backends. Encryption uses XWing for key encapsulation and XChaCha20Poly1305 for data encryption. It treats pushes like normal git with fast forward checks being the default and not allowing overwriting of remote unless force mode is used.

DISCLAIMER: THIS IS AN EXPERIMENTAL PROJECT, there hasnt been a formal security audit. DO NOT rely on this for any critical repositories.

Github

reddit.com
u/Frozenjob — 3 days ago
▲ 4 r/rust

git-remote-pqcrypt: Experimental Rust Git remote helper for encrypted repository storage

I wanted my projects to be accessible trough github on multiple different devices and have the ability to share access to other people, while at the same time having it encrypted at rest so github couldnt use it for AI training.

The first tool I found for this was gcrypt. It was missing support for anything other than pgp, written entirely in bash, lacked CLI tooling and it uploads the whole git repository each time you push to remote instead of using git packfiles to push only changes and it is dormant with last update being in 2024.

So I built an experimental alternative in Rust. Instead of re-uploading the entire repository history on every push, it encrypts and transfers only the new packfiles Git generates for that push. The binary acts both as a git remote helper and a unified CLI for key generation, user management and repository initialization, and supports local, SFTP and Git-backed storage backends. Encryption uses XWing for key encapsulation and XChaCha20Poly1305 for data encryption.

DISCLAIMER: THIS IS AN EXPERIMENTAL PROJECT, there hasnt been a formal security audit. DO NOT rely on this for any critical repositories.

Feel free to review or make a issue if you see a problem with it.

Github

u/Frozenjob — 22 days ago