1 /*
2  *	binkleyforce -- unix FTN mailer project
3  *
4  *	Copyright (c) 1998-2000 Alexander Belkin, 2:5020/1398.11
5  *
6  *	This program is free software; you can redistribute it and/or modify
7  *	it under the terms of the GNU General Public License as published by
8  *	the Free Software Foundation; either version 2 of the License, or
9  *	(at your option) any later version.
10  *
11  *	$Id: prot_yoohoo.h,v 1.1.1.1 2004/09/09 09:52:40 kstepanenkov Exp $
12  */
13 
14 #ifndef _S_YOOHOO_H_
15 #define _S_YOOHOO_H_
16 
17 #define YOOHOO_HELLOLEN   128 /* Size of the 'HELLO' frame */
18 #define YOOHOO_MAXFIELD   40
19 
20 /*
21  * Information for/from yoohoo handshake (real packet size is 128 bytes)
22  */
23 typedef struct
24 {
25 	s_sysaddr *addrs;         /* FTN address */
26 	int       anum;
27 	int       product_code;   /* product code */
28 	int       version_maj;    /* major revision of the product */
29 	int       version_min;    /* minor revision of the product */
30 	char      system[YOOHOO_MAXFIELD+1];
31 	char      sysop[YOOHOO_MAXFIELD+1];
32 	char      passwd[YOOHOO_MAXFIELD+1];
33 	int       capabilities;
34 }
35 s_yoohoo_sysinfo;
36 
37 #define YOOHOO_DIETIFNA   0x0001  /* Can do fast "FTS-0001"  */
38 #define YOOHOO_FTB_USER   0x0002  /* Reserved by Opus-CBCS   */
39 #define YOOHOO_ZMODEM     0x0004  /* Does ZModem, 1K blocks  */
40 #define YOOHOO_ZEDZAP     0x0008  /* Can do ZModem variant   */
41 #define YOOHOO_JANUS      0x0010  /* Can do Janus            */
42 #define YOOHOO_HYDRA      0x0020  /* Can do Hydra            */
43 #define YOOHOO_Bit_6      0x0040  /* reserved by FTSC        */
44 #define YOOHOO_Bit_7      0x0080  /* reserved by FTSC        */
45 #define YOOHOO_Bit_8      0x0100  /* reserved by FTSC        */
46 #define YOOHOO_Bit_9      0x0200  /* reserved by FTSC        */
47 #define YOOHOO_Bit_a      0x0400  /* reserved by FTSC        */
48 #define YOOHOO_Bit_b      0x0800  /* reserved by FTSC        */
49 #define YOOHOO_Bit_c      0x1000  /* reserved by FTSC        */
50 #define YOOHOO_Bit_d      0x2000  /* reserved by FTSC        */
51 #define YOOHOO_DO_DOMAIN  0x4000  /* Packet contains domain  */
52 #define YOOHOO_WZ_FREQ    0x8000  /* WZ file req. ok         */
53 
54 /* prot_yoohoo.c */
55 int yoohoo_send_hello(s_yoohoo_sysinfo *local_data);
56 int yoohoo_recv_hello(s_yoohoo_sysinfo *remote_data);
57 void yoohoo_set_sysinfo(s_yoohoo_sysinfo *local_data, int hrc,
58                         e_protocol protocol);
59 void yoohoo_log_sysinfo(s_yoohoo_sysinfo *yoohoo);
60 
61 /* prot_yoohoo_api.c */
62 extern s_handshake_protocol handshake_protocol_yoohoo;
63 
64 #endif
65