mimc

package
v0.1.0-alpha Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MiMC

type MiMC struct {
	Params
}

MiMC reference implementation (pure Go)

func NewMiMC

func NewMiMC(seed string) MiMC

NewMiMC returns a MiMCImpl object, pure-go reference implementation

func (MiMC) Hash

func (h MiMC) Hash(data ...curve.Element) curve.Element

Hash hash using Miyaguchi–Preneel: https://en.wikipedia.org/wiki/One-way_compression_function The XOR operation is replaced by field addition, data is in Montgomery form

type Params

type Params []curve.Element

Params constants for the mimc hash function

func NewParams

func NewParams(seed string) Params

Jump to

Keyboard shortcuts

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