diff options
author | Paul Kehrer <paul.l.kehrer@gmail.com> | 2013-11-18 14:11:55 -0600 |
---|---|---|
committer | Paul Kehrer <paul.l.kehrer@gmail.com> | 2013-11-18 14:11:55 -0600 |
commit | c985dbb47be06cbb39ecceba9bfbe70088e10fcf (patch) | |
tree | f407d81ec43a0751be072a407633227313a25b75 /tests/utils.py | |
parent | 984eeeb388e79db6354efd884e0f5d8b7b069560 (diff) | |
download | cryptography-c985dbb47be06cbb39ecceba9bfbe70088e10fcf.tar.gz cryptography-c985dbb47be06cbb39ecceba9bfbe70088e10fcf.tar.bz2 cryptography-c985dbb47be06cbb39ecceba9bfbe70088e10fcf.zip |
modify nist loader to support multi-line GCM sections
Diffstat (limited to 'tests/utils.py')
-rw-r--r-- | tests/utils.py | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/tests/utils.py b/tests/utils.py index 8fa9af92..988a80b0 100644 --- a/tests/utils.py +++ b/tests/utils.py @@ -40,7 +40,15 @@ def load_nist_vectors(vector_data): # Look for section headers if line.startswith("[") and line.endswith("]"): - section = line[1:-1] + if "=" in line: + # GCM section headers + if "Keylen" in line: + section = line[1:-1] + else: + section += line[1:-1] + else: + # non-GCM section headers + section = line[1:-1] continue if line.strip() == "FAIL": |