X-Git-Url: https://git.distorted.org.uk/~mdw/tripe/blobdiff_plain/19220671b286fcd7e9818be2e7262094411519c5..fb6a9f13a40d1b9e797b4fe858a06cfdbcc1109b:/server/tripe.h diff --git a/server/tripe.h b/server/tripe.h index 940e3d61..d3dce08b 100644 --- a/server/tripe.h +++ b/server/tripe.h @@ -402,6 +402,7 @@ struct algswitch { struct kdata { unsigned ref; /* Reference counter */ struct knode *kn; /* Pointer to cache entry */ + uint32 id; /* The underlying key's id */ char *tag; /* Full tag name of the key */ dhgrp *grp; /* The group we work in */ dhsc *k; /* The private key (or null) */ @@ -827,6 +828,19 @@ extern int km_reload(void); extern kdata *km_findpub(const char */*tag*/); extern kdata *km_findpriv(const char */*tag*/); +/* --- @km_findpubbyid@, @km_findprivbyid@ --- * + * + * Arguments: @uint32 id@ = key id to load + * + * Returns: Pointer to the kdata object if successful, or null on error. + * + * Use: Fetches a public or private key from the keyring given its + * numeric id. + */ + +extern kdata *km_findpubbyid(uint32 /*id*/); +extern kdata *km_findprivbyid(uint32 /*id*/); + /* --- @km_samealgsp@ --- * * * Arguments: @const kdata *kdx, *kdy@ = two key data objects