mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-10 01:48:00 +00:00
Pageant: move extension list out into header file.
That's a part of the protocol spec (ish), so it should be somewhere reasonably sensible rather than buried in the middle of a source file.
This commit is contained in:
parent
78e006b60b
commit
3687df73a8
@ -609,15 +609,6 @@ static bool reencrypt_key(PageantKey *pk)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
#define PUTTYEXT(base) base "@putty.projects.tartarus.org"
|
|
||||||
|
|
||||||
#define KNOWN_EXTENSIONS(X) \
|
|
||||||
X(EXT_QUERY, "query") \
|
|
||||||
X(EXT_ADD_PPK, PUTTYEXT("add-ppk")) \
|
|
||||||
X(EXT_REENCRYPT, PUTTYEXT("reencrypt")) \
|
|
||||||
X(EXT_REENCRYPT_ALL, PUTTYEXT("reencrypt-all")) \
|
|
||||||
/* end of list */
|
|
||||||
|
|
||||||
#define DECL_EXT_ENUM(id, name) id,
|
#define DECL_EXT_ENUM(id, name) id,
|
||||||
enum Extension { KNOWN_EXTENSIONS(DECL_EXT_ENUM) EXT_UNKNOWN };
|
enum Extension { KNOWN_EXTENSIONS(DECL_EXT_ENUM) EXT_UNKNOWN };
|
||||||
#define DEF_EXT_NAMES(id, name) PTRLEN_DECL_LITERAL(name),
|
#define DEF_EXT_NAMES(id, name) PTRLEN_DECL_LITERAL(name),
|
||||||
|
12
pageant.h
12
pageant.h
@ -242,3 +242,15 @@ int pageant_reencrypt_key(struct pageant_pubkey *key, char **retstr);
|
|||||||
int pageant_reencrypt_all_keys(char **retstr);
|
int pageant_reencrypt_all_keys(char **retstr);
|
||||||
int pageant_sign(struct pageant_pubkey *key, ptrlen message, strbuf *out,
|
int pageant_sign(struct pageant_pubkey *key, ptrlen message, strbuf *out,
|
||||||
uint32_t flags, char **retstr);
|
uint32_t flags, char **retstr);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Definitions for agent protocol extensions.
|
||||||
|
*/
|
||||||
|
#define PUTTYEXT(base) base "@putty.projects.tartarus.org"
|
||||||
|
|
||||||
|
#define KNOWN_EXTENSIONS(X) \
|
||||||
|
X(EXT_QUERY, "query") \
|
||||||
|
X(EXT_ADD_PPK, PUTTYEXT("add-ppk")) \
|
||||||
|
X(EXT_REENCRYPT, PUTTYEXT("reencrypt")) \
|
||||||
|
X(EXT_REENCRYPT_ALL, PUTTYEXT("reencrypt-all")) \
|
||||||
|
/* end of list */
|
||||||
|
Loading…
Reference in New Issue
Block a user