frp256v1

package module
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2025 License: ISC Imports: 6 Imported by: 5

README

FRP256v1

ISC License GoDoc Go Report Card GitHub release (latest by date)

Parameters for the ANSSI FRP256v1 Elliptic curve

Agence nationale de la sécurité des systèmes d'information. "Publication d'un paramétrage de courbe elliptique visant des applications de passeport électronique et de l'administration électronique française." 21 November 2011.

License

This project is licensed under the ISC License.

Documentation

Overview

Parameters for the FRP256v1 Elliptic curve

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ECDH added in v0.0.3

func ECDH(privateKey *ecdsa.PrivateKey, publicKey *ecdsa.PublicKey) ([]byte, error)

func P256 added in v0.0.3

func P256() elliptic.Curve

Types

type PrivateKey added in v0.0.3

type PrivateKey struct {
	PublicKey PublicKey
	D         *big.Int
}

func NewPrivateKey added in v0.0.3

func NewPrivateKey(privateKey *ecdsa.PrivateKey) *PrivateKey

func ParsePrivateKey added in v0.0.3

func ParsePrivateKey(der []byte) (*PrivateKey, error)

func (*PrivateKey) MarshalPKCS8PrivateKey added in v0.0.3

func (pk *PrivateKey) MarshalPKCS8PrivateKey(curve elliptic.Curve) ([]byte, error)

func (*PrivateKey) ToECDSAPrivateKey added in v0.0.3

func (pk *PrivateKey) ToECDSAPrivateKey() *ecdsa.PrivateKey

type PublicKey added in v0.0.3

type PublicKey struct {
	X, Y  *big.Int
	Curve elliptic.Curve
}

func ParsePublicKey added in v0.0.3

func ParsePublicKey(der []byte) (*PublicKey, error)

func (*PublicKey) MarshalPKCS8PublicKey added in v0.0.3

func (pk *PublicKey) MarshalPKCS8PublicKey(curve elliptic.Curve) ([]byte, error)

func (*PublicKey) ToECDSA added in v0.0.3

func (pk *PublicKey) ToECDSA() *ecdsa.PublicKey

Jump to

Keyboard shortcuts

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