euca-bundle-image occasionally chokes on bad RNG output
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
euca2ools |
Confirmed
|
Low
|
Unassigned |
Bug Description
When the encryption code in euca-bundle-image generates a key and IV to use when encrypting the image, the random number generating algorithm occasionally yields a value that causes an exception when that value is handed to unhexlify:
Traceback (most recent call last):
File "/usr/bin/
main()
File "/usr/bin/
encrypted_file, key, iv, bundled_size = euca.encrypt_
File "/usr/lib/
k=EVP.
TypeError: Odd-length string
Currently, when this occurs, the program terminates unsuccessfully. Because this happens very rarely, I will change this behavior to print a short warning that contains the unusable key and IV, ask the user to report those values in this bug, and then retry encryption with a new key and IV so the command can return successfully.
Future users: if you see a message such as the following when you run euca-bundle-image, please report the "k" and "iv" values it indicates in a comment on this bug:
WARNING: retrying encryption to work around a rare RNG bug
Please report the following values to Eucalyptus Systems at
https:/
this issue.
k: 0x9680c0e4f42da
iv: 0xe8fe9e11b31ba
affects: | eucalyptus → euca2ools |
description: | updated |
Confirmed on the Eucalyptus forums: http:// open.eucalyptus .com/forum/ euca-bundle- image-error- typeerror- odd-length- string