-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Improve p12 passphrase generation #654
Comments
We're already doing it this way for CA_password, and ansible's to_uuid is problematic as it uses uuid v5 under the hood (trailofbits#654)
The main problem with #655 is that it retains the 32-bit passwords, which my i7 laptop with https://github.com/crackpkcs12/crackpkcs12 seems to get 7,000/sec with (about a week of walltime for 2 cores). |
We're already doing it this way for CA_password, and ansible's to_uuid is problematic as it uses uuid v5 under the hood (#654)
This buys us an extra 16bits of password guessing entropy by expanding the characterset from hex to [a-zA-Z0-9_@]
Taking to account that we store the p12 password in plaintext, does this issue make any sense? |
Am I the only one that doesn't use mobileconfigs? :D I traditionally rely on .p12 certs not being trivially crackable, but perhaps I'm weird. |
Yes, but we still need to get rid of plaintext passwords |
Understood - is it worth addressing that in a separate issue? |
…ts#655) We're already doing it this way for CA_password, and ansible's to_uuid is problematic as it uses uuid v5 under the hood (trailofbits#654)
…ts#655) We're already doing it this way for CA_password, and ansible's to_uuid is problematic as it uses uuid v5 under the hood (trailofbits#654)
See
algo/playbooks/facts/main.yml
Line 32 in 8da53f8
Under the hood, ansible uses python's uuid5 function https://github.com/ansible/ansible/blob/7e71bdd3a0fd38b089464c884154e2152507d61f/lib/ansible/plugins/filter/core.py#L308
Which is implemented without adding any additional entropy of its own, unlike uuid4():
https://hg.python.org/cpython/file/2.7/Lib/uuid.py#l586
Which appears to result in deterministic output given the same input:
I could be wrong, but I worry that this reduces the entropy in p12 secrets to the time at which they were created
The text was updated successfully, but these errors were encountered: