Package eu.emi.security.authn.x509.proxy
Class ProxyGenerator
- java.lang.Object
-
- eu.emi.security.authn.x509.proxy.ProxyGenerator
-
public class ProxyGenerator extends java.lang.Object
Utilities to create proxy certificates.- Author:
- K. Benedyczak
-
-
Constructor Summary
Constructors Constructor Description ProxyGenerator()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ProxyCertificate
generate(ProxyCertificateOptions param, java.security.PrivateKey privateKey)
Generate the proxy certificate object from the local certificate.static java.security.cert.X509Certificate[]
generate(ProxyRequestOptions param, java.security.PrivateKey privateKey)
Generate the proxy certificate object from the received Certificate Signing Request.
-
-
-
Method Detail
-
generate
public static ProxyCertificate generate(ProxyCertificateOptions param, java.security.PrivateKey privateKey) throws java.security.InvalidKeyException, java.security.SignatureException, java.security.NoSuchAlgorithmException, java.security.cert.CertificateParsingException, java.io.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:
java.security.InvalidKeyException
- invalid key exceptionjava.security.SignatureException
- signature exceptionjava.security.NoSuchAlgorithmException
- no such algorithm exceptionjava.security.cert.CertificateParsingException
- certificate parsing exceptionjava.io.IOException
- IO exception
-
generate
public static java.security.cert.X509Certificate[] generate(ProxyRequestOptions param, java.security.PrivateKey privateKey) throws java.security.InvalidKeyException, java.security.SignatureException, java.security.NoSuchAlgorithmException, java.security.cert.CertificateParsingException, java.io.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:
java.security.InvalidKeyException
- invalid key exceptionjava.security.SignatureException
- signature exceptionjava.security.NoSuchAlgorithmException
- no such algorithm exceptionjava.security.cert.CertificateParsingException
- certificate parsing exceptionjava.io.IOException
- IO exception
-
-