core

package
v1.6.29 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: BSD-2-Clause-Patent Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// VERSION ...
	VERSION = "1" // TODO Change when necessary (change of hash algorithm, modification of string structure, etc.)
)

Variables

This section is empty.

Functions

func ExtractData

func ExtractData(crumbled string) (verificationHash string, crumbs encrypter.Crumbs, err error)

ExtractData ...

func GetCrumbs

func GetCrumbs(crumbled string) (crumbs []encrypter.Crumb, err error)

GetCrumbs returns the underlying slices of the passed crumbled string

func GetUncrumbs

func GetUncrumbs(partialUncrumb string) (uncrumbs []decrypter.Uncrumb, err error)

GetUncrumbs returns the underlying uncrumbs fromt the passed partialUncrumbs string

Types

type Crumbl

type Crumbl struct {
	Source     string
	HashEngine string
	Owners     []signer.Signer
	Trustees   []signer.Signer
}

Crumbl ...

func (*Crumbl) Process

func (c *Crumbl) Process() (string, error)

Process ...

func (*Crumbl) ToFile

func (c *Crumbl) ToFile(filename string) (string, error)

ToFile save the crumbl to file, eventually appending it to an already filled file

func (*Crumbl) ToStdOut

func (c *Crumbl) ToStdOut() (result string, err error)

ToStdOut writes the crumbl to stdout

type Uncrumbl

type Uncrumbl struct {
	Crumbled         string
	Slices           []decrypter.Uncrumb
	VerificationHash string
	Signer           signer.Signer
	IsOwner          bool
}

Uncrumbl ...

func (*Uncrumbl) Process

func (u *Uncrumbl) Process() (res []byte, err error)

Process ...

func (Uncrumbl) ToFile

func (u Uncrumbl) ToFile(filename string) (result string, err error)

ToFile ...

func (*Uncrumbl) ToStdOut

func (u *Uncrumbl) ToStdOut() (result string, err error)

ToStdOut ...

Jump to

Keyboard shortcuts

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