mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-09 17:38:00 +00:00
Move bug flag definitions out into ssh.h.
With a new shiny list-macro system that will allocate power-of-2 values for them without me having to manually keep the numbers straight.
This commit is contained in:
parent
ce0b672e78
commit
370ff150ab
17
ssh.c
17
ssh.c
@ -47,23 +47,6 @@ static const char *const ssh2_disconnect_reasons[] = {
|
||||
"illegal user name",
|
||||
};
|
||||
|
||||
/*
|
||||
* Various remote-bug flags.
|
||||
*/
|
||||
#define BUG_CHOKES_ON_SSH1_IGNORE 1
|
||||
#define BUG_SSH2_HMAC 2
|
||||
#define BUG_NEEDS_SSH1_PLAIN_PASSWORD 4
|
||||
#define BUG_CHOKES_ON_RSA 8
|
||||
#define BUG_SSH2_RSA_PADDING 16
|
||||
#define BUG_SSH2_DERIVEKEY 32
|
||||
#define BUG_SSH2_REKEY 64
|
||||
#define BUG_SSH2_PK_SESSIONID 128
|
||||
#define BUG_SSH2_MAXPKT 256
|
||||
#define BUG_CHOKES_ON_SSH2_IGNORE 512
|
||||
#define BUG_CHOKES_ON_WINADJ 1024
|
||||
#define BUG_SENDS_LATE_REQUEST_REPLY 2048
|
||||
#define BUG_SSH2_OLDGEX 4096
|
||||
|
||||
#define DH_MIN_SIZE 1024
|
||||
#define DH_MAX_SIZE 8192
|
||||
|
||||
|
26
ssh.h
26
ssh.h
@ -1266,3 +1266,29 @@ const char *ssh2_pkt_type(Pkt_KCtx pkt_kctx, Pkt_ACtx pkt_actx, int type);
|
||||
* format.
|
||||
*/
|
||||
void old_keyfile_warning(void);
|
||||
|
||||
/*
|
||||
* Flags indicating implementation bugs that we know how to mitigate
|
||||
* if we think the other end has them.
|
||||
*/
|
||||
#define SSH_IMPL_BUG_LIST(X) \
|
||||
X(BUG_CHOKES_ON_SSH1_IGNORE) \
|
||||
X(BUG_SSH2_HMAC) \
|
||||
X(BUG_NEEDS_SSH1_PLAIN_PASSWORD) \
|
||||
X(BUG_CHOKES_ON_RSA) \
|
||||
X(BUG_SSH2_RSA_PADDING) \
|
||||
X(BUG_SSH2_DERIVEKEY) \
|
||||
X(BUG_SSH2_REKEY) \
|
||||
X(BUG_SSH2_PK_SESSIONID) \
|
||||
X(BUG_SSH2_MAXPKT) \
|
||||
X(BUG_CHOKES_ON_SSH2_IGNORE) \
|
||||
X(BUG_CHOKES_ON_WINADJ) \
|
||||
X(BUG_SENDS_LATE_REQUEST_REPLY) \
|
||||
X(BUG_SSH2_OLDGEX) \
|
||||
/* end of list */
|
||||
#define TMP_DECLARE_LOG2_ENUM(thing) log2_##thing,
|
||||
enum { SSH_IMPL_BUG_LIST(TMP_DECLARE_LOG2_ENUM) };
|
||||
#undef TMP_DECLARE_LOG2_ENUM
|
||||
#define TMP_DECLARE_REAL_ENUM(thing) thing = 1 << log2_##thing,
|
||||
enum { SSH_IMPL_BUG_LIST(TMP_DECLARE_REAL_ENUM) };
|
||||
#undef TMP_DECLARE_REAL_ENUM
|
||||
|
Loading…
Reference in New Issue
Block a user