Product
Introducing License Enforcement in Socket
Ensure open-source compliance with Socket’s License Enforcement Beta. Set up your License Policy and secure your software!
github.com/luke-park/ecdh25519
A simple to use implementation of ECDH with curve25519 for Go. The core mathematics of this algorithm are already present in golang.org/x/crypto/curve25519, this library just implements the algorithm in such a way that knowledge of the underlying mathematics is not necessary.
The below example does not include proper error handling.
package main
import (
"github.com/luke-park/ecdh25519"
)
func main() {
prv1, _ := ecdh25519.GenerateKey()
prv2, _ := ecdh25519.GenerateKey()
s1 := prv1.ComputeSecret(prv2.Public())
s2 := prv2.ComputeSecret(prv1.Public())
// bytes.Compare(s1, s2) == 0
}
The full documentation of this package can be found on GoDoc.
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Ensure open-source compliance with Socket’s License Enforcement Beta. Set up your License Policy and secure your software!
Product
We're launching a new set of license analysis and compliance features for analyzing, managing, and complying with licenses across a range of supported languages and ecosystems.
Product
We're excited to introduce Socket Optimize, a powerful CLI command to secure open source dependencies with tested, optimized package overrides.