crypto

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2019 License: MIT Imports: 5 Imported by: 0

README

Package Crypto

Purpose

This package will be used to stre generic cryptographic schemes, such as sha3, checksum and random entropy. This is different to cryptographic schemes such as bulletproof and vrf which have one or two specific usecases in the repo.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Checksum

func Checksum(data []byte) (uint32, error)

Checksum hashes the data with Sha3256 and returns the first four bytes

func CompareChecksum

func CompareChecksum(data []byte, want uint32) bool

CompareChecksum takes data and an expected checksum Returns true if the checksum of the given data is equal to the expected checksum

func RandEntropy

func RandEntropy(n uint32) ([]byte, error)

RandEntropy takes an argument n and populates a byte slice of size n with random input.

Types

This section is empty.

Directories

Path Synopsis
Package base58 implementation ported from : https://github.com/mr-tron/base58
Package base58 implementation ported from : https://github.com/mr-tron/base58
Package bls implements the compact BLS Multisignature construction which preappends the public key to the signature according to the *plain public-key model*.
Package bls implements the compact BLS Multisignature construction which preappends the public key to the signature according to the *plain public-key model*.

Jump to

Keyboard shortcuts

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