dsa

package
v0.0.0-...-fab57c2 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package dsa provides a mockable wrapper for crypto/dsa.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Impl

type Impl struct{}

func (*Impl) GenerateKey

func (*Impl) GenerateKey(priv *dsa.PrivateKey, rand io.Reader) error

func (*Impl) GenerateParameters

func (*Impl) GenerateParameters(params *dsa.Parameters, rand io.Reader, sizes dsa.ParameterSizes) error

func (*Impl) Sign

func (*Impl) Sign(rand io.Reader, priv *dsa.PrivateKey, hash []byte) (r *big.Int, s *big.Int, err error)

func (*Impl) Verify

func (*Impl) Verify(pub *dsa.PublicKey, hash []byte, r *big.Int, s *big.Int) bool

type Interface

type Interface interface {
	GenerateKey(priv *dsa.PrivateKey, rand io.Reader) error
	GenerateParameters(params *dsa.Parameters, rand io.Reader, sizes dsa.ParameterSizes) error
	Sign(rand io.Reader, priv *dsa.PrivateKey, hash []byte) (r *big.Int, s *big.Int, err error)
	Verify(pub *dsa.PublicKey, hash []byte, r *big.Int, s *big.Int) bool
}

Jump to

Keyboard shortcuts

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