Giter VIP home page Giter VIP logo

aes256cli's Introduction

aes256cli

A simple file encrypt/decrypt tool.

The tool uses Go's built-in crypto/aes library to encrypt the input file with AES-256.

Caveat

Currently, the aes256cli reads the entire input file in memory before encrypting it and writing it to disk. This means that you can easily run out of memory if you try encrypting a large file. I hope to address this in the near future.

Installation

If you have Go installed:

go install github.com/ro-tex/aes256cli@latest

If you prefer a binary, you can download a Linux amd64 one from https://github.com/ro-tex/aes256cli/releases.

Usage

To encrypt a file:

aes256cli -e myFile.dat

To decrypt a file:

aes256cli -d myFile.dat.aes

To see the usage information run the tool without parameters:

$ aes256cli 
You must choose to either encrypt (-e/--encrypt) or decrypt (-d/--decrypt) a file.

Usage of aes256cli:

aes256cli [operation] FILENAME

  -d    decrypt a file
  -decrypt
        decrypt a file
  -e    encrypt a file
  -encrypt
        encrypt a file

aes256cli's People

Contributors

ro-tex avatar

Stargazers

Aydin Manzouri avatar E. Recio avatar Art Popp avatar

Watchers

 avatar

aes256cli's Issues

Don't read the entire input file in mem

Problem

Currently, I'm reading the entire input file in memory, where it is then being encrypted before being written to disk. This uses a lot of memory and might even make it impossible to use the tool for certain tasks, e.g. encrypting a file larger than 50% of RAM.

Possible solutions

Check for compatible approaches that use either chunking (AES-256 is a block cipher, after all) or streaming.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.