public class

DistributionPointName

extends Object
java.lang.Object
   ↳ sun.security.x509.DistributionPointName

Class Overview

Represents the DistributionPointName ASN.1 type. It is used in the CRL Distribution Points Extension (OID = 2.5.29.31) and the Issuing Distribution Point Extension (OID = 2.5.29.28).

Its ASN.1 definition is:


     DistributionPointName ::= CHOICE {
         fullName                  [0] GeneralNames,
         nameRelativeToCRLIssuer   [1] RelativeDistinguishedName }

     GeneralNames ::= SEQUENCE SIZE (1..MAX) OF GeneralName

     GeneralName ::= CHOICE {
         otherName                 [0] INSTANCE OF OTHER-NAME,
         rfc822Name                [1] IA5String,
         dNSName                   [2] IA5String,
         x400Address               [3] ORAddress,
         directoryName             [4] Name,
         ediPartyName              [5] EDIPartyName,
         uniformResourceIdentifier [6] IA5String,
         iPAddress                 [7] OCTET STRING,
         registeredID              [8] OBJECT IDENTIFIER }

     RelativeDistinguishedName ::= SET OF AttributeTypeAndValue

     AttributeTypeAndValue ::= SEQUENCE {
         type    AttributeType,
         value   AttributeValue }

     AttributeType ::= OBJECT IDENTIFIER

     AttributeValue ::= ANY DEFINED BY AttributeType

 

Instances of this class are designed to be immutable. However, since this is an internal API we do not use defensive cloning for values for performance reasons. It is the responsibility of the consumer to ensure that no mutable elements are modified.

Summary

Public Constructors
DistributionPointName(GeneralNames fullName)
Creates a distribution point name using a full name.
DistributionPointName(RDN relativeName)
Creates a distribution point name using a relative name.
DistributionPointName(DerValue encoding)
Creates a distribution point name from its DER-encoded form.
Public Methods
void encode(DerOutputStream out)
Encodes the distribution point name and writes it to the DerOutputStream.
boolean equals(Object obj)
Compare an object to this distribution point name for equality.
GeneralNames getFullName()
Returns the full name for the distribution point or null if not set.
RDN getRelativeName()
Returns the relative name for the distribution point or null if not set.
int hashCode()
Returns the hash code for this distribution point name.
String toString()
Returns a printable string of the distribution point name.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public DistributionPointName (GeneralNames fullName)

Creates a distribution point name using a full name.

Parameters
fullName the name for the distribution point.
Throws
IllegalArgumentException if fullName is null.

public DistributionPointName (RDN relativeName)

Creates a distribution point name using a relative name.

Parameters
relativeName the name of the distribution point relative to the name of the issuer of the CRL.
Throws
IllegalArgumentException if relativeName is null.

public DistributionPointName (DerValue encoding)

Creates a distribution point name from its DER-encoded form.

Parameters
encoding the DER-encoded value.
Throws
IOException on decoding error.

Public Methods

public void encode (DerOutputStream out)

Encodes the distribution point name and writes it to the DerOutputStream.

Parameters
out the output stream.
Throws
IOException on encoding error.

public boolean equals (Object obj)

Compare an object to this distribution point name for equality.

Parameters
obj Object to be compared to this
Returns
  • true if objects match; false otherwise

public GeneralNames getFullName ()

Returns the full name for the distribution point or null if not set.

public RDN getRelativeName ()

Returns the relative name for the distribution point or null if not set.

public int hashCode ()

Returns the hash code for this distribution point name.

Returns
  • the hash code.

public String toString ()

Returns a printable string of the distribution point name.

Returns
  • a string representation of the object.