A secure file encryption and decryption tool written in Go. This application provides a simple command-line interface for protecting files using strong encryption standards.
- AES-256-GCM encryption: Industry standards encryption
- Argon2id key derivation: Memory-hard key derivation function (Time=1, Memory=64MB, Threads=4) for modern security.
- Random salt and nonce generation: Prevents rainbow table attacks
- Cross-platform support: Works on Windows, Linux, and macOS
- Secure password input: Passwords are hidden during entry
- Supports all file types: Encrypt any file format
- Go 1.16 or higher (https://go.dev/doc/install)
- Git (for cloning the repository)
-
Clone the repository:
git clone https://github.com/Dimm377/Go-Encryptor-Tools.git cd Go-Encryptor-Tools -
Install dependencies:
go mod tidy
The tool provides three main commands:
go run . encrypt [file_path]go run . decrypt [file_path]go run . helpEncrypt a text file:
go run . encrypt testing.txtDecrypt the same file:
go run . decrypt testing.txt-
Encryption Process:
- A random 16-byte salt is generated
- PBKDF2 is used to derive a key from the password using the salt
- A random 12-byte nonce is generated
- The file content is encrypted using AES-256-GCM
- The salt, nonce, and ciphertext are concatenated and written to the file
-
Decryption Process:
- The salt, nonce, and ciphertext are extracted from the file
- The same PBKDF2 process is used to derive the key from your password
- AES-256-GCM decryption is performed on the ciphertext
- The original file content is restored
- The original file will be overwritten with encrypted/decrypted content
- Always keep a backup of important files before encryption
- Losing your password will result in permanent data loss
- Make sure you remember the password you entered
- This tool was created for personal use only
If you encounter any issues or have questions, please open an issue in the GitHub repository.