mirror of
https://github.com/fluencelabs/js-libp2p-crypto
synced 2025-08-01 04:22:07 +00:00
big-endian
This commit is contained in:
@@ -26,7 +26,7 @@ module.exports = (curveName) => {
|
||||
const genSharedKey = (theirPub, forcePrivate) => {
|
||||
const pub = ec.keyFromPublic(theirPub, 'hex')
|
||||
const p = forcePrivate || priv
|
||||
return p.derive(pub.getPublic()).toBuffer('le')
|
||||
return p.derive(pub.getPublic()).toBuffer('be')
|
||||
}
|
||||
|
||||
return {
|
||||
|
Reference in New Issue
Block a user