From f893558d782396f10c2fe49a8bc73deff4a36d14 Mon Sep 17 00:00:00 2001 From: Nathan Bass Date: Sat, 14 May 2016 22:56:29 -0500 Subject: [PATCH] Minor correction to GenerateSharedSecret documentation. (#696) --- btcec/ciphering.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/btcec/ciphering.go b/btcec/ciphering.go index e4f3abeb6..11e6fbb54 100644 --- a/btcec/ciphering.go +++ b/btcec/ciphering.go @@ -41,7 +41,7 @@ var ( ) // GenerateSharedSecret generates a shared secret based on a private key and a -// private key using Diffie-Hellman key exchange (ECDH) (RFC 4753). +// public key using Diffie-Hellman key exchange (ECDH) (RFC 4753). // RFC5903 Section 9 states we should only return x. func GenerateSharedSecret(privkey *PrivateKey, pubkey *PublicKey) []byte { x, _ := pubkey.Curve.ScalarMult(pubkey.X, pubkey.Y, privkey.D.Bytes())