summaryrefslogtreecommitdiffstats
path: root/kbx/keybox-search-desc.h
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2009-12-08 17:30:33 +0100
committerWerner Koch <wk@gnupg.org>2009-12-08 17:30:33 +0100
commit9a96043be4bed4e18320918e042b1601c9d93e95 (patch)
tree0066f7268d25aa95d59cf5fbb7570e487b809c52 /kbx/keybox-search-desc.h
parentSupport CERT records via ADNS (diff)
downloadgnupg2-9a96043be4bed4e18320918e042b1601c9d93e95.tar.xz
gnupg2-9a96043be4bed4e18320918e042b1601c9d93e95.zip
Unification of the search descriptor usage.
Diffstat (limited to 'kbx/keybox-search-desc.h')
-rw-r--r--kbx/keybox-search-desc.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/kbx/keybox-search-desc.h b/kbx/keybox-search-desc.h
index 98d813507..e5da155f8 100644
--- a/kbx/keybox-search-desc.h
+++ b/kbx/keybox-search-desc.h
@@ -48,24 +48,31 @@ typedef enum {
KEYDB_SEARCH_MODE_NEXT
} KeydbSearchMode;
-struct keydb_search_desc {
+
+/* Forwward declaration. See g10/packet.h. */
+struct gpg_pkt_user_id_s;
+typedef struct gpg_pkt_user_id_s *gpg_pkt_user_id_t;
+
+/* A search descriptor. */
+struct keydb_search_desc
+{
KeydbSearchMode mode;
- int (*skipfnc)(void *,void*); /* used to be: void*, u32* */
+ int (*skipfnc)(void *, u32 *, gpg_pkt_user_id_t);
void *skipfncvalue;
const unsigned char *sn;
int snlen; /* -1 := sn is a hex string */
union {
const char *name;
unsigned char fpr[24];
- unsigned char kid[8];
+ u32 kid[2]; /* Note that this is in native endianess. */
unsigned char grip[20];
} u;
+ int exact; /* Use exactly this key ('!' suffix in gpg). */
};
struct keydb_search_desc;
typedef struct keydb_search_desc KEYDB_SEARCH_DESC;
-
typedef struct keydb_search_desc KEYBOX_SEARCH_DESC;