Replaced legacy `*.orly` module imports with `next.orly.dev/pkg` paths across the codebase for consistency. Removed legacy `go.mod` files from sub-packages, consolidating dependency management. Added Dockerfiles and configurations for benchmarking environments.
17 lines
549 B
Go
17 lines
549 B
Go
// Copyright (c) 2015-2016 The btcsuite developers
|
|
// Use of this source code is governed by an ISC
|
|
// license that can be found in the LICENSE file.
|
|
|
|
package btcec
|
|
|
|
import (
|
|
"next.orly.dev/pkg/crypto/ec/secp256k1"
|
|
)
|
|
|
|
// GenerateSharedSecret generates a shared secret based on a secret key and a
|
|
// public key using Diffie-Hellman key exchange (ECDH) (RFC 4753).
|
|
// RFC5903 Section 9 states we should only return x.
|
|
func GenerateSharedSecret(privkey *SecretKey, pubkey *PublicKey) []byte {
|
|
return secp256k1.GenerateSharedSecret(privkey, pubkey)
|
|
}
|