Package org.apache.cxf.rs.security.xml
Class XmlSecInInterceptor
java.lang.Object
org.apache.cxf.phase.AbstractPhaseInterceptor<Message>
org.apache.cxf.rs.security.xml.XmlSecInInterceptor
- All Implemented Interfaces:
jakarta.ws.rs.ext.ReaderInterceptor,Interceptor<Message>,PhaseInterceptor<Message>
public class XmlSecInInterceptor
extends AbstractPhaseInterceptor<Message>
implements jakarta.ws.rs.ext.ReaderInterceptor
A new StAX-based interceptor for processing messages with XML Signature + Encryption content.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaroundReadFrom(jakarta.ws.rs.ext.ReaderInterceptorContext ctx) protected org.apache.xml.security.stax.securityEvent.SecurityEventListenerconfigureSecurityEventListener(org.apache.wss4j.common.crypto.Crypto sigCrypto, Message msg, org.apache.xml.security.stax.ext.XMLSecurityProperties securityProperties) voidhandleMessage(Message message) Intercepts a message.booleanbooleanvoidsetDecryptionAlias(String decryptionAlias) voidsetEncryptionProperties(EncryptionProperties properties) voidsetPersistSignature(boolean persist) voidsetRequireEncryption(boolean requireEncryption) voidsetRequireSignature(boolean requireSignature) voidsetSignatureProperties(SignatureProperties properties) voidsetSignatureVerificationAlias(String signatureVerificationAlias) voidsetSubjectConstraints(List<String> constraints) Set a list of Strings corresponding to regular expression constraints on the subject DN of a certificateprotected voidthrowFault(String error, Exception ex) Methods inherited from class org.apache.cxf.phase.AbstractPhaseInterceptor
addAfter, addAfter, addBefore, addBefore, getAdditionalInterceptors, getAfter, getBefore, getId, getPhase, handleFault, isGET, isRequestor, setAfter, setBefore
-
Constructor Details
-
XmlSecInInterceptor
public XmlSecInInterceptor()
-
-
Method Details
-
handleMessage
Description copied from interface:InterceptorIntercepts a message. Interceptors should NOT invoke handleMessage or handleFault on the next interceptor - the interceptor chain will take care of this.- Specified by:
handleMessagein interfaceInterceptor<Message>- Throws:
Fault
-
configureSecurityEventListener
protected org.apache.xml.security.stax.securityEvent.SecurityEventListener configureSecurityEventListener(org.apache.wss4j.common.crypto.Crypto sigCrypto, Message msg, org.apache.xml.security.stax.ext.XMLSecurityProperties securityProperties) -
throwFault
-
setEncryptionProperties
-
setSignatureProperties
-
getDecryptionAlias
-
setDecryptionAlias
-
getSignatureVerificationAlias
-
setSignatureVerificationAlias
-
setPersistSignature
public void setPersistSignature(boolean persist) -
isRequireSignature
public boolean isRequireSignature() -
setRequireSignature
public void setRequireSignature(boolean requireSignature) -
isRequireEncryption
public boolean isRequireEncryption() -
setRequireEncryption
public void setRequireEncryption(boolean requireEncryption) -
setSubjectConstraints
Set a list of Strings corresponding to regular expression constraints on the subject DN of a certificate -
aroundReadFrom
public Object aroundReadFrom(jakarta.ws.rs.ext.ReaderInterceptorContext ctx) throws IOException, jakarta.ws.rs.WebApplicationException - Specified by:
aroundReadFromin interfacejakarta.ws.rs.ext.ReaderInterceptor- Throws:
IOExceptionjakarta.ws.rs.WebApplicationException
-