org.blinkenlights.jid3.test
Class ID3V2Test.ExpandCryptoAgent

java.lang.Object
  extended byorg.blinkenlights.jid3.test.ID3V2Test.ExpandCryptoAgent
All Implemented Interfaces:
ICryptoAgent
Enclosing class:
ID3V2Test

public class ID3V2Test.ExpandCryptoAgent
extends java.lang.Object
implements ICryptoAgent


Constructor Summary
ID3V2Test.ExpandCryptoAgent()
           
 
Method Summary
 byte[] decrypt(byte[] abyEncryptedData, byte[] abyEncryptionData)
          Decrypt an array of bytes.
 byte[] encrypt(byte[] abyRawData, byte[] abyEncryptionData)
          Encrypt an array of bytes.
 java.lang.String getOwnerIdentifier()
          Get the owner identifier for this encryption method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ID3V2Test.ExpandCryptoAgent

public ID3V2Test.ExpandCryptoAgent()
Method Detail

decrypt

public byte[] decrypt(byte[] abyEncryptedData,
                      byte[] abyEncryptionData)
               throws ID3CryptException
Description copied from interface: ICryptoAgent
Decrypt an array of bytes.

Specified by:
decrypt in interface ICryptoAgent
Parameters:
abyEncryptedData - an array of encrypted bytes
abyEncryptionData - an array of bytes which are used to decrypt the encrypted data
Returns:
an array of unencrypted bytes
Throws:
ID3CryptException

encrypt

public byte[] encrypt(byte[] abyRawData,
                      byte[] abyEncryptionData)
               throws ID3CryptException
Description copied from interface: ICryptoAgent
Encrypt an array of bytes.

Specified by:
encrypt in interface ICryptoAgent
Parameters:
abyRawData - an array of bytes which are to be encrypted
abyEncryptionData - an array of bytes which are used to encrypt the raw data
Returns:
an array of encrypted bytes
Throws:
ID3CryptException

getOwnerIdentifier

public java.lang.String getOwnerIdentifier()
Description copied from interface: ICryptoAgent
Get the owner identifier for this encryption method. Each encrypted frame in a tag has its encryption method represented by a unique owner identifier. This value much match the owner identifier of a crypto agent to be used for decryption.

Specified by:
getOwnerIdentifier in interface ICryptoAgent
Returns:
a string containing the owner identifier