Page MenuHome GnuPG

the way gpg updates the pubring files makes it impossible to symlink it
Closed, WontfixPublic

Description

i would like to share the same pubring in two gpg homes, and i symlink-ed the
files, but gpg renames the symlink as a backup and creates a new file for the
pubring db.

i know that it's not a really good idea due to potential concurrent
modifications, but in my case that's not a problem.

please consider this use-case.

and thanks for gpg!

Event Timeline

So you suggest to follow the symlink before editing the file?

well, i'm not a posix security expert, so take it with a piece of salt... but if
gpg followed symlinks on the pubring files, then it would be possible to symlink
the same public key db into two gnupg home directories.

So now, what shall we do proper file locking and make sure that the user has
permissions to both files? It will be quite some code to get this all done right.

marcus claimed this task.