-
Deprecated.A new certificate handling package is created in the Java platform. This Certificate interface is entirely deprecated and is here to allow for a smooth transition to the new package.
@Deprecated public interface Certificate
This is an interface of abstract methods for managing a variety of identity certificates. An identity certificate is a guarantee by a principal that a public key is that of another principal. (A principal represents an entity such as an individual user, a group, or a corporation.)
In particular, this interface is intended to be a common abstraction for constructs that have different formats but important common uses. For example, different types of certificates, such as X.509 certificates and PGP certificates, share general certificate functionality (the need to encode and decode certificates) and some types of information, such as a public key, the principal whose key it is, and the guarantor guaranteeing that the public key is that of the specified principal. So an implementation of X.509 certificates and an implementation of PGP certificates can both utilize the Certificate interface, even though their formats and additional types and amounts of information stored are different.
Important: This interface is useful for cataloging and grouping objects sharing certain common uses. It does not have any semantics of its own. In particular, a Certificate object does not make any statement as to the validity of the binding. It is the duty of the application implementing this interface to verify the certificate and satisfy itself of its validity.
- See Also:
Certificate
-
-
Method Summary
Methods Modifier and Type Method and Description void
decode(InputStream stream)
Deprecated.Decodes a certificate from an input stream.void
encode(OutputStream stream)
Deprecated.Encodes the certificate to an output stream in a format that can be decoded by thedecode
method.String
getFormat()
Deprecated.Returns the name of the coding format.Principal
getGuarantor()
Deprecated.Returns the guarantor of the certificate, that is, the principal guaranteeing that the public key associated with this certificate is that of the principal associated with this certificate.Principal
getPrincipal()
Deprecated.Returns the principal of the principal-key pair being guaranteed by the guarantor.PublicKey
getPublicKey()
Deprecated.Returns the key of the principal-key pair being guaranteed by the guarantor.String
toString(boolean detailed)
Deprecated.Returns a string that represents the contents of the certificate.
-
-
-
Method Detail
-
getGuarantor
Principal getGuarantor()
Deprecated.Returns the guarantor of the certificate, that is, the principal guaranteeing that the public key associated with this certificate is that of the principal associated with this certificate. For X.509 certificates, the guarantor will typically be a Certificate Authority (such as the United States Postal Service or Verisign, Inc.).- Returns:
- the guarantor which guaranteed the principal-key binding.
-
getPrincipal
Principal getPrincipal()
Deprecated.Returns the principal of the principal-key pair being guaranteed by the guarantor.- Returns:
- the principal to which this certificate is bound.
-
getPublicKey
PublicKey getPublicKey()
Deprecated.Returns the key of the principal-key pair being guaranteed by the guarantor.- Returns:
- the public key that this certificate certifies belongs to a particular principal.
-
encode
void encode(OutputStream stream) throws KeyException, IOException
Deprecated.Encodes the certificate to an output stream in a format that can be decoded by thedecode
method.- Parameters:
stream
- the output stream to which to encode the certificate.- Throws:
KeyException
- if the certificate is not properly initialized, or data is missing, etc.IOException
- if a stream exception occurs while trying to output the encoded certificate to the output stream.- See Also:
decode(java.io.InputStream)
,getFormat()
-
decode
void decode(InputStream stream) throws KeyException, IOException
Deprecated.Decodes a certificate from an input stream. The format should be that returned bygetFormat
and produced byencode
.- Parameters:
stream
- the input stream from which to fetch the data being decoded.- Throws:
KeyException
- if the certificate is not properly initialized, or data is missing, etc.IOException
- if an exception occurs while trying to input the encoded certificate from the input stream.- See Also:
encode(java.io.OutputStream)
,getFormat()
-
getFormat
String getFormat()
Deprecated.Returns the name of the coding format. This is used as a hint to find an appropriate parser. It could be "X.509", "PGP", etc. This is the format produced and understood by theencode
anddecode
methods.- Returns:
- the name of the coding format.
-
toString
String toString(boolean detailed)
Deprecated.Returns a string that represents the contents of the certificate.- Parameters:
detailed
- whether or not to give detailed information about the certificate- Returns:
- a string representing the contents of the certificate
-
-
Nederlandse vertaling
U hebt gevraagd om deze site in het Nederlands te bezoeken. Voor nu wordt alleen de interface vertaald, maar nog niet alle inhoud.Als je me wilt helpen met vertalingen, is je bijdrage welkom. Het enige dat u hoeft te doen, is u op de site registreren en mij een bericht sturen waarin u wordt gevraagd om u toe te voegen aan de groep vertalers, zodat u de gewenste pagina's kunt vertalen. Een link onderaan elke vertaalde pagina geeft aan dat u de vertaler bent en heeft een link naar uw profiel.
Bij voorbaat dank.
Document heeft de 11/06/2005 gemaakt, de laatste keer de 04/03/2020 gewijzigd
Bron van het afgedrukte document:https://www.gaudry.be/nl/java-api-rf-java/security/Certificate.html
De infobrol is een persoonlijke site waarvan de inhoud uitsluitend mijn verantwoordelijkheid is. De tekst is beschikbaar onder CreativeCommons-licentie (BY-NC-SA). Meer info op de gebruiksvoorwaarden en de auteur.
Referenties
Deze verwijzingen en links verwijzen naar documenten die geraadpleegd zijn tijdens het schrijven van deze pagina, of die aanvullende informatie kunnen geven, maar de auteurs van deze bronnen kunnen niet verantwoordelijk worden gehouden voor de inhoud van deze pagina.
De auteur Deze site is als enige verantwoordelijk voor de manier waarop de verschillende concepten, en de vrijheden die met de referentiewerken worden genomen, hier worden gepresenteerd. Vergeet niet dat u meerdere broninformatie moet doorgeven om het risico op fouten te verkleinen.