diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2023-07-30 13:48:59 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2023-07-30 13:48:59 +0700 |
commit | 3e5ab53725678c662b5d351fb4a9bc2d3c5d8822 (patch) | |
tree | 8e492cfabb5965847e46b2a4aeb0430e4a202640 /crypto/src/x509/X509Certificate.cs | |
parent | Refactoring around digest calculation (diff) | |
download | BouncyCastle.NET-ed25519-3e5ab53725678c662b5d351fb4a9bc2d3c5d8822.tar.xz |
Add extra properties on X509Certificate
Diffstat (limited to 'crypto/src/x509/X509Certificate.cs')
-rw-r--r-- | crypto/src/x509/X509Certificate.cs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/crypto/src/x509/X509Certificate.cs b/crypto/src/x509/X509Certificate.cs index 944b627b0..465899042 100644 --- a/crypto/src/x509/X509Certificate.cs +++ b/crypto/src/x509/X509Certificate.cs @@ -265,6 +265,8 @@ namespace Org.BouncyCastle.X509 get { return c.EndDate.ToDateTime(); } } + public virtual TbsCertificateStructure TbsCertificate => c.TbsCertificate; + /// <summary> /// Return the Der encoded TbsCertificate data. /// This is the certificate component less the signature. @@ -464,6 +466,11 @@ namespace Org.BouncyCastle.X509 } /// <summary> + /// Return the plain SubjectPublicKeyInfo that holds the encoded public key. + /// </summary> + public virtual SubjectPublicKeyInfo SubjectPublicKeyInfo => c.SubjectPublicKeyInfo; + + /// <summary> /// Get the public key of the subject of the certificate. /// </summary> /// <returns>The public key parameters.</returns> |