Commit Graph

5 Commits

Author SHA1 Message Date
Clark Boylan 0996ab2857 Make tests' encrypt_secret.py work with python3
This was not compatible with python3 due to encoding issues of the input
and the out. Ensure we pass the input plaintext as bytes to the
encryption routine and use the base64 module to convert the output to
base64.

Change-Id: Ie8b3a8e5c93544e448016829c1071240b68e8957
2017-10-19 18:09:57 +00:00
David Shrewsbury 699a6b22dd Re-enable E305 pep8 errors
E305 expected 2 blank lines after class or function definition

Change-Id: I122ed1bc7e720ec00127cb971b4b353bee2704fd
2017-05-19 09:38:36 -04:00
James E. Blair 717e8e928d Augment references of pkcs1 with oaep
Rightly the system in use is RSAES-OAEP, part of the PKCS#1 standard.
"PKCS#1" is not enough information to communicate to someone the
encryption scheme in use.  Refer to the scheme Zuul uses as "PKCS#1-OAEP"
or "pkcs1-oaep" to clarify.

Change-Id: I74dcde6fa3756354ce65233c64c6189d1b241e90
2017-03-29 12:44:45 -07:00
James E. Blair bf1a4f2192 Isolate encryption-related methods
Create an interface to the cryptography library so that internally
Zuul uses simple facade methods.  Unit test that interface, and
that it is compatible with OpenSSL.

Change-Id: I57da1081c8d43b0b44af5967d075908459c91687
2017-03-29 12:44:44 -07:00
James E. Blair 01f83b73f2 Add secret top-level config object
This adds secrets as a top-level config object, including a new
custom YAML tag to indicate encrypted data.

It also adds a script which encrypts data for use in tests.

Change-Id: I92a6bc048874f8aa4ebe0dd27180b253bede7370
2017-03-29 12:44:39 -07:00