Allow WSSConfig injection in WSHandler and improve WSSConfig for injection of
Processors instances
--------------------------------------------------------------------------------------------------
Key: WSS-154
URL: https://issues.apache.org/jira/browse/WSS-154
Project: WSS4J
Issue Type: Improvement
Components: WSS4J Core
Environment: Apache CXF 2.1.3, with Spring based configuration
Reporter: Guillaume Sauthier
Assignee: Ruchith Udayanga Fernando
Hi
I've worked on WSS4J to allow Processor configuration.
In CXF, security interceptor (based on WSS4J) are configured using a Spring
configuration file.
In my case, I wanted to add a Processor to handle my specific security token.
In the current WSS4J, there is an extension mechanism
(WSSConfig.setProcessor(QName, String)), but it doesn't accept a Processor
instance, instead it nderstand a Processor classname tht will be instanciated.
I need to have a Processor instance instead because my Processor is itself
configured with Spring.
So I propose a patch that change WSSConfig with a new method
setProcessorInstances(Map<QName, Processor>).
I've also changed the WSHandler.doReceiveAction method because it was creating
a new WSSConfig instance each time it's invoked.
So in my change, a WSSConfig instance (configured with my map of Processors
instances) can be injected (WSHandler.setWssConfig) in WSHandler.
So, in doReceiveAction, it will use that WSSConfig instead of creating a new
one each time. If the wssConfig has not been injected, it recreates a new one,
like the old behavior.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]