Package eu.emi.security.authn.x509.proxy
Class ProxyGenerator
java.lang.Object
eu.emi.security.authn.x509.proxy.ProxyGenerator
Utilities to create proxy certificates.
- Author:
- K. Benedyczak
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ProxyCertificategenerate(ProxyCertificateOptions param, PrivateKey privateKey) Generate the proxy certificate object from the local certificate.static X509Certificate[]generate(ProxyRequestOptions param, PrivateKey privateKey) Generate the proxy certificate object from the received Certificate Signing Request.
-
Constructor Details
-
ProxyGenerator
public ProxyGenerator()
-
-
Method Details
-
generate
public static ProxyCertificate generate(ProxyCertificateOptions param, PrivateKey privateKey) throws InvalidKeyException, SignatureException, NoSuchAlgorithmException, CertificateParsingException, IOException Generate the proxy certificate object from the local certificate.- Parameters:
param- proxy parametersprivateKey- key to sign the proxy- Returns:
- a newly created proxy certificate, wrapped together with a private key if it was also generated.
- Throws:
InvalidKeyException- invalid key exceptionSignatureException- signature exceptionNoSuchAlgorithmException- no such algorithm exceptionCertificateParsingException- certificate parsing exceptionIOException- IO exception
-
generate
public static X509Certificate[] generate(ProxyRequestOptions param, PrivateKey privateKey) throws InvalidKeyException, SignatureException, NoSuchAlgorithmException, CertificateParsingException, IOException Generate the proxy certificate object from the received Certificate Signing Request.- Parameters:
param- proxy parametersprivateKey- key to sign the proxy- Returns:
- chain with the new proxy on the first position
- Throws:
InvalidKeyException- invalid key exceptionSignatureException- signature exceptionNoSuchAlgorithmException- no such algorithm exceptionCertificateParsingException- certificate parsing exceptionIOException- IO exception
-