use of org.apache.wss4j.policy.stax.enforcer.PolicyInputProcessor in project cxf by apache.
the class PolicyBasedWSS4JStaxInInterceptor method configureSecurityEventListeners.
@Override
protected List<SecurityEventListener> configureSecurityEventListeners(SoapMessage msg, WSSSecurityProperties securityProperties) throws WSSPolicyException {
final List<SecurityEventListener> securityEventListeners = new ArrayList<>(2);
securityEventListeners.addAll(super.configureSecurityEventListeners(msg, securityProperties));
Endpoint endoint = msg.getExchange().getEndpoint();
PolicyEnforcer policyEnforcer = createPolicyEnforcer(endoint.getEndpointInfo(), msg);
securityProperties.addInputProcessor(new PolicyInputProcessor(policyEnforcer, securityProperties));
securityEventListeners.add(policyEnforcer);
return securityEventListeners;
}
Aggregations