/** * Constructs a holder for v2 attribute certificates with a hash value for some type of object. * * <p><code>digestedObjectType</code> can be one of the following: * * <ul> * <li>0 - publicKey - A hash of the public key of the holder must be passed. * <li>1 - publicKeyCert - A hash of the public key certificate of the holder must be passed. * <li>2 - otherObjectDigest - A hash of some other object type must be passed. <code> * otherObjectTypeID</code> must not be empty. * </ul> * * <p>This cannot be used if a v1 attribute certificate is used. * * @param digestedObjectType The digest object type. * @param digestAlgorithm The algorithm identifier for the hash. * @param otherObjectTypeID The object type ID if <code>digestedObjectType</code> is <code> * otherObjectDigest</code>. * @param objectDigest The hash value. */ public AttributeCertificateHolder( int digestedObjectType, String digestAlgorithm, String otherObjectTypeID, byte[] objectDigest) { holder = new Holder( new ObjectDigestInfo( digestedObjectType, otherObjectTypeID, new AlgorithmIdentifier(digestAlgorithm), Arrays.clone(objectDigest))); }