6 * Copyright (c) 1983, 1989 Regents of the University of California.
9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions
12 * 1. Redistributions of source code must retain the above copyright
13 * notice, this list of conditions and the following disclaimer.
14 * 2. Redistributions in binary form must reproduce the above copyright
15 * notice, this list of conditions and the following disclaimer in the
16 * documentation and/or other materials provided with the distribution.
17 * 3. All advertising materials mentioning features or use of this software
18 * must display the following acknowledgement:
19 * This product includes software developed by the University of
20 * California, Berkeley and its contributors.
21 * 4. Neither the name of the University nor the names of its contributors
22 * may be used to endorse or promote products derived from this software
23 * without specific prior written permission.
25 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
26 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
27 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
28 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
29 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
30 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
31 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
32 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
33 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
34 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
37 * @(#)ftp.h 8.1 (Berkeley) 6/2/93
43 /* Definitions for FTP; see RFC-765. */
48 #define PRELIM 1 /* positive preliminary */
49 #define COMPLETE 2 /* positive completion */
50 #define CONTINUE 3 /* positive intermediate */
51 #define TRANSIENT 4 /* transient negative completion */
52 #undef ERROR /* <wingdi.h> */
53 #define ERROR 5 /* permanent negative completion */
58 #define TYPE_A 1 /* ASCII */
59 #define TYPE_E 2 /* EBCDIC */
60 #define TYPE_I 3 /* image */
61 #define TYPE_L 4 /* local byte size */
64 const char *typenames[] = {"0", "ASCII", "EBCDIC", "Image", "Local" };
70 #define FORM_N 1 /* non-print */
71 #define FORM_T 2 /* telnet format effectors */
72 #define FORM_C 3 /* carriage control (ASA) */
74 const char *formnames[] = {"0", "Nonprint", "Telnet", "Carriage-control" };
80 #define STRU_F 1 /* file (no record structure) */
81 #define STRU_R 2 /* record structure */
82 #define STRU_P 3 /* page structure */
84 const char *strunames[] = {"0", "File", "Record", "Page" };
90 #define MODE_S 1 /* stream */
91 #define MODE_B 2 /* block */
92 #define MODE_C 3 /* compressed */
94 const char *modenames[] = {"0", "Stream", "Block", "Compressed" };
100 #define PROT_C 1 /* clear */
101 #define PROT_S 2 /* safe */
102 #define PROT_P 3 /* private */
103 #define PROT_E 4 /* confidential */
106 const char *levelnames[] = {"0", "Clear", "Safe", "Private", "Confidential" };
109 #if defined(KERBEROS) && defined(NOENCRYPTION)
110 /* Define away krb_rd_priv and krb_mk_priv. Don't need them anyway.
111 * This might not be the best place for this ...
113 #define krb_rd_priv(o,l,ses,s,h,c,m) krb_rd_safe(o,l,s,h,c,m)
114 #define krb_mk_priv(i,o,l,ses,s,h,c) krb_mk_safe(i,o,l,s,h,c)
120 #define REC_ESC '\377' /* Record-mode Escape */
121 #define REC_EOR '\001' /* Record-mode End-of-Record */
122 #define REC_EOF '\002' /* Record-mode End-of-File */
127 #define BLK_EOR 0x80 /* Block is End-of-Record */
128 #define BLK_EOF 0x40 /* Block is End-of-File */
129 #define BLK_ERRORS 0x20 /* Block is suspected of containing errors */
130 #define BLK_RESTART 0x10 /* Block is Restart Marker */
132 #define BLK_BYTECOUNT 2 /* Bytes in this block */