blake2s

package
v1.0.17 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 19, 2022 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Overview

* Copyright 2020 The openwallet Authors * This file is part of the openwallet library. * * The openwallet library is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * The openwallet library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details.

* Copyright 2020 The openwallet Authors * This file is part of the openwallet library. * * The openwallet library is free software: you can redistribute it and/or modify * it under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * The openwallet library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details.

Index

Constants

View Source
const (
	BlockSize  = 64
	Size       = 32
	SaltSize   = 8
	PersonSize = 8
	KeySize    = 32
)

Variables

This section is empty.

Functions

func New

func New(c *Config) (hash.Hash, error)

func New256

func New256() hash.Hash

func NewMAC

func NewMAC(outBytes uint8, key []byte) hash.Hash

func Sum256

func Sum256(data []byte) [Size]byte

Types

type Config

type Config struct {
	Size   uint8
	Key    []byte
	Salt   []byte
	Person []byte
	Tree   *Tree
}

type Tree

type Tree struct {
	Fanout        uint8
	MaxDepth      uint8
	LeafSize      uint32
	NodeOffset    uint64
	NodeDepth     uint8
	InnerHashSize uint8
	IsLastNode    bool
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL