Skip navigation links

Oracle® Information Rights Management Server Java API Reference
11g Release 1 (11.1.1)

E12907-03


oracle.irm.engine.types.content.crypto
Class CryptoSchema

java.lang.Object
  extended by oracle.irm.engine.types.content.crypto.CryptoSchema

All Implemented Interfaces:
Serializable

public class CryptoSchema
extends Object
implements Serializable

Crypto Schema type. A cryptography schema is used to link a KeySet with the set of cryptography algorithms used when working with that key set. A cryptography schema must be specified when creating a key set. The schema defines what types of cryptography key are generated and what key sizes are used. The cryptography schema is also used (via the key set) when sealing or unsealing content. When performing operations such as sealing or unsealing the schema defines what algorithms are used for encrypting (and decrypting) the content, signing the content and calculating digests.

XML Serialization

Crypto Schema instances can be serialized as an XML document. This XML document can also be used to recreate a Crypto Schema object. The following XML document shows an example Crypto Schema in XML form.

<?xml version="1.0" encoding="UTF-8"?>
<content:CryptoSchema xmlns:content="http://xmlns.oracle.com/irm/content">
    <id>AES128</id>
    <encryptionTransformation>AES/CTR/NoPadding</encryptionTransformation>
    <encryptionKeySize>128</encryptionKeySize>
    <sessionKeyEncryptionTransformation>AES/ECB/NoPadding</sessionKeyEncryptionTransformation>
    <sessionKeyEncryptionKeySize>128</sessionKeyEncryptionKeySize>
    <hmacSigningAlgorithm>HmacSHA256</hmacSigningAlgorithm>
    <hmacSigningKeySize>128</hmacSigningKeySize>
    <digestAlgorithm>SHA-256</digestAlgorithm>
    <useFips>false</useFips>
</content:CryptoSchema>

Crypto Schema instances can also be serialized by reference. A reference contains all the information needed to uniquely identify a Crypto Schema without needing to serialize the complete object. The reference form of the XML document can be seen below.

<?xml version="1.0" encoding="UTF-8"?>
<content:CryptoSchemaRef xmlns:content="http://xmlns.oracle.com/irm/content">
    <id>AES128</id>
</content:CryptoSchemaRef>

See Also:
Serialized Form

Constructor Summary
CryptoSchema()
          No argument constructor.
CryptoSchema(String id, String encryptionTransformation, int encryptionKeySize, String hmacSigningAlgorithm, int hmacSigningKeySize, String digestAlgorithm, String sessionKeyEncryptionTransformation, int sessionKeyEncryptionKeySize, boolean useFips)
          Constructor.

 

Method Summary
 String getDigestAlgorithm()
          The message digest algorithm.
 int getEncryptionKeySize()
          The encryption key size (in bits).
 String getEncryptionTransformation()
          The encryption transformation.
 String getHmacSigningAlgorithm()
          The signing algorithm specification.
 int getHmacSigningKeySize()
          The key size (in bits) for the HMAC operation.
 String getId()
          The identity of the schema.
 int getSessionKeyEncryptionKeySize()
          The key size (in bits) for session key encryption.
 String getSessionKeyEncryptionTransformation()
          The session key encryption transformation.
 boolean getUseFips()
          If true, only FIPS-approved cryptography implementations should be used.
 void setDigestAlgorithm(String value)
          The message digest algorithm.
 void setEncryptionKeySize(int value)
          The encryption key size (in bits).
 void setEncryptionTransformation(String value)
          The encryption transformation.
 void setHmacSigningAlgorithm(String value)
          The signing algorithm specification.
 void setHmacSigningKeySize(int value)
          The key size (in bits) for the HMAC operation.
 void setId(String value)
          The identity of the schema.
 void setSessionKeyEncryptionKeySize(int value)
          The key size (in bits) for session key encryption.
 void setSessionKeyEncryptionTransformation(String value)
          The session key encryption transformation.
 void setUseFips(boolean value)
          If true, only FIPS-approved cryptography implementations should be used.

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

CryptoSchema

public CryptoSchema()
No argument constructor.

CryptoSchema

public CryptoSchema(String id,
                    String encryptionTransformation,
                    int encryptionKeySize,
                    String hmacSigningAlgorithm,
                    int hmacSigningKeySize,
                    String digestAlgorithm,
                    String sessionKeyEncryptionTransformation,
                    int sessionKeyEncryptionKeySize,
                    boolean useFips)
Constructor.

Method Detail

getId

public String getId()
The identity of the schema. The identity must refer to a built-in engined defined cryptography schema.

Size

This property is limited to 50 characters in length.
Returns:
the value of the property.

setId

public void setId(String value)
The identity of the schema. The identity must refer to a built-in engined defined cryptography schema.

Size

This property is limited to 50 characters in length.
Parameters:
value - the new value for the property.

getEncryptionTransformation

public String getEncryptionTransformation()
The encryption transformation. The encryption transformation is used to encrypt (and decrypt) the main body of the sealed content using the per content generated session key.

e.g. AES/CTR/NoPadding.
Returns:
the value of the property.

setEncryptionTransformation

public void setEncryptionTransformation(String value)
The encryption transformation. The encryption transformation is used to encrypt (and decrypt) the main body of the sealed content using the per content generated session key.

e.g. AES/CTR/NoPadding.
Parameters:
value - the new value for the property.

getEncryptionKeySize

public int getEncryptionKeySize()
The encryption key size (in bits). This information is used with a key set is generated.
Returns:
the value of the property.

setEncryptionKeySize

public void setEncryptionKeySize(int value)
The encryption key size (in bits). This information is used with a key set is generated.
Parameters:
value - the new value for the property.

getHmacSigningAlgorithm

public String getHmacSigningAlgorithm()
The signing algorithm specification. The signing algorithm is used to sign the public header of the sealed content to prevent tampering.

e.g. HmacSHA256.
Returns:
the value of the property.

setHmacSigningAlgorithm

public void setHmacSigningAlgorithm(String value)
The signing algorithm specification. The signing algorithm is used to sign the public header of the sealed content to prevent tampering.

e.g. HmacSHA256.
Parameters:
value - the new value for the property.

getHmacSigningKeySize

public int getHmacSigningKeySize()
The key size (in bits) for the HMAC operation. This information is used with a key set is generated.
Returns:
the value of the property.

setHmacSigningKeySize

public void setHmacSigningKeySize(int value)
The key size (in bits) for the HMAC operation. This information is used with a key set is generated.
Parameters:
value - the new value for the property.

getDigestAlgorithm

public String getDigestAlgorithm()
The message digest algorithm. The digest is used to check the cipher text block has not been altered.

e.g. SHA-256.
Returns:
the value of the property.

setDigestAlgorithm

public void setDigestAlgorithm(String value)
The message digest algorithm. The digest is used to check the cipher text block has not been altered.

e.g. SHA-256.
Parameters:
value - the new value for the property.

getSessionKeyEncryptionTransformation

public String getSessionKeyEncryptionTransformation()
The session key encryption transformation. The session key transformation is used to encrypt the session key before embedding it into sealed content.

e.g. AES/ECB/NoPadding.
Returns:
the value of the property.

setSessionKeyEncryptionTransformation

public void setSessionKeyEncryptionTransformation(String value)
The session key encryption transformation. The session key transformation is used to encrypt the session key before embedding it into sealed content.

e.g. AES/ECB/NoPadding.
Parameters:
value - the new value for the property.

getSessionKeyEncryptionKeySize

public int getSessionKeyEncryptionKeySize()
The key size (in bits) for session key encryption. This information is used with a key set is generated.
Returns:
the value of the property.

setSessionKeyEncryptionKeySize

public void setSessionKeyEncryptionKeySize(int value)
The key size (in bits) for session key encryption. This information is used with a key set is generated.
Parameters:
value - the new value for the property.

getUseFips

public boolean getUseFips()
If true, only FIPS-approved cryptography implementations should be used.
Returns:
the value of the property.

setUseFips

public void setUseFips(boolean value)
If true, only FIPS-approved cryptography implementations should be used.
Parameters:
value - the new value for the property.

Skip navigation links

Oracle® Information Rights Management Server Java API Reference
11g Release 1 (11.1.1)

E12907-03


Copyright © 2011, Oracle. All rights reserved.