diff options
author | Nick Mathewson <nickm@torproject.org> | 2011-06-02 12:32:59 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2011-06-03 11:31:19 -0400 |
commit | bbf2fee8ff7bbb8f645b7d973cd84bc97e93ae54 (patch) | |
tree | d9db511a467af11a94c9e4d375f14cc9383638bc /changes | |
parent | 1d8bcba067ef8d96ebe022f06459d55c308343ec (diff) | |
download | tor-bbf2fee8ff7bbb8f645b7d973cd84bc97e93ae54.tar.gz tor-bbf2fee8ff7bbb8f645b7d973cd84bc97e93ae54.zip |
Reject 128-byte keys that are not 1024-bit
When we added the check for key size, we required that the keys be
128 bytes. But RSA_size (which defers to BN_num_bytes) will return
128 for keys of length 1017..1024. This patch adds a new
crypto_pk_num_bits() that returns the actual number of significant
bits in the modulus, and uses that to enforce key sizes.
Also, credit the original bug3318 in the changes file.
Diffstat (limited to 'changes')
-rw-r--r-- | changes/bug3318 | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/changes/bug3318 b/changes/bug3318 index 38991c4b1d..8a3c27825f 100644 --- a/changes/bug3318 +++ b/changes/bug3318 @@ -1,3 +1,7 @@ o Minor bugfixes: - Fix a log message that said "bits" while displaying a value in - bytes. Fixes bug 3318; bugfix on 0.2.0.1-alpha. + bytes. Found by wanoskarnet. Fixes bug 3318; bugfix on + 0.2.0.1-alpha. + - When checking for 1024-bit keys, check for 1024 bits, not 128 + bytes. This allows Tor to correctly discard keys of length + 1017 through 1023. Bugfix on 0.0.9pre5. |