[
https://issues.apache.org/jira/browse/WSS-154?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12658332#action_12658332
]
Guillaume Sauthier commented on WSS-154:
----------------------------------------
Hi Colm
Thanks for the review ...
Sorry for the testcase, but I will not have the time to do it before january,
but I will provide one ...
For the cast, you can cast null to any type without expecting NPE, so casting
the Map return should be harmless.
Concerning the WSSConfig injection, I'm not sure of the RequestData solution.
This is just a move of the injection. Instead of WSHandler being injected, this
will be one of the CXF WSS4J Interceptors. Currently, the CXF out interceptor
do not call RequestData.setWssConfig, so it was easier to just provide the
injection in WSHandler.
But this is probably a feature that the CXF guys can take advantage of ...
> 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
> Affects Versions: 1.5.4
> Environment: Apache CXF 2.1.3, with Spring based configuration
> Reporter: Guillaume Sauthier
> Assignee: Ruchith Udayanga Fernando
> Fix For: 1.5.5
>
> Attachments: wss4j.patch
>
>
> 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]