commit | 193709736fd7d43c407bf73841fa6dbfca8fbbb3 | [log] [tgz] |
---|---|---|
author | Adam Langley <agl@golang.org> | Fri Feb 18 11:31:10 2011 -0500 |
committer | Adam Langley <agl@golang.org> | Fri Feb 18 11:31:10 2011 -0500 |
tree | e0b0ec25414f3c5cda142ced787e661c86a210af | |
parent | 547918e3632121cd2fa40e8d6d8f5f0b2e2778c2 [diff] |
crypto/rsa: left-pad OAEP results when needed. PKCS#1 v2.1 section 7.1.1 says that the result of an OAEP encryption is "an octet string of length $k$". Since we didn't left-pad the result it was previously possible for the result to be smaller when the most-significant byte was zero. Fixes #1519. R=rsc CC=golang-dev https://golang.org/cl/4175059