summaryrefslogtreecommitdiff
path: root/packet.h
diff options
context:
space:
mode:
authorBen Lindstrom <mouring@eviladmin.org>2001-07-04 04:02:36 +0000
committerBen Lindstrom <mouring@eviladmin.org>2001-07-04 04:02:36 +0000
commit16ae3d0dba5f81e5602798b915105284033dea75 (patch)
treece0c2bf0d7e961b1015d43d1a07269d81e7a9ce9 /packet.h
parent90279d80f57c79ac6566051172a94a2cca9674b1 (diff)
- itojun@cvs.openbsd.org 2001/06/26 06:32:58
[atomicio.h authfd.h authfile.h auth.h auth-options.h bufaux.h buffer.h canohost.h channels.h cipher.h clientloop.h compat.h compress.h crc32.h deattack.h dh.h dispatch.h groupaccess.h hostfile.h kex.h key.h log.h mac.h match.h misc.h mpaux.h packet.h radix.h readconf.h readpass.h rsa.h] prototype pedant. not very creative... - () -> (void) - no variable names
Diffstat (limited to 'packet.h')
-rw-r--r--packet.h25
1 files changed, 12 insertions, 13 deletions
diff --git a/packet.h b/packet.h
index 6430bb0be..97afbdf60 100644
--- a/packet.h
+++ b/packet.h
@@ -11,7 +11,7 @@
11 * called by a name other than "ssh" or "Secure Shell". 11 * called by a name other than "ssh" or "Secure Shell".
12 */ 12 */
13 13
14/* RCSID("$OpenBSD: packet.h,v 1.23 2001/05/28 23:58:35 markus Exp $"); */ 14/* RCSID("$OpenBSD: packet.h,v 1.24 2001/06/26 06:32:57 itojun Exp $"); */
15 15
16#ifndef PACKET_H 16#ifndef PACKET_H
17#define PACKET_H 17#define PACKET_H
@@ -23,7 +23,7 @@
23 * packet_set_encryption_key is called. It is permissible that fd_in and 23 * packet_set_encryption_key is called. It is permissible that fd_in and
24 * fd_out are the same descriptor; in that case it is assumed to be a socket. 24 * fd_out are the same descriptor; in that case it is assumed to be a socket.
25 */ 25 */
26void packet_set_connection(int fd_in, int fd_out); 26void packet_set_connection(int, int);
27 27
28/* Puts the connection file descriptors into non-blocking mode. */ 28/* Puts the connection file descriptors into non-blocking mode. */
29void packet_set_nonblocking(void); 29void packet_set_nonblocking(void);
@@ -46,32 +46,31 @@ void packet_close(void);
46 * encrypted independently of each other. Cipher types are defined in ssh.h. 46 * encrypted independently of each other. Cipher types are defined in ssh.h.
47 */ 47 */
48void 48void
49packet_set_encryption_key(const u_char *key, u_int keylen, 49packet_set_encryption_key(const u_char *, u_int, int);
50 int cipher_type);
51 50
52/* 51/*
53 * Sets remote side protocol flags for the current connection. This can be 52 * Sets remote side protocol flags for the current connection. This can be
54 * called at any time. 53 * called at any time.
55 */ 54 */
56void packet_set_protocol_flags(u_int flags); 55void packet_set_protocol_flags(u_int);
57 56
58/* Returns the remote protocol flags set earlier by the above function. */ 57/* Returns the remote protocol flags set earlier by the above function. */
59u_int packet_get_protocol_flags(void); 58u_int packet_get_protocol_flags(void);
60 59
61/* Enables compression in both directions starting from the next packet. */ 60/* Enables compression in both directions starting from the next packet. */
62void packet_start_compression(int level); 61void packet_start_compression(int);
63 62
64/* 63/*
65 * Informs that the current session is interactive. Sets IP flags for 64 * Informs that the current session is interactive. Sets IP flags for
66 * optimal performance in interactive use. 65 * optimal performance in interactive use.
67 */ 66 */
68void packet_set_interactive(int interactive); 67void packet_set_interactive(int);
69 68
70/* Returns true if the current connection is interactive. */ 69/* Returns true if the current connection is interactive. */
71int packet_is_interactive(void); 70int packet_is_interactive(void);
72 71
73/* Starts constructing a packet to send. */ 72/* Starts constructing a packet to send. */
74void packet_start(u_char type); 73void packet_start(u_char);
75 74
76/* Appends a character to the packet data. */ 75/* Appends a character to the packet data. */
77void packet_put_char(int ch); 76void packet_put_char(int ch);
@@ -175,14 +174,14 @@ int packet_not_very_much_data_to_write(void);
175 174
176/* maximum packet size, requested by client with SSH_CMSG_MAX_PACKET_SIZE */ 175/* maximum packet size, requested by client with SSH_CMSG_MAX_PACKET_SIZE */
177extern int max_packet_size; 176extern int max_packet_size;
178int packet_set_maxsize(int s); 177int packet_set_maxsize(int);
179#define packet_get_maxsize() max_packet_size 178#define packet_get_maxsize() max_packet_size
180 179
181/* Stores tty modes from the fd or tiop into current packet. */ 180/* Stores tty modes from the fd or tiop into current packet. */
182void tty_make_modes(int fd, struct termios *tiop); 181void tty_make_modes(int, struct termios *);
183 182
184/* Parses tty modes for the fd from the current packet. */ 183/* Parses tty modes for the fd from the current packet. */
185void tty_parse_modes(int fd, int *n_bytes_ptr); 184void tty_parse_modes(int, int *);
186 185
187#define packet_integrity_check(payload_len, expected_len, type) \ 186#define packet_integrity_check(payload_len, expected_len, type) \
188do { \ 187do { \
@@ -212,9 +211,9 @@ int packet_connection_is_ipv4(void);
212int packet_remaining(void); 211int packet_remaining(void);
213 212
214/* append an ignore message */ 213/* append an ignore message */
215void packet_send_ignore(int nbytes); 214void packet_send_ignore(int);
216 215
217/* add an ignore message and make sure size (current+ignore) = n*sumlen */ 216/* add an ignore message and make sure size (current+ignore) = n*sumlen */
218void packet_inject_ignore(int sumlen); 217void packet_inject_ignore(int);
219 218
220#endif /* PACKET_H */ 219#endif /* PACKET_H */