You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ws.apache.org by "Colm O hEigeartaigh (Closed) (JIRA)" <ji...@apache.org> on 2011/10/03 11:04:35 UTC
[jira] [Closed] (WSS-112) DerivedKeyProcessor is overwritten if
more derivedkeys are present in a Soap Message.
[ https://issues.apache.org/jira/browse/WSS-112?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Colm O hEigeartaigh closed WSS-112.
-----------------------------------
> DerivedKeyProcessor is overwritten if more derivedkeys are present in a Soap Message.
> -------------------------------------------------------------------------------------
>
> Key: WSS-112
> URL: https://issues.apache.org/jira/browse/WSS-112
> Project: WSS4J
> Issue Type: Bug
> Environment: Rampart latest, Wss4J latest
> Reporter: Rasmus Rhein Helwigh
> Assignee: Fred Dushin
> Fix For: 1.5.4
>
>
> org.apache.ws.security.WSSConfig.getProcessor returns a cached Processor
> public Processor getProcessor(QName el) throws WSSecurityException {
> Processor p = (Processor) processorMap.get(el);
> return p;
> }
> This causes problem if two DerivedKeyProcessors are needed for the same message, as the second processor will overwrite the first.
> A fix could be to Create a new instance each time.
> Check out this hack:
> public Processor getProcessor(QName el) throws WSSecurityException {
> Processor p = (Processor) processorMap.get(el);
> try {
> return (Processor) Loader.loadClass(p.getClass().getName()).newInstance();
> } catch (InstantiationException e) {
> throw new WSSecurityException("Unable to get processor",e);
> } catch (IllegalAccessException e) {
> throw new WSSecurityException("Unable to get processor",e);
> } catch (ClassNotFoundException e) {
> throw new WSSecurityException("Unable to get processor",e);
> }
> }
> I can try and make a better fix if requested. WCF <-> Wss4j interop will work a lot better with this fix..
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ws.apache.org
For additional commands, e-mail: dev-help@ws.apache.org