core/crypto/poly1305

poly1305

Types

1

Constants

2

Procedures

6

final

final :: proc(ctx: ^Context, dst: []u8)Source

final finalizes the Context, writes the tag to dst, and calls reset on the Context.

init

init :: proc(ctx: ^Context, key: []u8)Source

init initializes a Context with the specified key. The key SHOULD be unique and MUST be unpredictable for each invocation.

reset

reset :: proc(ctx: ^Context)Source

reset sanitizes the Context. The Context must be re-initialized to be used again.

sum

sum :: proc(dst: []u8, msg: []u8, key: []u8)Source

sum will compute the Poly1305 MAC with the key over msg, and write the computed tag to dst. It requires that the dst buffer is the tag size.

The key SHOULD be unique and MUST be unpredictable for each invocation.

verify

verify :: proc(tag: []u8, msg: []u8, key: []u8) -> (bool)Source

verify will verify the Poly1305 tag computed with the key over msg and return true if and only if (⟺) the tag is valid. It requires that the tag is correctly sized.

Reference search

Find anything

Documentation preferences

Settings

System theme variants

Used only while Theme is set to System.