diff --git a/src/libfintx.EBICS/Commands/Command.cs b/src/libfintx.EBICS/Commands/Command.cs index 7545c27..20cf60c 100644 --- a/src/libfintx.EBICS/Commands/Command.cs +++ b/src/libfintx.EBICS/Commands/Command.cs @@ -312,12 +312,17 @@ protected XmlDocument AuthenticateXml(XmlDocument doc, string referenceUri, protected byte[] SignData(byte[] data, SignKeyPair kp) { - if (kp.Version != SignVersion.A005) + if (kp.Version == SignVersion.A005) { - throw new CryptographicException($"Only signature version {SignVersion.A005} is supported right now"); + return kp.PrivateKey.SignData(data, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1); + } + else if (kp.Version == SignVersion.A006) + { + return kp.PrivateKey.SignData(data, HashAlgorithmName.SHA256, RSASignaturePadding.Pss); } + else + throw new CryptographicException($"Only signature version {SignVersion.A005} is supported right now"); - return kp.PrivateKey.SignData(data, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1); } public override string ToString() diff --git a/src/libfintx.EBICS/libfintx.EBICS.csproj b/src/libfintx.EBICS/libfintx.EBICS.csproj index a2288e5..c001c8c 100644 --- a/src/libfintx.EBICS/libfintx.EBICS.csproj +++ b/src/libfintx.EBICS/libfintx.EBICS.csproj @@ -1,7 +1,7 @@  - netstandard2.0 + net462 diff --git a/src/libfintx.EBICSConfig/libfintx.EBICSConfig.csproj b/src/libfintx.EBICSConfig/libfintx.EBICSConfig.csproj index 1b9deb6..ad1a0a9 100644 --- a/src/libfintx.EBICSConfig/libfintx.EBICSConfig.csproj +++ b/src/libfintx.EBICSConfig/libfintx.EBICSConfig.csproj @@ -1,7 +1,7 @@  - netstandard2.0 + net462