diff options
| author | NIIBE Yutaka <[email protected]> | 2025-10-22 01:52:52 +0000 |
|---|---|---|
| committer | NIIBE Yutaka <[email protected]> | 2025-10-22 01:52:52 +0000 |
| commit | 4a2dda2002c42fa541dacd142093c89476df606d (patch) | |
| tree | 2d16bc08c7bf4135536e5ae1fb8c33bb5fa66b94 /g10/keyring.h | |
| parent | gpg,gpgsm: No more internal-lock when KEEP_LOCK is enabled. (diff) | |
| download | gnupg-4a2dda2002c42fa541dacd142093c89476df606d.tar.gz gnupg-4a2dda2002c42fa541dacd142093c89476df606d.zip | |
kbx,gpg,gpgsm: Add FP-close method for keydb to close before unlock.
* kbx/keybox.h (keybox_fp_close): New.
* kbx/keybox-init.c (keybox_fp_close): New.
(keybox_release): Don't close FP here.
* kbx/keybox-update.c (keybox_compress_when_no_other_users): Use
keybox_fp_close.
* kbx/backend-kbx.c (be_kbx_release_kbx_hd): Follow the change.
* g10/keyring.h (keyring_fp_close): New.
* g10/keyring.c (keyring_fp_close): New.
(keyring_release): Don't close IOBUF here.
(keyring_rebuild_cache): Use keyring_fp_close.
* g10/keydb.c (do_fp_close): New.
(unlock_all): Close FP before unlocking.
* sm/keydb.c (do_fp_close): New.
(unlock_all): Close FP before unlocking.
--
GnuPG-bug-id: 7855
Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'g10/keyring.h')
| -rw-r--r-- | g10/keyring.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/g10/keyring.h b/g10/keyring.h index 7155d1d4a..b3609edf4 100644 --- a/g10/keyring.h +++ b/g10/keyring.h @@ -28,6 +28,7 @@ int keyring_register_filename (const char *fname, int read_only, void **ptr); int keyring_is_writable (void *token); KEYRING_HANDLE keyring_new (void *token); +void keyring_fp_close (KEYRING_HANDLE hd); void keyring_release (KEYRING_HANDLE hd); void keyring_push_found_state (KEYRING_HANDLE hd); void keyring_pop_found_state (KEYRING_HANDLE hd); |
