Commit Graph

10442 Commits

Author SHA1 Message Date
Adel El-Beik
b114b39ca6
Merge pull request #7694 from corda/shams-bc-eddsa
ENT-11661: Replaced SunEC Ed25519 implementation with Bouncy Castle
2024-03-19 11:25:26 +00:00
Shams Asari
9d57caebed ENT-11661: Replaced SunEC Ed25519 implementation with Bouncy Castle
It turns out the JDK implementation (`SunEC` provider) of Ed25519 signature verification is quite slow, slower than the abandoned library (i2p) it replaced. This has been replaced by Bouncy Castle, whereby the `EDDSA_ED25519_SHA512` signature scheme uses it. `SunEC` still remains the default implementation. `Crypto.toSupportedPublicKey` (and `toSupportedPrivateKey`) were tweaked to make sure any `SunEC` keys are converted to Bouncy Castle. The presence of two different `EdECPublicKey` implementations for the same key causes cache misses in `BasicHSMKeyManagementService`, resulting in another performance degradation.
2024-03-19 07:48:22 +00:00
Adel El-Beik
d478decc6f
Merge pull request #7692 from corda/adel/ENT-11523
ENT-11523: Dont instrument due to the synchronization. Quasar was thr…
2024-03-15 13:43:43 +00:00
Adel El-Beik
d4829df687 ENT-11523: Dont instrument due to the synchronization. Quasar was throwing unable to instrument exception. 2024-03-14 13:55:28 +00:00
Adel El-Beik
7946958804
Merge pull request #7687 from corda/cc/dev/os/4.12/ent-11514/add_opens
ENT-11514 - More --add-opens JVM args
2024-03-13 11:06:51 +00:00
Adel El-Beik
769aac11f2
Merge pull request #7683 from racerole/release/os/4.12
ENT-11581: fix some typos
2024-03-13 11:05:41 +00:00
Chris Cochrane
ea93a5f560
Extra add-opens to support corda-shell 2024-03-12 15:45:19 +00:00
Adel El-Beik
5b8fc6f503
Merge pull request #7685 from corda/shams-signers-component-group
ENT-9659: Using signers component group for `WireTransaction.requiredSigningKeys`
2024-03-07 20:03:47 +00:00
Adel El-Beik
54135a26c9
Merge pull request #7680 from corda/shams-cleanup-jdk-8-11
ENT-11090: Removed all JDK 8/11 conditional code
2024-03-07 20:03:20 +00:00
Adel El-Beik
89a998892d
Merge pull request #7684 from corda/paulmoloneyr3/DOC-6379/broken-links
DOC-6379 - fixed broken links on github
2024-03-07 13:53:31 +00:00
Shams Asari
47a57285fb ENT-9659: Using signers component group for WireTransaction.requiredSigningKeys
The previous solution of using `Command.signers` has the risk of not being deserialisable if the correct CorDapp is not installed on the node.
2024-03-07 10:24:38 +00:00
Adel El-Beik
7019ea8e47
Merge pull request #7682 from corda/adel/ENT-11501
ENT-11501: Re initialise the logging, after system property set.
2024-03-06 17:39:46 +00:00
Paul Moloney
73c98e6c2c DOC-6379 - fixed broken links on github 2024-03-06 10:56:24 +00:00
racerole
4d1d1b0c9c fix some typos
Signed-off-by: racerole <jiangyifeng@outlook.com>
2024-03-06 11:06:13 +08:00
Adel El-Beik
5c9164c94a ENT-11501: Re initialise the logging, after system property set. 2024-03-05 19:40:14 +00:00
Shams Asari
900809b3d7 ENT-11090: Removed all JDK 8/11 conditional code 2024-03-05 17:10:26 +00:00
Adel El-Beik
6bdad94236
Merge pull request #7675 from corda/shams-remove-i2p
ENT-11101: Fix all crypto issues introduced by Java 17 upgrade
2024-03-05 14:32:34 +00:00
Shams Asari
0091807c2f ENT-11101: Fix all crypto issues introduced by Java 17 upgrade
The various crypto tests that were previously ignored have been re-enabled.

The abandoned i2p EdDSA library has been replaced with native support that was added in Java 15.

Java 17 (via the `SunEC` provider) does not support the secp256k1 curve (one of the two ECDSA curves supported in Corda). This would not normally have been an issue as secp256k1 is already taken care of by Bouncy Castle. However, this only works if the `Crypto` API is used or if `”BC”` is explicitly specified as the provider (e.g. `Signature.getInstance(“SHA256withECDSA”, “BC”)`). If no provider is specified, which is what is more common, and actually what the Java docs recommend, then this doesn’t work as the `SunEC` provider is selected. To resolve this, a custom provider was created, installed just in front of `SunEC`, which “augments” `SunEC` by delegating to Bouncy Castle if keys or parameters for secp256k1 are encountered.

`X509Utilities.createCertificate` now calls `X509Certificate.verify()` to verify the created certificate, rather than using the Bouncy Castle API. This is more representative of how certificates will be verified (e.g. during SSL handshake) and weeds out other issues (such as unsupported curve error for secp256k1).

`BCCryptoService` has been renamed to `DefaultCryptoService` as it no longer explicitly uses Bouncy Castle but rather uses the installed security providers. This was done to fix a failing test. Further, `BCCryptoService` was already relying on the installed providers in some places.

The hack to get Corda `SecureRandom` working was also resolved. Also, as an added bonus, tests which ignored `SPHINCS256_SHA256` have been reinstated.

Note, there is a slightly inconsistency between how EdDSA and ECDSA keys are handled (and also RSA). For the later, Bouncy Castle is preferred, and methods such as `toSupportedKey*` will convert any JDK class to Bouncy Castle. For EdDSA the preference is the JDK (`SunEC`). However, this is simply a continuation of the previous preference of the i2p library over Bouncy Castle.
2024-03-04 13:29:49 +00:00
Adel El-Beik
6dfbed572e
ENT-11522: Unignored flow tests and updated artemis mq filter to check for null property. (#7679) 2024-03-04 12:25:37 +00:00
Adel El-Beik
4031c28947
ENT-11502: Upgrade platform version to 140. (#7674) 2024-03-04 12:24:15 +00:00
Adel El-Beik
dea3e0a574
Merge pull request #7678 from corda/shams-getcallerclass-warning
ENT-11521: Upgraded to latest log4j to resolve getCallerClass warning
2024-03-04 09:41:24 +00:00
Shams Asari
8840710fab ENT-11521: Upgraded to latest log4j to resolve getCallerClass warning
"WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance." warning was being caused by log4j. Latest version fixes this issue.
2024-03-01 13:53:32 +00:00
Adel El-Beik
f3c45e9d1b
Merge pull request #7677 from corda/adel/ENT-11504
ENT-11504: Bind to the same address that the server socket created.
2024-02-28 13:01:37 +00:00
Paul Moloney
db9017f4ed
DOC-6353 - updated readme, fixed links and removed out of date info (#7676)
* DOC-6353 - updated readme, fixed links and removed out of date info


---------

Co-authored-by: Ronan Browne <ronan.browne@R3.com>
2024-02-22 15:45:36 +00:00
Adel El-Beik
0000c75391 ENT-11504: Bind to the same address that the server socket created. 2024-02-22 12:52:11 +00:00
Adel El-Beik
9babf8d801
Merge pull request #7673 from corda/shams-contracts-component-group
ENT-11355: Backwards compatibility with older nodes via new attachments component group
2024-02-21 15:11:20 +00:00
Shams Asari
200333b198 ENT-11355: Backwards compatibility with older nodes via new attachments component group 2024-02-19 17:19:49 +00:00
Adel El-Beik
c2742ba6a5
Merge pull request #7672 from corda/shams-tx-builder-cleanup
ENT-11355: Cleanup of TransactionBuilder and CorDapp loading
2024-02-15 17:57:48 +00:00
Shams Asari
8fd3139df1 ENT-11355: Cleanup of TransactionBuilder and CorDapp loading
This is code refactoring and cleanup that is required to add a new WireTransaction component group for 4.12+ attachments, and for supporting legacy (4.11 or older) contract CorDapps in the node.
2024-02-12 14:27:07 +00:00
Chris Cochrane
c7514e1c60
ENT-11443 Function sig changes to support removing enterprise compiler warnings (#7671) 2024-02-07 14:46:18 +00:00
Suhas Krishna Srivastava
a95b854b1e
ENT-11386: Using NodeAttachmentService instead of fat interface ServiceHub. (#7670) 2024-02-01 11:49:52 +00:00
Adel El-Beik
50a6f2f495
Merge pull request #7669 from corda/merge-release/os/4.11-release/os/4.12-2024-01-30-129
ENT-11387: Merging forward updates from release/os/4.11 to release/os/4.12 - 2024-01-30
2024-01-31 09:39:37 +00:00
Chris Cochrane
ee71bf5a78
ENT-11351 - Compiler warnings pass 5 (#7666)
* Reduce compiler warnings

* Address PR review comments

* Acually make use of capitalize(),decapitalize()
2024-01-30 18:09:55 +00:00
r3-build
5bfc39c364 Merging forward updates from release/os/4.11 to release/os/4.12 - 2024-01-30 2024-01-30 15:44:32 +00:00
Adel El-Beik
df07b7b8da
Merge pull request #7668 from corda/merge-release/os/4.10-release/os/4.11-2024-01-30-87
ENT-11387: Merging forward updates from release/os/4.10 to release/os/4.11 - 2024-01-30
2024-01-30 15:43:36 +00:00
r3-build
b6c2d17dae Merging forward updates from release/os/4.10 to release/os/4.11 - 2024-01-30 2024-01-30 11:51:24 +00:00
Rick Parker
4faa0caeb3
Merge pull request #7667 from corda/merge-release/os/4.9-release/os/4.10-2024-01-30-95
ENT-11387: Merging forward updates from release/os/4.9 to release/os/4.10 - 2024-01-30
2024-01-30 11:49:45 +00:00
r3-build
f2522943f2 Merging forward updates from release/os/4.9 to release/os/4.10 - 2024-01-30 2024-01-30 09:08:36 +00:00
Adel El-Beik
fa173baaee
ENT-11387: Fix to prevent interleaved stop/start causing bridge to be started with null session. (#7665)
* ENT-11387: Fix to prevent interleaved stop/start causing bridge to be started with null session.

* ENT-11387: Fixed bug in assigning null to session.
2024-01-30 09:07:18 +00:00
Chris Cochrane
9b794795a0
ENT-11351 - Compiler warnings pass 4 (#7663)
* Compiler warnings

* Resolve detekt errors

* Reverted code change; added warning suppression

* Address PR review comments
2024-01-29 13:49:00 +00:00
Shams Asari
a7d0684fe7
ENT-11384: Cleanup JarScanningCordappLoader (#7664)
* It uses URLs when in fact CorDapps are jar files, and so should being Path. It also does URL equality, which is not recommended
* Address (very old) TODO of removing RestrictedURL, which is not needed

Also, back-ported some minor changes from https://github.com/corda/enterprise/pull/5057.
2024-01-29 13:44:14 +00:00
Adel El-Beik
d642ebfbd7
Merge pull request #7662 from corda/arshadm/ent-6914-disable-node-metadata
ENT-6914 Disabled module metadata generation for the node capsule
2024-01-25 14:10:38 +00:00
Shams Asari
63f8e220c8
ENT-11251: Upgrade to Kotlin language version 1.9 (#7660) 2024-01-25 13:51:19 +00:00
Arshad Mahmood
4ea42c4d75 ENT-6914 Disabled module metadata generation for the node capsule as it was generating invalid json 2024-01-25 12:11:47 +00:00
Adel El-Beik
3d90c1d850
Merge pull request #7658 from corda/merge-release/os/4.11-release/os/4.12-2024-01-22-120
ENT-10900: Merging forward updates from release/os/4.11 to release/os/4.12 - 2024-01-22
2024-01-25 10:39:51 +00:00
Chris Cochrane
975500d878
ENT-11351 - Compiler warnings pass 3 (#7659)
* More compiler warnings fixed

* Amended deprecation suppression annotations, as per review comments
2024-01-25 10:18:58 +00:00
Adel El-Beik
3abb218bca
Merge pull request #7654 from corda/shams-external-verifier-analyse-txs
ENT-11255: Scan attachments to determine if they are Kotlin 1.2 or later
2024-01-23 16:56:47 +00:00
Balwant Kothari
5c193ce47f
ENT-11113 Uncommented ignored test cases (#7648)
ENT-11113 Uncommented ignored test cases
ENT-11113 Updated time for Flow Speed Test
2024-01-23 15:11:50 +00:00
Chris Cochrane
f15e6ec56a
ENT-11351 - Compiler warnings pass 2 (#7655)
* Addressed compiler warnings

* Removed unchecked cast fixes - not for this PR

* Sorted out detekt issues
2024-01-23 10:19:03 +00:00
r3-build
fd66ff81d0 Merging forward updates from release/os/4.11 to release/os/4.12 - 2024-01-22 2024-01-22 14:09:52 +00:00