projects
/
gpg-migrate.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
309ff8a
)
Stub out a PGPPacket._key_size dictionary
author
W. Trevor King
<wking@tremily.us>
Sat, 21 Dec 2013 18:10:00 +0000
(10:10 -0800)
committer
W. Trevor King
<wking@tremily.us>
Mon, 23 Dec 2013 21:41:05 +0000
(13:41 -0800)
The string-to-key algorithm needs to know the key size, so record an
algorithm's key size (in bits) for easy lookup. The AES key sizes
seem pretty obvious ;).
gpg-migrate.py
patch
|
blob
|
history
diff --git
a/gpg-migrate.py
b/gpg-migrate.py
index f8c1fd488934357da431f9f17940c46d0486ed6f..d8ae5ac12bd967e52f17d866a4a0a739642a0231 100755
(executable)
--- a/
gpg-migrate.py
+++ b/
gpg-migrate.py
@@
-123,6
+123,12
@@
class PGPPacket (dict):
'tripledes': _crypto_cipher_des3,
}
+ _key_size = { # in bits
+ 'aes with 128-bit key': 128,
+ 'aes with 192-bit key': 192,
+ 'aes with 256-bit key': 256,
+ }
+
_compression_algorithms = {
0: 'uncompressed',
1: 'zip',