Table of Contents

Struct PamojaTag

Namespace
Pamoja.Native.Interop
Assembly
Pamoja.Native.dll

A 16-byte authentication tag carried inline inside a blittable struct.

public struct PamojaTag
Inherited Members

Fields

Length

The width of a tag, in bytes.

public const int Length = 16

Field Value

int

Methods

From(ReadOnlySpan<byte>, string)

Reads a tag from exactly 16 bytes.

public static PamojaTag From(ReadOnlySpan<byte> bytes, string name)

Parameters

bytes ReadOnlySpan<byte>

The tag.

name string

What the bytes are, for the exception message.

Returns

PamojaTag

The tag.

Exceptions

ArgumentException

bytes is not Length bytes.

ToArray()

Copies the tag out as an array.

public readonly byte[] ToArray()

Returns

byte[]

The 16 bytes.