1263970Sdes/* $OpenBSD: compat.h,v 1.44 2013/12/30 23:52:27 djm Exp $ */
2224642Sbrooks/* $FreeBSD$ */
392559Sdes
457429Smarkm/*
592559Sdes * Copyright (c) 1999, 2000, 2001 Markus Friedl.  All rights reserved.
657429Smarkm *
757429Smarkm * Redistribution and use in source and binary forms, with or without
857429Smarkm * modification, are permitted provided that the following conditions
957429Smarkm * are met:
1057429Smarkm * 1. Redistributions of source code must retain the above copyright
1157429Smarkm *    notice, this list of conditions and the following disclaimer.
1257429Smarkm * 2. Redistributions in binary form must reproduce the above copyright
1357429Smarkm *    notice, this list of conditions and the following disclaimer in the
1457429Smarkm *    documentation and/or other materials provided with the distribution.
1557429Smarkm *
1657429Smarkm * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
1757429Smarkm * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
1857429Smarkm * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
1957429Smarkm * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
2057429Smarkm * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
2157429Smarkm * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
2257429Smarkm * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
2357429Smarkm * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
2457429Smarkm * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
2557429Smarkm * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2657429Smarkm */
2757429Smarkm
2857429Smarkm#ifndef COMPAT_H
2957429Smarkm#define COMPAT_H
3060573Skris
31137019Sdes#define	SSH_PROTO_UNKNOWN	0x00
3260573Skris#define	SSH_PROTO_1		0x01
3360573Skris#define	SSH_PROTO_1_PREFERRED	0x02
3460573Skris#define	SSH_PROTO_2		0x04
3560573Skris
3692559Sdes#define SSH_BUG_SIGBLOB		0x00000001
3792559Sdes#define SSH_BUG_PKSERVICE	0x00000002
3892559Sdes#define SSH_BUG_HMAC		0x00000004
3992559Sdes#define SSH_BUG_X11FWD		0x00000008
4092559Sdes#define SSH_OLD_SESSIONID	0x00000010
4192559Sdes#define SSH_BUG_PKAUTH		0x00000020
4292559Sdes#define SSH_BUG_DEBUG		0x00000040
4392559Sdes#define SSH_BUG_BANNER		0x00000080
4492559Sdes#define SSH_BUG_IGNOREMSG	0x00000100
4592559Sdes#define SSH_BUG_PKOK		0x00000200
4692559Sdes#define SSH_BUG_PASSWORDPAD	0x00000400
4792559Sdes#define SSH_BUG_SCANNER		0x00000800
4892559Sdes#define SSH_BUG_BIGENDIANAES	0x00001000
4992559Sdes#define SSH_BUG_RSASIGMD5	0x00002000
5092559Sdes#define SSH_OLD_DHGEX		0x00004000
5192559Sdes#define SSH_BUG_NOREKEY		0x00008000
5292559Sdes#define SSH_BUG_HBSERVICE	0x00010000
5392559Sdes#define SSH_BUG_OPENFAILURE	0x00020000
5492559Sdes#define SSH_BUG_DERIVEKEY	0x00040000
5592559Sdes#define SSH_BUG_DUMMYCHAN	0x00100000
5698684Sdes#define SSH_BUG_EXTEOF		0x00200000
57124211Sdes#define SSH_BUG_PROBE		0x00400000
58124211Sdes#define SSH_BUG_FIRSTKEX	0x00800000
59147005Sdes#define SSH_OLD_FORWARD_ADDR	0x01000000
60181111Sdes#define SSH_BUG_RFWD_ADDR	0x02000000
61192595Sdes#define SSH_NEW_OPENSSH		0x04000000
62247485Sdes#define SSH_BUG_DYNAMIC_RPORT	0x08000000
63264693Sdes#define SSH_BUG_CURVE25519PAD	0x10000000
6460573Skris
65264693Sdes#define SSH_BUG_LARGEWINDOW	0x80000000
66264693Sdes
6792559Sdesvoid     enable_compat13(void);
6892559Sdesvoid     enable_compat20(void);
6992559Sdesvoid     compat_datafellows(const char *);
7092559Sdesint	 proto_spec(const char *);
7192559Sdeschar	*compat_cipher_proposal(char *);
72263970Sdeschar	*compat_pkalg_proposal(char *);
73264693Sdeschar	*compat_kex_proposal(char *);
7492559Sdes
7557429Smarkmextern int compat13;
7660573Skrisextern int compat20;
7760573Skrisextern int datafellows;
7857429Smarkm#endif
79