1 instantiation of CoseSigner
System.Security.Cryptography.Cose (1)
System\Security\Cryptography\Cose\CoseSigner.cs (1)
52
/// <paramref name="key"/> is <see cref="RSA"/>, use <see cref="
CoseSigner
(RSA, RSASignaturePadding, HashAlgorithmName, CoseHeaderMap?, CoseHeaderMap?)"/> to specify a signature padding.
88 references to CoseSigner
System.Security.Cryptography.Cose (88)
System\Security\Cryptography\Cose\CoseHelpers.cs (1)
228
internal static void WriteSignature(Span<byte> buffer, ReadOnlySpan<byte> toBeSigned, CborWriter writer,
CoseSigner
signer)
System\Security\Cryptography\Cose\CoseMultiSignMessage.cs (53)
60
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
67
public static byte[] SignDetached(byte[] detachedContent,
CoseSigner
signer, CoseHeaderMap? protectedHeaders = null, CoseHeaderMap? unprotectedHeaders = null, byte[]? associatedData = null)
90
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
97
public static byte[] SignEmbedded(byte[] embeddedContent,
CoseSigner
signer, CoseHeaderMap? protectedHeaders = null, CoseHeaderMap? unprotectedHeaders = null, byte[]? associatedData = null)
120
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
127
public static byte[] SignDetached(ReadOnlySpan<byte> detachedContent,
CoseSigner
signer, CoseHeaderMap? protectedHeaders = null, CoseHeaderMap? unprotectedHeaders = null, ReadOnlySpan<byte> associatedData = default)
147
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
154
public static byte[] SignEmbedded(ReadOnlySpan<byte> embeddedContent,
CoseSigner
signer, CoseHeaderMap? protectedHeaders = null, CoseHeaderMap? unprotectedHeaders = null, ReadOnlySpan<byte> associatedData = default)
177
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
185
public static byte[] SignDetached(Stream detachedContent,
CoseSigner
signer, CoseHeaderMap? protectedHeaders = null, CoseHeaderMap? unprotectedHeaders = null, ReadOnlySpan<byte> associatedData = default)
201
CoseSigner
signer,
241
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
250
CoseSigner
signer,
274
CoseSigner
signer,
305
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
312
public static bool TrySignDetached(ReadOnlySpan<byte> detachedContent, Span<byte> destination,
CoseSigner
signer, out int bytesWritten, CoseHeaderMap? protectedHeaders = null, CoseHeaderMap? unprotectedHeaders = null, ReadOnlySpan<byte> associatedData = default)
333
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
340
public static bool TrySignEmbedded(ReadOnlySpan<byte> embeddedContent, Span<byte> destination,
CoseSigner
signer, out int bytesWritten, CoseHeaderMap? protectedHeaders = null, CoseHeaderMap? unprotectedHeaders = null, ReadOnlySpan<byte> associatedData = default)
343
private static bool TrySign(ReadOnlySpan<byte> content, Span<byte> destination,
CoseSigner
signer, CoseHeaderMap? protectedHeaders, CoseHeaderMap? unprotectedHeaders, out int bytesWritten, ReadOnlySpan<byte> associatedData, bool isDetached)
366
CoseSigner
signer,
392
CoseSigner
signer,
414
private static void ValidateBeforeSign(
CoseSigner
signer, CoseHeaderMap? protectedHeaders, CoseHeaderMap? unprotectedHeaders)
439
CoseSigner
signer,
468
CoseSigner
signer,
498
private static int ComputeEncodedSize(
CoseSigner
signer, CoseHeaderMap? protectedHeaders, CoseHeaderMap? unprotectedHeaders, int contentLength, bool isDetached)
638
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
646
public void AddSignatureForEmbedded(
CoseSigner
signer, byte[]? associatedData = null)
657
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
665
public void AddSignatureForEmbedded(
CoseSigner
signer, ReadOnlySpan<byte> associatedData)
686
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
694
public void AddSignatureForDetached(byte[] detachedContent,
CoseSigner
signer, byte[]? associatedData = null)
710
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
718
public void AddSignatureForDetached(ReadOnlySpan<byte> detachedContent,
CoseSigner
signer, ReadOnlySpan<byte> associatedData = default)
743
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
751
public void AddSignatureForDetached(Stream detachedContent,
CoseSigner
signer, ReadOnlySpan<byte> associatedData = default)
763
private void AddSignatureCore(ReadOnlySpan<byte> contentBytes, Stream? contentStream,
CoseSigner
signer, ReadOnlySpan<byte> associatedData)
819
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
827
public Task AddSignatureForDetachedAsync(Stream detachedContent,
CoseSigner
signer, ReadOnlyMemory<byte> associatedData = default, CancellationToken cancellationToken = default)
839
private async Task AddSignatureCoreAsync(Stream content,
CoseSigner
signer, ReadOnlyMemory<byte> associatedData, CancellationToken cancellationToken)
System\Security\Cryptography\Cose\CoseSign1Message.cs (31)
44
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
51
public static byte[] SignDetached(byte[] detachedContent,
CoseSigner
signer, byte[]? associatedData = null)
69
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
76
public static byte[] SignEmbedded(byte[] embeddedContent,
CoseSigner
signer, byte[]? associatedData = null)
94
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
101
public static byte[] SignDetached(ReadOnlySpan<byte> detachedContent,
CoseSigner
signer, ReadOnlySpan<byte> associatedData = default)
118
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
125
public static byte[] SignEmbedded(ReadOnlySpan<byte> embeddedContent,
CoseSigner
signer, ReadOnlySpan<byte> associatedData = default)
146
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
153
public static byte[] SignDetached(Stream detachedContent,
CoseSigner
signer, ReadOnlySpan<byte> associatedData = default)
167
internal static byte[] SignCore(ReadOnlySpan<byte> contentBytes, Stream? contentStream,
CoseSigner
signer, ReadOnlySpan<byte> associatedData, bool isDetached)
197
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
204
public static Task<byte[]> SignDetachedAsync(Stream detachedContent,
CoseSigner
signer, ReadOnlyMemory<byte> associatedData = default, CancellationToken cancellationToken = default)
221
private static async Task<byte[]> SignAsyncCore(int expectedSize, Stream content,
CoseSigner
signer, ReadOnlyMemory<byte> associatedData, CancellationToken cancellationToken)
242
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
249
public static bool TrySignDetached(ReadOnlySpan<byte> detachedContent, Span<byte> destination,
CoseSigner
signer, out int bytesWritten, ReadOnlySpan<byte> associatedData = default)
264
/// The <see cref="
CoseSigner
.ProtectedHeaders"/> and <see cref="
CoseSigner
.UnprotectedHeaders"/> collections in <paramref name="signer"/> have one or more labels in common.
271
public static bool TrySignEmbedded(ReadOnlySpan<byte> embeddedContent, Span<byte> destination,
CoseSigner
signer, out int bytesWritten, ReadOnlySpan<byte> associatedData = default)
274
private static bool TrySign(ReadOnlySpan<byte> content, Span<byte> destination,
CoseSigner
signer, out int bytesWritten, ReadOnlySpan<byte> associatedData, bool isDetached)
293
internal static void ValidateBeforeSign(
CoseSigner
signer)
306
private static int CreateCoseSign1Message(ReadOnlySpan<byte> contentBytes, Stream? contentStream, Span<byte> buffer,
CoseSigner
signer, ReadOnlySpan<byte> associatedData, bool isDetached)
332
private static async Task<int> CreateCoseSign1MessageAsync(Stream content, byte[] buffer,
CoseSigner
signer, ReadOnlyMemory<byte> associatedData, CancellationToken cancellationToken)
927
private static int ComputeEncodedSize(
CoseSigner
signer, int contentLength, bool isDetached)
System\Security\Cryptography\Cose\CoseSigner.cs (3)
43
/// Initializes a new instance of the <see cref="
CoseSigner
"/> class.
92
/// Initializes a new instance of the <see cref="
CoseSigner
"/> class.
129
/// Initializes a new instance of the <see cref="
CoseSigner
"/> class.