I'm using crypto package to signing the data using below code. The DSA in the package is ed25519 . In this code I want to using a static private key which is generated by other service(node js) into sign function which mention in the code.I have tried it but showing me the error
cannot convert "3ef8cc42c5c5ed0f7a11ef2045da509ed175074223c6ee1a6acc71c15b2a8a8a" (untyped string constant) to [64]byte
CODE
package main
import (
"log"
crypto "golang.org/x/crypto/nacl/sign"
)
func main() {
signedData := crypto.Sign(nil, []byte("hello"), *[64]byte("3ef8cc42c5c5ed0f7a11ef2045da509ed175074223c6ee1a6acc71c15b2a8a8a"))
log.Println(string(signedData))
log.Println(signedData)
}
Can anyone help me in this? library link