Skip to content

chore: Adapt camel-pqc to Bouncy Castle 1.85 algorithm renames#24653

Merged
davsclaus merged 2 commits into
mainfrom
fix/bc-1.85-algorithm-renames
Jul 13, 2026
Merged

chore: Adapt camel-pqc to Bouncy Castle 1.85 algorithm renames#24653
davsclaus merged 2 commits into
mainfrom
fix/bc-1.85-algorithm-renames

Conversation

@davsclaus

Copy link
Copy Markdown
Contributor

Summary

Claude Code on behalf of davsclaus

Bouncy Castle 1.85 removed the pre-standardization PQC algorithm names (DILITHIUM, KYBER, SPHINCSPLUS) from the BCPQC provider. This PR adapts camel-pqc to use the NIST standardized names:

  • DILITHIUMML-DSA (BC provider) — FIPS 204
  • KYBERML-KEM (BC provider) — FIPS 203
  • SPHINCSPLUSSLH-DSA (BC provider) — FIPS 205

The Camel enum constants (signatureAlgorithm=DILITHIUM, keyEncapsulationAlgorithm=KYBER, etc.) are preserved unchanged for backward compatibility — existing routes continue to work transparently.

Changes:

  • Updated PQCSignatureAlgorithms.DILITHIUM and .SPHINCSPLUS to use new JCA names and BC provider
  • Updated PQCKeyEncapsulationAlgorithms.KYBER to use new JCA name and BC provider
  • Updated default parameter specs from old BC classes (DilithiumParameterSpec, KyberParameterSpec, SPHINCSPlusParameterSpec) to standardized ones (MLDSAParameterSpec, MLKEMParameterSpec, SLHDSAParameterSpec)
  • Updated all lifecycle managers (File, AWS, Hashicorp) and crypto material classes
  • Updated all tests

This is a companion to PR #24648 (Bouncy Castle 1.84 → 1.85 version bump).

Test plan

  • All 168 camel-pqc tests pass (including PQCEndToEndIntegrationTest which was failing)
  • Code compiles and formats correctly

🤖 Generated with Claude Code

dependabot Bot and others added 2 commits July 13, 2026 07:47
Bumps `bouncycastle-version` from 1.84 to 1.85.

Updates `org.bouncycastle:bcpkix-jdk18on` from 1.84 to 1.85
- [Changelog](https://github.com/bcgit/bc-java/blob/main/docs/releasenotes.html)
- [Commits](https://github.com/bcgit/bc-java/commits)

Updates `org.bouncycastle:bcprov-jdk18on` from 1.84 to 1.85
- [Changelog](https://github.com/bcgit/bc-java/blob/main/docs/releasenotes.html)
- [Commits](https://github.com/bcgit/bc-java/commits)

Updates `org.bouncycastle:bcutil-jdk18on` from 1.84 to 1.85
- [Changelog](https://github.com/bcgit/bc-java/blob/main/docs/releasenotes.html)
- [Commits](https://github.com/bcgit/bc-java/commits)

Updates `org.bouncycastle:bcjmail-jdk18on` from 1.84 to 1.85
- [Changelog](https://github.com/bcgit/bc-java/blob/main/docs/releasenotes.html)
- [Commits](https://github.com/bcgit/bc-java/commits)

Updates `org.bouncycastle:bcpg-jdk18on` from 1.84 to 1.85
- [Changelog](https://github.com/bcgit/bc-java/blob/main/docs/releasenotes.html)
- [Commits](https://github.com/bcgit/bc-java/commits)

Updates `org.bouncycastle:bcmail-jdk18on` from 1.84 to 1.85
- [Changelog](https://github.com/bcgit/bc-java/blob/main/docs/releasenotes.html)
- [Commits](https://github.com/bcgit/bc-java/commits)

---
updated-dependencies:
- dependency-name: org.bouncycastle:bcpkix-jdk18on
  dependency-version: '1.85'
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: org.bouncycastle:bcprov-jdk18on
  dependency-version: '1.85'
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: org.bouncycastle:bcutil-jdk18on
  dependency-version: '1.85'
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: org.bouncycastle:bcjmail-jdk18on
  dependency-version: '1.85'
  dependency-type: direct:development
  update-type: version-update:semver-minor
- dependency-name: org.bouncycastle:bcpg-jdk18on
  dependency-version: '1.85'
  dependency-type: direct:production
  update-type: version-update:semver-minor
- dependency-name: org.bouncycastle:bcmail-jdk18on
  dependency-version: '1.85'
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Bouncy Castle 1.85 removed the pre-standardization PQC algorithm names
(DILITHIUM, KYBER, SPHINCSPLUS) from the BCPQC provider, replacing them
with the NIST standardized names (ML-DSA, ML-KEM, SLH-DSA) in the main
BC provider.

Update the PQC enum values and default parameter specs to use the new
names while keeping the Camel enum constants unchanged for backward
compatibility. Users with signatureAlgorithm=DILITHIUM in their routes
will continue to work transparently.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Claus Ibsen <claus.ibsen@gmail.com>
@github-actions

Copy link
Copy Markdown
Contributor

🌟 Thank you for your contribution to the Apache Camel project! 🌟
🤖 CI automation will test this PR automatically.

🐫 Apache Camel Committers, please review the following items:

  • First-time contributors require MANUAL approval for the GitHub Actions to run
  • You can use the command /component-test (camel-)component-name1 (camel-)component-name2.. to request a test from the test bot although they are normally detected and executed by CI.
  • You can label PRs using skip-tests and test-dependents to fine-tune the checks executed by this PR.
  • Build and test logs are available in the summary page. Only Apache Camel committers have access to the summary.

⚠️ Be careful when sharing logs. Review their contents before sharing them publicly.

@gnodet gnodet left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clean, comprehensive adaptation of camel-pqc to Bouncy Castle 1.85's NIST-standardized PQC algorithm names. All renamed algorithms (DILITHIUM→ML-DSA, KYBER→ML-KEM, SPHINCSPLUS→SLH-DSA) are correctly mapped across 20 files with proper parameter spec equivalences, provider migration from BCPQC to BC, and backward-compatible enum constant preservation.

Minor notes:

  • The BC version bump from 1.84 to 1.85 overlaps with companion PR #24648. One will need a trivial rebase after the other merges.
  • The SPHINCS+ default parameter spec change from Haraka-based (haraka_256s) to SHA2-based (slh_dsa_sha2_128s) is correct since NIST FIPS 205 only standardized SHA2 and SHAKE instantiations.
  • The explicit parameter spec returns in lifecycle managers (replacing null/key-size fallbacks) is an improvement.

This review was generated by an AI agent and may contain inaccuracies. Please verify all suggestions before applying.

Claude Code review on behalf of @gnodet

@github-actions

Copy link
Copy Markdown
Contributor

🧪 CI tested the following changed modules:

  • components/camel-pqc
  • parent

POM dependency changes: targeted tests included

Changed properties: bouncycastle-version

Modules affected by dependency changes (11)
  • :camel-asn1
  • :camel-xmlsecurity
  • :camel-jsch
  • :camel-fop
  • :camel-as2-api
  • :camel-crypto-pgp
  • :camel-pqc
  • :camel-pdf
  • :camel-ftp
  • :camel-ssh
  • :camel-mina-sftp

🔬 Scalpel shadow comparison — Scalpel: 22 tested, 29 compile-only — current: 9 all tested

Maveniverse Scalpel detected 51 affected modules (current approach: 9).

⚠️ Modules only in Scalpel (42)
  • apache-camel
  • camel-allcomponents
  • camel-as2
  • camel-as2-api
  • camel-asn1
  • camel-azure-files
  • camel-catalog
  • camel-catalog-console
  • camel-catalog-lucene
  • camel-catalog-maven
  • camel-catalog-suggest
  • camel-componentdsl
  • camel-crypto-pgp
  • camel-csimple-maven-plugin
  • camel-endpointdsl
  • camel-endpointdsl-support
  • camel-fop
  • camel-ftp
  • camel-itest
  • camel-jbang-core
  • camel-jbang-it
  • camel-jbang-main
  • camel-jbang-plugin-edit
  • camel-jbang-plugin-generate
  • camel-jbang-plugin-kubernetes
  • camel-jbang-plugin-test
  • camel-jsch
  • camel-kamelet-main
  • camel-launcher
  • camel-mina-sftp
  • camel-pdf
  • camel-report-maven-plugin
  • camel-route-parser
  • camel-ssh
  • camel-xmlsecurity
  • camel-yaml-dsl
  • camel-yaml-dsl-deserializers
  • camel-yaml-dsl-maven-plugin
  • camel-zookeeper-master
  • coverage
  • docs
  • dummy-component

Changed properties: bouncycastle-version

Skip-tests mode would test 22 modules (11 direct + 11 downstream), skip tests for 29 (generated code, meta-modules)

Modules Scalpel would test (22)
  • camel-as2
  • camel-as2-api
  • camel-asn1
  • camel-azure-files
  • camel-crypto-pgp
  • camel-fop
  • camel-ftp
  • camel-jbang-mcp
  • camel-jbang-plugin-mcp
  • camel-jbang-plugin-route-parser
  • camel-jbang-plugin-tui
  • camel-jbang-plugin-validate
  • camel-jsch
  • camel-launcher-container
  • camel-mina-sftp
  • camel-pdf
  • camel-pqc
  • camel-ssh
  • camel-xmlsecurity
  • camel-yaml-dsl-validator
  • camel-yaml-dsl-validator-maven-plugin
  • camel-zookeeper-master
Modules with tests skipped (29)
  • apache-camel
  • camel-allcomponents
  • camel-catalog
  • camel-catalog-console
  • camel-catalog-lucene
  • camel-catalog-maven
  • camel-catalog-suggest
  • camel-componentdsl
  • camel-csimple-maven-plugin
  • camel-endpointdsl
  • camel-endpointdsl-support
  • camel-itest
  • camel-jbang-core
  • camel-jbang-it
  • camel-jbang-main
  • camel-jbang-plugin-edit
  • camel-jbang-plugin-generate
  • camel-jbang-plugin-kubernetes
  • camel-jbang-plugin-test
  • camel-kamelet-main
  • camel-launcher
  • camel-report-maven-plugin
  • camel-route-parser
  • camel-yaml-dsl
  • camel-yaml-dsl-deserializers
  • camel-yaml-dsl-maven-plugin
  • coverage
  • docs
  • dummy-component

ℹ️ Shadow mode — Scalpel observes but does not affect test execution. Learn more

All tested modules (51 modules)
  • Camel :: AS2 :: API
  • Camel :: AS2 :: Component
  • Camel :: ASN.1
  • Camel :: All Components Sync point
  • Camel :: Assembly
  • Camel :: Azure :: Files
  • Camel :: Catalog :: CSimple Maven Plugin (deprecated)
  • Camel :: Catalog :: Camel Catalog
  • Camel :: Catalog :: Camel Report Maven Plugin
  • Camel :: Catalog :: Camel Route Parser
  • Camel :: Catalog :: Console
  • Camel :: Catalog :: Dummy Component
  • Camel :: Catalog :: Lucene (deprecated)
  • Camel :: Catalog :: Maven
  • Camel :: Catalog :: Suggest
  • Camel :: Component DSL
  • Camel :: Coverage
  • Camel :: Crypto PGP
  • Camel :: Docs
  • Camel :: Endpoint DSL
  • Camel :: Endpoint DSL :: Support
  • Camel :: FOP
  • Camel :: FTP
  • Camel :: Integration Tests
  • Camel :: JBang :: Core
  • Camel :: JBang :: Integration tests
  • Camel :: JBang :: MCP
  • Camel :: JBang :: Main
  • Camel :: JBang :: Plugin :: Edit
  • Camel :: JBang :: Plugin :: Generate
  • Camel :: JBang :: Plugin :: Kubernetes
  • Camel :: JBang :: Plugin :: MCP
  • Camel :: JBang :: Plugin :: Route Parser
  • Camel :: JBang :: Plugin :: TUI
  • Camel :: JBang :: Plugin :: Testing
  • Camel :: JBang :: Plugin :: Validate
  • Camel :: Jsch
  • Camel :: Kamelet Main
  • Camel :: Launcher
  • Camel :: Launcher :: Container
  • Camel :: MINA SFTP
  • Camel :: PDF
  • Camel :: PQC
  • Camel :: SSH
  • Camel :: XML Security
  • Camel :: YAML DSL
  • Camel :: YAML DSL :: Deserializers
  • Camel :: YAML DSL :: Maven Plugins
  • Camel :: YAML DSL :: Validator
  • Camel :: YAML DSL :: Validator Maven Plugin
  • Camel :: Zookeeper Master

⚙️ View full build and test results

@davsclaus davsclaus added this to the 4.22.0 milestone Jul 13, 2026
@davsclaus davsclaus self-assigned this Jul 13, 2026
@davsclaus davsclaus merged commit 0c55504 into main Jul 13, 2026
5 checks passed
@davsclaus davsclaus deleted the fix/bc-1.85-algorithm-renames branch July 13, 2026 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants