Represents an opaque type. An opaque type merely decodes the tag and tag class and stores the contents octets in an OCTET STRING. The opaque type is represented in ASN.1 as
[UNIVERSAL x] IMPLICIT OCTET STRING
where
x
is the tag.
The opaque type is comparable to an {@link ASN1OpenType open type} in that it matches any type (just like thedeprecated ANY type) on decoding. The encoding can be reconstructed easily. This type is used whenever decoding of a structure should be deferred to a later point in time. For instance an AlgorithmIdentifier implementation can use an opaque type in order to decode algorithm parameters. The encoding of the algorithm parameters is then done by JCA/JCE classes later on.
One drawback of the opaque type is that special handling by the encoders and decoders is rquired to make it work properly. The main problem is that the opaque type does not store whether the underlying type is constructed or primitive. This decision must be made by the encoder.
Due to this limitation the opaque type can be used only for decoding types of class UNIVERSAL.
@author Volker Roth
@author Stefan Endler
@version "$Id: ASN1Opaque.java,v 1.3 2007/08/11 18:21:50 sendler Exp $"