Skip to content

x/crypto/openpgp: encrypt private key documentation missing #16994

@acasajus

Description

@acasajus

Please answer these questions before submitting your issue. Thanks!

What version of Go are you using (go version)?

go version go1.7 darwin/amd64

What operating system and processor architecture are you using (go env)?

GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/acasajus/Devel/gospace"
GORACE=""
GOROOT="/usr/local/Cellar/go/1.7/libexec"
GOTOOLDIR="/usr/local/Cellar/go/1.7/libexec/pkg/tool/darwin_amd64"
CC="clang"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/_m/s8xbjvsx05d7g5vm9b0wlsc00000gn/T/go-build341779350=/tmp/go-build -gno-record-gcc-switches -fno-common"
CXX="clang++"
CGO_ENABLED="1"

What did you do?

Tried to encrypt a openpgp.packet.PrivateKey and dump it in a PGP armor.

What did you expect to see?

An example on how to do it. I haven't found any way to do it. I would like a pointer in how to export a private key encrypting it with a passphrase. The inverse of openpgp.packet.PrivateKey.Decrypt.

What did you see instead?

No information on how to do it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions