You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
* commit 23e859dfd2e095bd71be0290b7c99f0016c6bf4e (HEAD, tag: android-o-mr1-iot-preview-8, m/master, aosp/o-mr1-iot-preview-8, aosp/master) |\ Merge: 70d9b6a 9432381 | | Author: Treehugger Robot <treehugger-gerrit@google.com> | | Date: Wed Mar 28 13:02:01 2018 +0000 | | | | Merge "Throw ShortBufferException in RSA CipherSpi." | | | * commit 943238191685c85367fb0c51fb0a5f124b361876 |/ Author: Adam Vartanian <flooey@google.com> | Date: Tue Mar 27 14:16:53 2018 +0100 | | Throw ShortBufferException in RSA CipherSpi. | | The Javadoc for javax.crypto.Cipher.doFinal() and friends states that | Ciphers should throw ShortBufferException when given an output buffer | that's too small to hold the output. BC does this in its other | classes, but the RSA implementation doesn't check the output buffer | size and just throws ArrayIndexOutOfBoundsException when it tries to | fill the output buffer. | | This is bad not only because it's the wrong exception, but because it | modifies the Cipher object's internal buffers when it does it, which | means that passing a too-short buffer and then calling doFinal() again | with a properly-sized buffer will result in incorrect output. | | This fixes tests that have been added for this case in Conscrypt | upstream. | | Test: cts -m CtsLibcoreTestCases -t com.android.org.conscrypt.javax.crypto | Change-Id: Ieac98be5b9574006f1409911103487b8b55bb94e |
7 years ago | |
---|---|---|
.. | ||
bcpkix | 7 years ago | |
bcprov | 7 years ago | |
Android.bp | 7 years ago | |
CleanSpec.mk | 7 years ago | |
MODULE_LICENSE_BSD_LIKE | 7 years ago | |
NOTICE | 7 years ago | |
OWNERS | 7 years ago | |
README.android | 7 years ago | |
bouncycastle.version | 7 years ago | |
jarjar-rules.txt | 7 years ago |
README.android
Bouncy Castle on the Android platform. --- The code in this directory is based on $BOUNCYCASTLE_VERSION in the file bouncycastle.version. See the in-file change markers for more information on how the code differs from $BOUNCYCASTLE_VERSION. Porting New Versions of Bouncy Castle. -- The following steps are recommended for porting new Bouncy Castle versions. 1) Retrieve the appropriate version of the Bouncy Castle source from www.bouncycastle.org/latest_releases.html (both bcprov-jdk*-*.tar.gz and bcpkix-jdk*-*.tar.gz files). Check the checksum (found at http://bouncycastle.org/checksums.html) with: md5sum bcprov-jdk*-*.tar.gz sha1sum bcprov-jdk*-*.tar.gz md5sum bcpkix-jdk*-*.tar.gz sha1sum bcpkix-jdk*-*.tar.gz 2) Submit the code to the upstream-master branch: a) Create a new branch tracking upstream-master git checkout -b upgrade-to-xxx --track aosp/upstream-master b) Update the variables in bouncycastle.version. c) Expand the source from the .tar.gz files d) Replace bc{prov,pkix}/src/main/java/org with the equivalent source directory e) Ensure any new files are added git add bc{prov,pkix} f) Commit the change git commit -a -m 'bouncycastle: Android tree with upstream code for version X.XX' g) Get the change reviewed repo upload . -D upstream-master 3) Merge the code into the master branch a) Create a new branch repo start merge-xxx b) Merge the changes in git fetch aosp upstream-master git merge aosp/upstream-master c) Resolve any conflicts. Some common cases: * If upstream changed a file that's deleted locally, we probably don't need it * If upstream added a file to a directory we deleted, we probably don't need it d) Confirm all changes git diff aosp/master e) Run the tests, commonly at least cts -m CtsLibcoreTestCases cts -m CtsLibcoreFileIOTestCases cts -m CtsLibcoreJsr166TestCases cts -m CtsLibcoreOjTestCases cts -m CtsLibcoreOkHttpTestCases cts -m CtsLibcoreWycheproofBCTestCases e) Get the change reviewed repo upload .