S.S.C.Cose: Add new MultiSign APIs and address API review feedback on existing ones...
authorDavid CantĂș <dacantu@microsoft.com>
Thu, 7 Jul 2022 19:40:01 +0000 (14:40 -0500)
committerGitHub <noreply@github.com>
Thu, 7 Jul 2022 19:40:01 +0000 (14:40 -0500)
commit97d96f2ab6f739637e56d414840544b56e67482c
tree08c8c160b4a83618278cb964bf7a3850f42d2f5d
parentdd438664d6657a495bcd22d023c46a7bdff26dcd
S.S.C.Cose: Add new MultiSign APIs and address API review feedback on existing ones (#71390)

* Make full assembly unsupported on browser

* Add new MultiSign APIs and address API review feedback on existing ones

* Add SignaturePadding tests and address #70189

* Address feedback (typos and leftover code)

* Add tests for CoseHeaderValue and wrap CborReader/Writer errors

* nits and line chopping

* Move alg. validations to CoseSigner and add remaining AddSignatureFor* APIs
38 files changed:
src/libraries/System.Security.Cryptography.Cose/Directory.Build.props
src/libraries/System.Security.Cryptography.Cose/ref/System.Security.Cryptography.Cose.cs
src/libraries/System.Security.Cryptography.Cose/src/Resources/Strings.resx
src/libraries/System.Security.Cryptography.Cose/src/System.Security.Cryptography.Cose.csproj
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseHeaderLabel.cs
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseHeaderMap.cs
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseHeaderValue.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseHelpers.cs
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseMessage.cs
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseMultiSignMessage.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseSign1Message.cs
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseSignature.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/CoseSigner.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/KeyType.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/KnownCoseAlgorithms.cs
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/KnownHeaders.cs
src/libraries/System.Security.Cryptography.Cose/src/System/Security/Cryptography/Cose/SigStructureContext.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseHeaderMapTests.cs
src/libraries/System.Security.Cryptography.Cose/tests/CoseHeaderValueTests.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeMultiSign.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecodeSign1.cs [moved from src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.DecoseSign1.cs with 82% similarity]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.Sign.CustomHeaderMaps.Stream.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.Sign.CustomHeaderMaps.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.Sign.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMessageTests.Verify.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMultiSignMessageTests.Sign.CustomHeaderMaps.Stream.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMultiSignMessageTests.Sign.CustomHeaderMaps.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMultiSignMessageTests.Sign.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMultiSignMessageTests.Verify.Stream.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseMultiSignMessageTests.Verify.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseSign1MessageTests.Sign.CustomHeaderMaps.Stream.cs
src/libraries/System.Security.Cryptography.Cose/tests/CoseSign1MessageTests.Sign.CustomHeaderMaps.cs
src/libraries/System.Security.Cryptography.Cose/tests/CoseSign1MessageTests.Sign.cs
src/libraries/System.Security.Cryptography.Cose/tests/CoseSign1MessageTests.Verify.Stream.cs
src/libraries/System.Security.Cryptography.Cose/tests/CoseSign1MessageTests.Verify.cs
src/libraries/System.Security.Cryptography.Cose/tests/CoseSignerTests.cs [new file with mode: 0644]
src/libraries/System.Security.Cryptography.Cose/tests/CoseTestHelpers.cs
src/libraries/System.Security.Cryptography.Cose/tests/System.Security.Cryptography.Cose.Tests.csproj