gpg: symmetric encryption of ‘[stdin]’ failed: Operation cancelled

--

Trying this command:

tar -cvzf - "/Volumes/myfolder" | gpg -c --passphrase super-secret > backup.tar.gz.gpg

Was getting this error:

gpg: problem with the agent: Inappropriate ioctl for device
gpg: error creating passphrase: Operation cancelled
gpg: symmetric encryption of '[stdin]' failed: Operation cancelled

Running this, then trying again, fixed it:

GPG_TTY=$(tty)
export GPG_TTY

Source

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Martin Roldan Araujo
Martin Roldan Araujo

Written by Martin Roldan Araujo

I write code 🤖 👾 🍳 🇲🇽 🏍

No responses yet

Write a response