diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2023-01-16 18:36:02 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2023-01-16 18:36:02 +0700 |
commit | c93162764c5097f65f2792c577f8a7658c6ee0dc (patch) | |
tree | 52bc090595bcb81e2db276c9023176deb02897b1 /crypto/src/openssl/MiscPemGenerator.cs | |
parent | Refactoring in RsaCoreEngine (diff) | |
download | BouncyCastle.NET-ed25519-c93162764c5097f65f2792c577f8a7658c6ee0dc.tar.xz |
Refactoring in PEM classes
Diffstat (limited to 'crypto/src/openssl/MiscPemGenerator.cs')
-rw-r--r-- | crypto/src/openssl/MiscPemGenerator.cs | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/crypto/src/openssl/MiscPemGenerator.cs b/crypto/src/openssl/MiscPemGenerator.cs index 0e918f793..fe2583063 100644 --- a/crypto/src/openssl/MiscPemGenerator.cs +++ b/crypto/src/openssl/MiscPemGenerator.cs @@ -32,15 +32,11 @@ namespace Org.BouncyCastle.OpenSsl private readonly SecureRandom random; public MiscPemGenerator(object obj) + : this(obj, null, null, null) { - this.obj = obj; } - public MiscPemGenerator( - object obj, - string algorithm, - char[] password, - SecureRandom random) + public MiscPemGenerator(object obj, string algorithm, char[] password, SecureRandom random) { this.obj = obj; this.algorithm = algorithm; @@ -54,9 +50,7 @@ namespace Org.BouncyCastle.OpenSsl throw new ArgumentNullException("obj"); if (obj is AsymmetricCipherKeyPair keyPair) - { return CreatePemObject(keyPair.Private); - } string type; byte[] encoding; |