summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/signing.c
diff options
context:
space:
mode:
authorAllan McRae <allan@archlinux.org>2012-10-29 11:51:04 +0100
committerAllan McRae <allan@archlinux.org>2013-02-09 03:43:36 +0100
commit45b6d36cf7f228190dc3d20952d1e001c91bd12d (patch)
treec9cf7e69061f181aab2a002b597b798e7ba11ff9 /lib/libalpm/signing.c
parentc0835ff08e3228c748c57784869401d50421930c (diff)
downloadpacman-45b6d36cf7f228190dc3d20952d1e001c91bd12d.tar.gz
pacman-45b6d36cf7f228190dc3d20952d1e001c91bd12d.tar.xz
Make key_in_keychain available in library
In preparation for checking key presence and downloading needed keys before conflict checking. Signed-off-by: Allan McRae <allan@archlinux.org>
Diffstat (limited to 'lib/libalpm/signing.c')
-rw-r--r--lib/libalpm/signing.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/libalpm/signing.c b/lib/libalpm/signing.c
index ec9aa99b..883d62d0 100644
--- a/lib/libalpm/signing.c
+++ b/lib/libalpm/signing.c
@@ -185,7 +185,7 @@ error:
* @param fpr the fingerprint key ID to look up
* @return 1 if key is known, 0 if key is unknown, -1 on error
*/
-static int key_in_keychain(alpm_handle_t *handle, const char *fpr)
+int _alpm_key_in_keychain(alpm_handle_t *handle, const char *fpr)
{
gpgme_error_t err;
gpgme_ctx_t ctx;
@@ -633,10 +633,11 @@ error:
}
#else /* HAVE_LIBGPGME */
-static int key_in_keychain(alpm_handle_t UNUSED *handle, const char UNUSED *fpr)
+int _alpm_key_in_keychain(alpm_handle_t UNUSED *handle, const char UNUSED *fpr)
{
return -1;
}
+
int _alpm_gpgme_checksig(alpm_handle_t UNUSED *handle, const char UNUSED *path,
const char UNUSED *base64_sig, alpm_siglist_t UNUSED *siglist)
{
@@ -812,7 +813,7 @@ int _alpm_process_siglist(alpm_handle_t *handle, const char *identifier,
case ALPM_SIGSTATUS_KEY_UNKNOWN:
/* ensure this key is still actually unknown; we may have imported it
* on an earlier call to this function. */
- if(key_in_keychain(handle, result->key.fingerprint) == 1) {
+ if(_alpm_key_in_keychain(handle, result->key.fingerprint) == 1) {
break;
}
_alpm_log(handle, ALPM_LOG_ERROR,