summary refs log tree commit diff
path: root/crypto/src/cms/SignerInfoGenerator.cs
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/src/cms/SignerInfoGenerator.cs')
-rw-r--r--crypto/src/cms/SignerInfoGenerator.cs11
1 files changed, 11 insertions, 0 deletions
diff --git a/crypto/src/cms/SignerInfoGenerator.cs b/crypto/src/cms/SignerInfoGenerator.cs
index df8d1d0a1..786749cb5 100644
--- a/crypto/src/cms/SignerInfoGenerator.cs
+++ b/crypto/src/cms/SignerInfoGenerator.cs
@@ -58,6 +58,16 @@ namespace Org.BouncyCastle.Cms
         {
             this.certificate = certificate;
         }
+
+        public SignerInfoGeneratorBuilder NewBuilder()
+        {
+            SignerInfoGeneratorBuilder builder = new SignerInfoGeneratorBuilder();
+            builder.WithSignedAttributeGenerator(signedGen);
+            builder.WithUnsignedAttributeGenerator(unsignedGen);
+            builder.SetDirectSignature(isDirectSignature);
+            return builder;
+        }
+
     }
 
     public class SignerInfoGeneratorBuilder
@@ -69,6 +79,7 @@ namespace Org.BouncyCastle.Cms
         public SignerInfoGeneratorBuilder()
         {
         }
+    
 
         /**
          * If the passed in flag is true, the signer signature will be based on the data, not