Skip to content
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

Possible security issues in encryption #330

Open
fortran77 opened this issue Feb 20, 2019 · 1 comment
Open

Possible security issues in encryption #330

fortran77 opened this issue Feb 20, 2019 · 1 comment

Comments

@fortran77
Copy link

I know this project is not being actively updated currently, but someday when it is active again, I hope the following will be kept in mind.

In release 1.9.1, the code in gmvault_utils.py makes a random password like this:

def make_password(minlength=8, maxlength=16):
  ...
    return ''.join([random.choice(letters) for _ in range(length)])

The python documentation found at https://docs.python.org/2/library/random.html says that the functions in the random module generate completely deterministic random numbers and are “completely unsuitable for cryptographic purposes.” (Emphasis added.)

The documentation recommends using os.urandom() or SystemRandom if you require a cryptographically secure pseudo-random number generator.

Also the length of the random number is currently forced into the range 8..16 characters, which is only 48..95 bits (based on 5.95 bits per alphanumeric character). Better would be 256 bits (to make it quantum-computing-proof) or 43 characters. Since the user is not entering the key manually, it can be made long.

Also, AES is in much more common use, so its code is probably much better debugged, and almost all newer CPUs include AES in hardware. So for better security and performance, in the long run AES should replace Blowfish.

@aztazt
Copy link

aztazt commented Sep 4, 2019

Thanks for pointing that out

This was referenced Oct 27, 2020
dotlambda added a commit to dotlambda/nixpkgs that referenced this issue Mar 8, 2021
The git repo has not seen any commit since 2016.
It is insecure: gaubert/gmvault#330
Login is mostly broken: gaubert/gmvault#335
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

No branches or pull requests

2 participants