Remove ph-security runtime dependency on ph-bc - #57
Merged
phax merged 1 commit intoAug 25, 2026
Conversation
This was referenced Aug 25, 2026
Contributor
Author
|
Additional downstream verification is complete against the local snapshot chain from this PR, phax/peppol-commons#81, and phax/phase4#395:
So the proposed sequence has now been exercised through a real downstream application, not only the individual Maven modules. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this changes
CRLHelperwith a small, strict DER parser for the exact X.509 extension subset used there.ph-bcto test scope inph-security; existing certificate-generation tests can keep using it.Why
Downstream Peppol/phase4 applications otherwise receive the complete Bouncy Castle stack solely because
ph-securityhas two small ASN.1/constant linkages. Modern JDK APIs cover the certificate, trust, and revocation operations, but do not expose a supported public CRL Distribution Points decoder. The included parser is deliberately limited to the relevant DER structure rather than introducing another general ASN.1 dependency or using internal JDK classes.This does not remove the
ph-bcmodule or prevent applications from choosing the BC provider. It only makes standardph-securityX.509 use provider-neutral.Verification
mvn -pl ph-security -am verify— all 15 reactor modules passed.ph-securitysuite — 80 tests, 0 failures/errors (2 existing skips).org.bouncycastle.*andcom.helger.bc.*.ph-securityproduction classes contain noorg/bouncycastleorcom/helger/bcreferences.A small follow-up in peppol-commons can remove its direct
ph-bcdependency once this is available in a ph-commons release.