aboutsummaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.gpg.bc.test
Commit message (Collapse)AuthorAgeFilesLines
* Prepare 5.13.2-SNAPSHOT buildsMatthias Sohn2022-06-142-5/+5
| | | | Change-Id: I4862e5d80a7d95a1a119d06306e3f6927445d1d3
* JGit v5.13.1.202206130422-rv5.13.1.202206130422-rMatthias Sohn2022-06-132-2/+2
| | | | | Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Change-Id: Ife74d64e8171c68dbf08271492c0ac852a6dc51c
* Prepare 5.13.1-SNAPSHOT buildsMatthias Sohn2021-09-082-5/+5
| | | | Change-Id: Ib2f689d8d13eab022da5b5e83d6d6bebc1bb81d3
* JGit v5.13.0.202109080827-rv5.13.0.202109080827-rMatthias Sohn2021-09-082-2/+2
| | | | | Change-Id: If3b2d4256712cc7e577c23e75c0d4ad940870e72 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.13.0-SNAPSHOT buildsMatthias Sohn2021-09-012-2/+2
| | | | Change-Id: I2a1d7ab24d5ca718348f4ce3cda351553e48cd1f
* JGit v5.13.0.202109011149-rc1v5.13.0.202109011149-rc1Matthias Sohn2021-09-012-2/+2
| | | | | Change-Id: Id8d0970102f18e61a2fc7cf941267c9089d71c1a Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.13.0-SNAPSHOT buildsMatthias Sohn2021-08-252-2/+2
| | | | Change-Id: I6db044fdd57b60adbc2dd078c4af8cb54bb331c3
* JGit v5.13.0.202108250949-m3v5.13.0.202108250949-m3Matthias Sohn2021-08-252-2/+2
| | | | | Change-Id: Icc079b28327f5a02256f9a06837c2be6352ea6e3 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Relax version range for hamcrest and assertjMatthias Sohn2021-07-191-1/+1
| | | | | | | | | | | We currently cannot use hamcrest 2.2 and assertj 3.20.2 (which requires hamcrest 2.2) in egit tests since other Eclipse dependencies (e.g. swtbot) require hamcrest 1.1. Hence relax version range for these components in jgit so that jgit tests also work when using the egit target platform. Change-Id: I521e2ec4491bd8d790609b8a66a8f14511a865a1
* Update orbit to I20210713220109Matthias Sohn2021-07-161-0/+1
| | | | | | | | | | | | | | | | | | | | | update - org.apache.commons.compress to 1.20.0.v20210713-192 - org.bouncycastle.bcpg to 1.69.0.v20210713-1924 - org.bouncycastle.bcpkix to 1.69.0.v20210713-1924 - org.bouncycastle.bcprov to 1.69.0.v20210713-1924 - add org.bouncycastle.bcutil 1.69.0.v20210713-1924 In bazel build don't expose bouncycastle to org.eclipse.jgit since it's not used there anymore since code depending on bouncycastle was moved to org.eclipse.jgit.gpg.bc. CQ: 21771 CQ: 23471 CQ: 23472 CQ: 23473 CQ: 23474 Change-Id: Id3d94c00c39bbc57e3f49a61150841249dc3985c
* Update orbit to I20210711110031Matthias Sohn2021-07-161-2/+1
| | | | | | | | | | | | | | | and update - assertj to 3.20.2.v20210706-1104 - hamcrest to 2.2.0.v20210711-0821 - classes which were in org.hamcrest.core 1.3 and org.hamcrest.library 1.3 were all moved to org.hamcrest in 2.2 - the annotation org.hamcrest.Factory was removed and is no longer needed - junit 4.13 requires hamcrest-core and hamcrest-library 1.3 therefore keep them in the target platform CQ: 23501 Change-Id: Ife871c0343b611be9203aed7f86577e85bbf5c95
* Prepare 5.13.0-SNAPSHOT buildsMatthias Sohn2021-06-142-5/+5
| | | | Change-Id: Ie9cfc1eeb0eda7b2bbe744a22a7e4cfe6d59bc37
* Prepare 5.12.1-SNAPSHOT buildsMatthias Sohn2021-06-132-5/+5
| | | | Change-Id: Idf266c34aa9a04cf9c5e0e09bcb415c13d773d4c
* JGit v5.12.0.202106070339-rv5.12.0.202106070339-rMatthias Sohn2021-06-072-2/+2
| | | | | Change-Id: I0fbfea2c83f1ce83f75130cc97591547032f1104 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.12.0-SNAPSHOT buildsMatthias Sohn2021-06-032-2/+2
| | | | | Change-Id: Ifc72d3f3ac84b9c4055b95ec0093d877ffb09ab0 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* JGit v5.12.0.202106021050-rc1v5.12.0.202106021050-rc1Matthias Sohn2021-06-022-2/+2
| | | | | Change-Id: I622ee049f14f37504ff4a062f03d6fc25465d0ec Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.12.0-SNAPSHOT buildsMatthias Sohn2021-06-022-2/+2
| | | | Change-Id: I25e4efc9b40ae4e7168b37385445c73992c5beb0
* JGit v5.12.0.202106011439-rc1v5.12.0.202106011439-rc1Matthias Sohn2021-06-012-2/+2
| | | | | Change-Id: Ieac1d02879defe0f4791062448d4efc328a2f652 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.12.0-SNAPSHOT buildsMatthias Sohn2021-06-012-2/+2
| | | | | Change-Id: If563be77aab768ac1f31ae2211fb0892d0205a2a Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* JGit v5.12.0.202105261145-m3v5.12.0.202105261145-m3Matthias Sohn2021-05-262-2/+2
| | | | | Change-Id: I3b1af2032227900e6e0c6189f47bace1df67f0ab Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.12.0-SNAPSHOT buildsMatthias Sohn2021-05-062-2/+2
| | | | Change-Id: I2fc5305e7eaaa4593d418fc3b31d20e4b6e1e585
* JGit v5.12.0.202105051250-m2v5.12.0.202105051250-m2Matthias Sohn2021-05-052-2/+2
| | | | | Change-Id: Ic7d86c91ec0ff9aa0678dcb971c197e62a4ca2dc Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Bazel: Remove unused dependencies flagged by unused_depsDavid Ostrovsky2021-03-271-9/+3
| | | | | Change-Id: I7fcb494fdce4bb3de203236fa51b188b099d842f Signed-off-by: David Ostrovsky <david@ostrovsky.org>
* Bazel: Format build file with buildifierDavid Ostrovsky2021-03-271-1/+1
| | | | | Change-Id: I4c0c7ffb04d7bed517faf1a4932d8c76738bff11 Signed-off-by: David Ostrovsky <david@ostrovsky.org>
* Prepare 5.12.0-SNAPSHOT buildsMatthias Sohn2021-03-102-5/+5
| | | | | Change-Id: I736de7c3deb11da75777d459f47332df0b486443 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.11.1-SNAPSHOT buildsMatthias Sohn2021-03-092-5/+5
| | | | | Change-Id: I94628ccbb5099a65aa4345cfd28a141ff5555b68 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* JGit v5.11.0.202103091610-rv5.11.0.202103091610-rMatthias Sohn2021-03-092-2/+2
| | | | | Change-Id: I8e6855eaf7228459f492036feb4e34ca085698a7 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.11.0-SNAPSHOT buildsMatthias Sohn2021-03-042-2/+2
| | | | | Change-Id: I89ed49a6acc53dd75d16f40c99e1140e0c18f646 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* JGit v5.11.0.202103031150-rc1v5.11.0.202103031150-rc1Matthias Sohn2021-03-032-2/+2
| | | | | Change-Id: I0a86fa59645888f9f36ea6938c9121e095f02fc6 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.11.0-SNAPSHOT buildsMatthias Sohn2021-02-242-2/+2
| | | | | Change-Id: If3dbe084ee37ae4b993d3a10ec48b14e8709ff6d Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* JGit v5.11.0.202102240950-m3v5.11.0.202102240950-m3Matthias Sohn2021-02-242-2/+2
| | | | | Change-Id: Iea6b3515fa63db497989194b6bf50fe7324086d0 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* GPG: fix reading unprotected old-format secret keysThomas Wolf2021-02-223-9/+47
| | | | | | | | Fix code and add a test case. The old code passed on the original input stream, which has already been consumed. Bug: 570501 Change-Id: I81f60698ce42443df57e59b1d1ab155574136fa8 Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
* Add missing bazel dependency for o.e.j.gpg.bc.testMatthias Sohn2021-02-201-0/+1
| | | | | | This was missed in 64cbea8a9794047fe576d03ab8a46e4eaf7eabee. Change-Id: I0b2b234b9888a7dd8b7ace624233b141fb7c4394 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* GPG: handle extended private key formatThomas Wolf2021-02-199-1/+413
| | | | | | | | | | | | | | | | | | | | | | | | | Add detection for the key-value pair format that was available in gpg-agent for some time already and that has become the default since gpg-agent 2.2.20. If a secret key in the .gnupg/private-keys-v1.d directory is found to have this format, extract the human-readable key from it, convert it to the binary serialized form and hand that to BouncyCastle. Encrypted keys in the new format may use AES/OCB. OCB is a patent- encumbered algorithm; although there is a license for open-source software, that may not be good enough and OCB may not be available in Java. It is not available in the default security provider in Java, and it is also not available in the BouncyCastle version included in Eclipse. Implement AES/OCB decryption, throwing a PGPException with a nice message if the algorithm is not available. Include a copy of the normal s-expression parser of BouncyCastle and fix it to properly handle data from such keys: such keys do not contain an internal hash since the AES/OCB cipher includes and checks a MAC already. Bug: 570501 Change-Id: Ifa6391a809a84cfc6ae7c6610af6a79204b4143b Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
* GPG: compute the keygrip to find a secret keyThomas Wolf2021-02-1619-5/+468
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The gpg-agent stores secret keys in individual files in the secret key directory private-keys-v1.d. The files have the key's keygrip (in upper case) as name and extension ".key". A keygrip is a SHA1 hash over the parameters of the public key. By computing this keygrip, we can pre-compute the expected file name and then check only that one file instead of having to iterate over all keys stored in that directory. This file naming scheme is actually an implementation detail of gpg-agent. It is unlikely to change, though. The keygrip itself is computed via libgcrypt and will remain stable according to the GPG main author.[1] Add an implementation for calculating the keygrip and include tests. Do not iterate over files in BouncyCastleGpgKeyLocator but only check the single file identified by the keygrip. Ideally upstream BouncyCastle would provide such a getKeyGrip() method. But as it re-builds GPG and libgcrypt internals, it's doubtful it would be included there, and since BouncyCastle even lacks a number of curve OIDs for ed25519/curve25519 and uses the short-Weierstrass parameters instead of the more common Montgomery parameters, including it there might be quite a bit of work. [1] http://gnupg.10057.n7.nabble.com/GnuPG-2-1-x-and-2-2-x-keyring-formats-tp54146p54154.html Bug: 547536 Change-Id: I30022a0e7b33b1bf35aec1222f84591f0c30ddfd Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
* GPG user ID matching: use case-insensitive matchingThomas Wolf2020-12-291-5/+6
| | | | | | | | | | | | | Although not mentioned in the GPG documentation at [1], GPG uses case-insensitive matching also for the '<' (exact e-mail) and '@' (partial e-mail) operators. Matching for '=' (full exact match) is case-sensitive. Compare [2]. [1] https://www.gnupg.org/documentation/manuals/gnupg/Specify-a-User-ID.html [2] https://dev.gnupg.org/source/gnupg/browse/master/g10/keyring.c;22f7dddc34446a8c3e9eddf6cb281f16802351d7$890 Bug: 547789 Change-Id: I2f5ab65807d5dde3aa00ff032894701bbd8418c9 Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
* Prepare 5.11.0-SNAPSHOT buildsMatthias Sohn2020-12-022-3/+3
| | | | | Change-Id: I91e5532526775191fbd34f81e2ef777cba605e3b Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Ignore missing javadoc tags in test bundlesMatthias Sohn2020-11-291-2/+2
| | | | | | | | It seems Eclipse 4.18 reports them as error whereas earlier versions ignored this maybe since we don't require javadoc comments for all the test bundles. Change-Id: I3f4d42ce681ea5c2b4b302991d2641290ac8561d Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.10.0-SNAPSHOT buildsMatthias Sohn2020-08-272-3/+3
| | | | | Change-Id: I9a2b39e9e85f27179ceb3b1709d75c466089a3bc Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Prepare 5.9.0-SNAPSHOT buildsMatthias Sohn2020-06-092-3/+3
| | | | | Change-Id: Ia998e2772df1285a4c674b07201f15d53156eb78 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
* Decouple BouncyCastle from JGit CoreMatthias Sohn2020-06-0119-0/+1032
Motivation: BouncyCastle serves as 'default' implementation of the GPG Signer. If a client application does not use it there is no need to pull in this dependency, especially since BouncyCastle is a large library. Move the classes depending on BouncyCastle to an OSGi fragment extending the org.eclipse.jgit bundle. They are moved to a distinct internal package in order to avoid split packages. This doesn't break public API since these classes were already in an internal package before this change. Add a new feature org.eclipse.jgit.gpg.bc to enable installation. With that users can now decide if they want to install it. Attempts to sign a commit if org.eclipse.jgit.gpg.bc isn't available will result in ServiceUnavailableException being thrown. Bug: 559106 Change-Id: I42fd6c00002e17aa9a7be96ae434b538ea86ccf8 Also-by: Michael Dardis <git@md-5.net> Signed-off-by: Michael Dardis <git@md-5.net> Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> Signed-off-by: David Ostrovsky <david@ostrovsky.org>