org.apache.cxf.rs.security.jose.jwe
Class AbstractWrapKeyEncryptionAlgorithm

java.lang.Object
  extended by org.apache.cxf.rs.security.jose.jwe.AbstractWrapKeyEncryptionAlgorithm
All Implemented Interfaces:
KeyEncryptionProvider
Direct Known Subclasses:
AesGcmWrapKeyEncryptionAlgorithm, AesWrapKeyEncryptionAlgorithm, RSAKeyEncryptionAlgorithm

public abstract class AbstractWrapKeyEncryptionAlgorithm
extends Object
implements KeyEncryptionProvider


Field Summary
protected static Logger LOG
           
 
Constructor Summary
protected AbstractWrapKeyEncryptionAlgorithm(Key key, boolean wrap, Set<String> supportedAlgorithms)
           
protected AbstractWrapKeyEncryptionAlgorithm(Key key, KeyAlgorithm jweAlgo, boolean wrap, Set<String> supportedAlgorithms)
           
protected AbstractWrapKeyEncryptionAlgorithm(Key key, KeyAlgorithm jweAlgo, Set<String> supportedAlgorithms)
           
protected AbstractWrapKeyEncryptionAlgorithm(Key key, Set<String> supportedAlgorithms)
           
 
Method Summary
protected  String checkAlgorithm(String algo)
           
protected  void checkAlgorithms(JweHeaders headers)
           
 KeyAlgorithm getAlgorithm()
           
protected  AlgorithmParameterSpec getAlgorithmParameterSpec(JweHeaders headers)
           
protected  String getContentEncryptionAlgoJava(JweHeaders headers)
           
 byte[] getEncryptedContentEncryptionKey(JweHeaders headers, byte[] cek)
           
protected  String getKeyEncryptionAlgoJava(JweHeaders headers)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG

protected static final Logger LOG
Constructor Detail

AbstractWrapKeyEncryptionAlgorithm

protected AbstractWrapKeyEncryptionAlgorithm(Key key,
                                             Set<String> supportedAlgorithms)

AbstractWrapKeyEncryptionAlgorithm

protected AbstractWrapKeyEncryptionAlgorithm(Key key,
                                             boolean wrap,
                                             Set<String> supportedAlgorithms)

AbstractWrapKeyEncryptionAlgorithm

protected AbstractWrapKeyEncryptionAlgorithm(Key key,
                                             KeyAlgorithm jweAlgo,
                                             Set<String> supportedAlgorithms)

AbstractWrapKeyEncryptionAlgorithm

protected AbstractWrapKeyEncryptionAlgorithm(Key key,
                                             KeyAlgorithm jweAlgo,
                                             boolean wrap,
                                             Set<String> supportedAlgorithms)
Method Detail

getAlgorithm

public KeyAlgorithm getAlgorithm()
Specified by:
getAlgorithm in interface KeyEncryptionProvider

getEncryptedContentEncryptionKey

public byte[] getEncryptedContentEncryptionKey(JweHeaders headers,
                                               byte[] cek)
Specified by:
getEncryptedContentEncryptionKey in interface KeyEncryptionProvider

getKeyEncryptionAlgoJava

protected String getKeyEncryptionAlgoJava(JweHeaders headers)

getContentEncryptionAlgoJava

protected String getContentEncryptionAlgoJava(JweHeaders headers)

getAlgorithmParameterSpec

protected AlgorithmParameterSpec getAlgorithmParameterSpec(JweHeaders headers)

checkAlgorithm

protected String checkAlgorithm(String algo)

checkAlgorithms

protected void checkAlgorithms(JweHeaders headers)


Apache CXF