Struct iron_csrf::ChaCha20Poly1305CsrfProtection [] [src]

pub struct ChaCha20Poly1305CsrfProtection { /* fields omitted */ }

Uses the ChaCha20Poly1305 AEAD to provide signed, encrypted CSRF tokens and cookies.

Methods

impl ChaCha20Poly1305CsrfProtection
[src]

Using scrypt with params n=14, r=8, p=1, generate the key material used for the underlying ChaCha20Poly1305 AEAD.

Panics

This function may panic if the underlying library fails catastrophically.

Trait Implementations

impl CsrfProtection for ChaCha20Poly1305CsrfProtection
[src]

Returns the internal representation of a CSRF cookie given a slice of decoded bytes.

Returns the internal representation of a CSRF token given a slice of decoded bytes.

Creates a CSRF token and cookie with the given TTL in seconds.

Returns whether