diff --git a/crypto/src/pkix/PkixCertPathBuilderException.cs b/crypto/src/pkix/PkixCertPathBuilderException.cs
index 46845d287..81c833459 100644
--- a/crypto/src/pkix/PkixCertPathBuilderException.cs
+++ b/crypto/src/pkix/PkixCertPathBuilderException.cs
@@ -1,22 +1,32 @@
using System;
+using System.Runtime.Serialization;
using Org.BouncyCastle.Security;
namespace Org.BouncyCastle.Pkix
{
- /// <summary>
- /// Summary description for PkixCertPathBuilderException.
- /// </summary>
-#if !PORTABLE
[Serializable]
-#endif
- public class PkixCertPathBuilderException : GeneralSecurityException
+ public class PkixCertPathBuilderException
+ : GeneralSecurityException
{
- public PkixCertPathBuilderException() : base() { }
-
- public PkixCertPathBuilderException(string message) : base(message) { }
+ public PkixCertPathBuilderException()
+ : base()
+ {
+ }
- public PkixCertPathBuilderException(string message, Exception exception) : base(message, exception) { }
-
+ public PkixCertPathBuilderException(string message)
+ : base(message)
+ {
+ }
+
+ public PkixCertPathBuilderException(string message, Exception innerException)
+ : base(message, innerException)
+ {
+ }
+
+ protected PkixCertPathBuilderException(SerializationInfo info, StreamingContext context)
+ : base(info, context)
+ {
+ }
}
}
diff --git a/crypto/src/pkix/PkixCertPathValidatorException.cs b/crypto/src/pkix/PkixCertPathValidatorException.cs
index f2152bcd3..effb60569 100644
--- a/crypto/src/pkix/PkixCertPathValidatorException.cs
+++ b/crypto/src/pkix/PkixCertPathValidatorException.cs
@@ -45,8 +45,8 @@ namespace Org.BouncyCastle.Pkix
{
}
- public PkixCertPathValidatorException(string message, Exception exception)
- : base(message, exception)
+ public PkixCertPathValidatorException(string message, Exception innerException)
+ : base(message, innerException)
{
}
@@ -55,10 +55,10 @@ namespace Org.BouncyCastle.Pkix
/// detail message, cause, certification path, and index.
/// </summary>
/// <param name="message">the detail message (or <code>null</code> if none)</param>
- /// <param name="exception">the cause (or <code>null</code> if none)</param>
+ /// <param name="innerException">the cause (or <code>null</code> if none)</param>
/// <param name="index">the index of the certificate in the certification path that</param> *
- public PkixCertPathValidatorException(string message, Exception exception, int index)
- : base(message, exception)
+ public PkixCertPathValidatorException(string message, Exception innerException, int index)
+ : base(message, innerException)
{
if (index < -1)
throw new ArgumentException("cannot be < -1", nameof(index));
diff --git a/crypto/src/pkix/PkixNameConstraintValidatorException.cs b/crypto/src/pkix/PkixNameConstraintValidatorException.cs
index d0882ca96..c67123506 100644
--- a/crypto/src/pkix/PkixNameConstraintValidatorException.cs
+++ b/crypto/src/pkix/PkixNameConstraintValidatorException.cs
@@ -1,16 +1,30 @@
using System;
+using System.Runtime.Serialization;
namespace Org.BouncyCastle.Pkix
{
-#if !PORTABLE
[Serializable]
-#endif
public class PkixNameConstraintValidatorException
: Exception
{
- public PkixNameConstraintValidatorException(string msg)
- : base(msg)
- {
- }
+ public PkixNameConstraintValidatorException()
+ : base()
+ {
+ }
+
+ public PkixNameConstraintValidatorException(string message)
+ : base(message)
+ {
+ }
+
+ public PkixNameConstraintValidatorException(string message, Exception innerException)
+ : base(message, innerException)
+ {
+ }
+
+ protected PkixNameConstraintValidatorException(SerializationInfo info, StreamingContext context)
+ : base(info, context)
+ {
+ }
}
}
|