Class ProxyCSRImpl
- java.lang.Object
-
- eu.emi.security.authn.x509.helpers.proxy.ProxyCSRImpl
-
-
Constructor Summary
Constructors Constructor Description ProxyCSRImpl(org.bouncycastle.pkcs.PKCS10CertificationRequest csr, PrivateKey pk)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.bouncycastle.pkcs.PKCS10CertificationRequest
getCSR()
Returns the CSRPrivateKey
getPrivateKey()
Returns the generated private key of this CSR.boolean
hasPrivateKey()
-
-
-
Constructor Detail
-
ProxyCSRImpl
public ProxyCSRImpl(org.bouncycastle.pkcs.PKCS10CertificationRequest csr, PrivateKey pk)
- Parameters:
csr
- PKCS10 certification requestpk
- use null if PrivateKey was not generated
-
-
Method Detail
-
getCSR
public org.bouncycastle.pkcs.PKCS10CertificationRequest getCSR()
Returns the CSR
-
getPrivateKey
public PrivateKey getPrivateKey() throws IllegalStateException
Returns the generated private key of this CSR. If public key was manually set an exception is thrown.- Specified by:
getPrivateKey
in interfaceProxyCSR
- Returns:
- The private key.
- Throws:
IllegalStateException
- if the private and public keys were not generated
-
hasPrivateKey
public boolean hasPrivateKey()
- Specified by:
hasPrivateKey
in interfaceProxyCSR
- Returns:
- true if private key was generated and is available through
ProxyCSR.getPrivateKey()
-
-