zeroknowledge

package
v0.0.0-...-d6dc4fc Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Prove

func Prove(d Data) string

Prover sends the hash of the data to the verifier.

func Verify

func Verify(providedHash, expectedHash string) bool

Verifier checks if the provided hash matches the expected hash.

Types

type Data

type Data struct {
	Content string
}

Data represents the data structure we wish to prove ownership of.

func (*Data) GenerateHash

func (d *Data) GenerateHash() string

GenerateHash creates a SHA-256 hash of the data's content.

Jump to

Keyboard shortcuts

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