phax / phase4

phase4 - AS4 client and server for integration into existing systems. Specific support for Peppol and CEF eDelivery built-in.
Apache License 2.0
154 stars 47 forks source link

SOAPHeaderElementProcessorWSS4J: Ability to add custom WSSConfig processors #150

Closed phax closed 1 year ago

phax commented 1 year ago

Discussed in https://github.com/phax/phase4/discussions/146

Originally posted by **sopgreg** July 21, 2023 Is there currently a way to add a custom processor to the `WSSConfig` in `SOAPHeaderElementProcessorWSS4J#_verifyAndDecrypt`? This is necessary to add a custom processor for the `EncryptedKey` part, since WSS4J does not support parts for EC, like so: `aWSSConfig.setProcessor(new QName("http://www.w3.org/2001/04/xmlenc#", "EncryptedKey"), customProcessor);`
phax commented 1 year ago

@sopgreg This was implemented in https://github.com/phax/phase4/commit/7a0e6bae49772eaaefe8b629649ae4594d903e27 Basically I renamed the new interface IAS4DecryptRequestDataModifier to IAS4DecryptParameterModifier and gave it a method to customize the WSSConfig object. You can set this modifier for senders and receivers.

phax commented 1 year ago

Part of the 2.2.0 release