pass-coffin icon indicating copy to clipboard operation
pass-coffin copied to clipboard

unable to find the signature for the coffin

Open vikasrawal opened this issue 2 years ago • 7 comments
trafficstars

Why am I getting this error as I do pass open: unable to find the signature for the coffin

vikasrawal avatar Jun 02 '23 12:06 vikasrawal

Can you share the output of this command?

env | grep 'PASSWORD_STORE_SIGNING_KEY'

ayushnix avatar Jun 02 '23 13:06 ayushnix

I have this in my cron: @reboot pass close

The idea is that the password store should be closed whenever machine is rebooted.

This seems to cause it. I do not have a problem when I manually do pass close and pass open from the terminal. But I have a problem when I reboot. The password store is closed, and cannot be opened.

I guess passing the environment variables should fix it. Something like this:

@reboot bash -l -c "pass close"

vikasrawal avatar Jun 02 '23 13:06 vikasrawal

@reboot PASSWORD_STORE_SIGNING_KEY=mykeyid pass close or any other way of specifying the environment variables in the cron does not work.

vikasrawal avatar Jun 02 '23 14:06 vikasrawal

If you're trying to sign and close a password store without any user interaction, your passphrase should be cached in your gpg-agent. If this isn't the case, the signing operation will fail. This is a known issue.

ayushnix avatar Jun 02 '23 14:06 ayushnix

That is right. What is the recommended strategy to close the password store on shutdown/reboot?

vikasrawal avatar Jun 03 '23 10:06 vikasrawal

If you want to close the password store on shutdown/reboot without any user interaction, you'll want to cache your GPG passphrase for an entire session. After that, you can use a systemd service to be executed before shutdown/reboot or the cron method you described to close the password store.

ayushnix avatar Jun 03 '23 12:06 ayushnix

I think the cron method will not work as gpg passphrase is not cached @reboot. One has to create a systemd service that runs before shutdown.

vikasrawal avatar Jun 03 '23 12:06 vikasrawal