package ecdh
Import Path
crypto/internal/fips140/ecdh (on go.dev)
Dependency Relation
imports 10 packages, and imported by one package
Package-Level Type Names (total 4)
Type Parameters:
P: Point[P]
N []byte
func P224() *Curve[*nistec.P224Point]
func P256() *Curve[*nistec.P256Point]
func P384() *Curve[*nistec.P384Point]
func P521() *Curve[*nistec.P521Point]
func ECDH[P](c *Curve[P], k *PrivateKey, peer *PublicKey) ([]byte, error)
func GenerateKey[P](c *Curve[P], rand io.Reader) (*PrivateKey, error)
func NewPrivateKey[P](c *Curve[P], key []byte) (*PrivateKey, error)
func NewPublicKey[P](c *Curve[P], key []byte) (*PublicKey, error)
Type Parameters:
P: any
Point is a generic constraint for the [nistec] Point types.
( Point[P]) Bytes() []byte
( Point[P]) BytesX() ([]byte, error)
( Point[P]) ScalarBaseMult([]byte) (P, error)
( Point[P]) ScalarMult(P, []byte) (P, error)
( Point[P]) SetBytes([]byte) (P, error)
(*PrivateKey) Bytes() []byte
(*PrivateKey) PublicKey() *PublicKey
func GenerateKey[P](c *Curve[P], rand io.Reader) (*PrivateKey, error)
func NewPrivateKey[P](c *Curve[P], key []byte) (*PrivateKey, error)
func ECDH[P](c *Curve[P], k *PrivateKey, peer *PublicKey) ([]byte, error)
(*PublicKey) Bytes() []byte
func NewPublicKey[P](c *Curve[P], key []byte) (*PublicKey, error)
func (*PrivateKey).PublicKey() *PublicKey
func ECDH[P](c *Curve[P], k *PrivateKey, peer *PublicKey) ([]byte, error)
The pages are generated with Golds v0.7.3-preview. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds. |