- itojun@cvs.openbsd.org 2001/12/05 03:50:01
[clientloop.c serverloop.c sshd.c]
deal with LP64 printf issue with sig_atomic_t. from thorpej
+ - itojun@cvs.openbsd.org 2001/12/05 03:56:39
+ [auth1.c auth2.c canohost.c channels.c deattack.c packet.c scp.c
+ sshconnect2.c]
+ make it compile with more strict prototype checking
20011126
- (tim) [contrib/cygwin/README, openbsd-compat/bsd-cygwin_util.c,
*/
#include "includes.h"
-RCSID("$OpenBSD: auth1.c,v 1.25 2001/06/26 16:15:23 dugsong Exp $");
+RCSID("$OpenBSD: auth1.c,v 1.26 2001/12/05 03:56:39 itojun Exp $");
#include "xmalloc.h"
#include "rsa.h"
* been exchanged and encryption is enabled.
*/
void
-do_authentication()
+do_authentication(void)
{
Authctxt *authctxt;
struct passwd *pw;
*/
#include "includes.h"
-RCSID("$OpenBSD: auth2.c,v 1.73 2001/11/17 19:14:34 stevesk Exp $");
+RCSID("$OpenBSD: auth2.c,v 1.74 2001/12/05 03:56:39 itojun Exp $");
#include <openssl/evp.h>
*/
void
-do_authentication2()
+do_authentication2(void)
{
Authctxt *authctxt = authctxt_new();
*/
#include "includes.h"
-RCSID("$OpenBSD: canohost.c,v 1.27 2001/06/23 15:12:17 itojun Exp $");
+RCSID("$OpenBSD: canohost.c,v 1.28 2001/12/05 03:56:39 itojun Exp $");
#include "packet.h"
#include "xmalloc.h"
*/
const char *
-get_remote_ipaddr()
+get_remote_ipaddr(void)
{
static char *canonical_host_ip = NULL;
}
int
-get_remote_port()
+get_remote_port(void)
{
return get_port(0);
}
int
-get_local_port()
+get_local_port(void)
{
return get_port(1);
}
*/
#include "includes.h"
-RCSID("$OpenBSD: channels.c,v 1.140 2001/10/10 22:18:47 markus Exp $");
+RCSID("$OpenBSD: channels.c,v 1.142 2001/12/05 03:56:39 itojun Exp $");
#include "ssh.h"
#include "ssh1.h"
*/
void
-channel_close_all()
+channel_close_all(void)
{
int i;
*/
int
-channel_not_very_much_buffered_data()
+channel_not_very_much_buffered_data(void)
{
u_int i;
Channel *c;
/* Returns true if any channel is still open. */
int
-channel_still_open()
+channel_still_open(void)
{
int i;
Channel *c;
/* Returns the id of an open channel suitable for keepaliving */
int
-channel_find_open()
+channel_find_open(void)
{
int i;
Channel *c;
*/
char *
-channel_open_message()
+channel_open_message(void)
{
Buffer buffer;
Channel *c;
/* If there is data to send to the connection, enqueue some of it now. */
void
-channel_output_poll()
+channel_output_poll(void)
{
int len, i;
Channel *c;
* anyway, and the server has no way to know but to trust the client anyway.
*/
void
-channel_permit_all_opens()
+channel_permit_all_opens(void)
{
if (num_permitted_opens == 0)
all_opens_permitted = 1;
/* Sends a message to the server to request authentication fd forwarding. */
void
-auth_request_forwarding()
+auth_request_forwarding(void)
{
packet_start(SSH_CMSG_AGENT_REQUEST_FORWARDING);
packet_send();
*/
char *
-auth_get_socket_name()
+auth_get_socket_name(void)
{
return auth_sock_name;
}
-/* $OpenBSD: deattack.c,v 1.15 2001/11/19 19:02:16 mpech Exp $ */
+/* $OpenBSD: deattack.c,v 1.16 2001/12/05 03:56:39 itojun Exp $ */
/*
* Cryptographic attack detector for ssh - source code
#include "crc32.h"
#include "getput.h"
#include "xmalloc.h"
+#include "deattack.h"
/* SSH Constants */
#define SSH_MAXBLOCKS (32 * 1024)
*/
#include "includes.h"
-RCSID("$OpenBSD: packet.c,v 1.72 2001/11/10 13:37:20 markus Exp $");
+RCSID("$OpenBSD: packet.c,v 1.73 2001/12/05 03:56:39 itojun Exp $");
#include "xmalloc.h"
#include "buffer.h"
/* Returns 1 if remote host is connected via socket, 0 if not. */
int
-packet_connection_is_on_socket()
+packet_connection_is_on_socket(void)
{
struct sockaddr_storage from, to;
socklen_t fromlen, tolen;
/* returns 1 if connection is via ipv4 */
int
-packet_connection_is_ipv4()
+packet_connection_is_ipv4(void)
{
struct sockaddr_storage to;
socklen_t tolen = sizeof(to);
/* Sets the connection into non-blocking mode. */
void
-packet_set_nonblocking()
+packet_set_nonblocking(void)
{
/* Set the socket into non-blocking mode. */
if (fcntl(connection_in, F_SETFL, O_NONBLOCK) < 0)
/* Returns the socket used for reading. */
int
-packet_get_connection_in()
+packet_get_connection_in(void)
{
return connection_in;
}
/* Returns the descriptor used for writing. */
int
-packet_get_connection_out()
+packet_get_connection_out(void)
{
return connection_out;
}
/* Closes the connection and clears and frees internal data structures. */
void
-packet_close()
+packet_close(void)
{
if (!initialized)
return;
/* Returns the remote protocol flags set earlier by the above function. */
u_int
-packet_get_protocol_flags()
+packet_get_protocol_flags(void)
{
return remote_protocol_flags;
}
}
void
-packet_send()
+packet_send(void)
{
if (compat20)
packet_send2();
/* Returns a character from the packet. */
u_int
-packet_get_char()
+packet_get_char(void)
{
char ch;
buffer_get(&incoming_packet, &ch, 1);
/* Returns an integer from the packet data. */
u_int
-packet_get_int()
+packet_get_int(void)
{
return buffer_get_int(&incoming_packet);
}
/* Checks if there is any buffered output, and tries to write some of the output. */
void
-packet_write_poll()
+packet_write_poll(void)
{
int len = buffer_len(&output);
if (len > 0) {
*/
void
-packet_write_wait()
+packet_write_wait(void)
{
fd_set *setp;
/* Returns true if there is buffered data to write to the connection. */
int
-packet_have_data_to_write()
+packet_have_data_to_write(void)
{
return buffer_len(&output) != 0;
}
/* Returns true if there is not too much data to write to the connection. */
int
-packet_not_very_much_data_to_write()
+packet_not_very_much_data_to_write(void)
{
if (interactive_mode)
return buffer_len(&output) < 16384;
/* Returns true if the current connection is interactive. */
int
-packet_is_interactive()
+packet_is_interactive(void)
{
return interactive_mode;
}
*/
#include "includes.h"
-RCSID("$OpenBSD: scp.c,v 1.85 2001/10/01 08:06:28 markus Exp $");
+RCSID("$OpenBSD: scp.c,v 1.86 2001/12/05 03:56:39 itojun Exp $");
#include "xmalloc.h"
#include "atomicio.h"
}
int
-response()
+response(void)
{
char ch, *cp, resp, rbuf[2048];
}
void
-usage()
+usage(void)
{
(void) fprintf(stderr,
"usage: scp [-pqrvBC46] [-F config] [-S ssh] [-P port] [-c cipher] [-i identity]\n"
*/
#include "includes.h"
-RCSID("$OpenBSD: sshconnect2.c,v 1.85 2001/11/07 16:03:17 markus Exp $");
+RCSID("$OpenBSD: sshconnect2.c,v 1.86 2001/12/05 03:56:39 itojun Exp $");
#include <openssl/bn.h>
#include <openssl/md5.h>
int *batch_flag; /* flag in option struct that disables method */
};
-void input_userauth_success(int type, int plen, void *ctxt);
-void input_userauth_failure(int type, int plen, void *ctxt);
-void input_userauth_banner(int type, int plen, void *ctxt);
-void input_userauth_error(int type, int plen, void *ctxt);
-void input_userauth_info_req(int type, int plen, void *ctxt);
-void input_userauth_pk_ok(int type, int plen, void *ctxt);
+void input_userauth_success(int, int, void *);
+void input_userauth_failure(int, int, void *);
+void input_userauth_banner(int, int, void *);
+void input_userauth_error(int, int, void *);
+void input_userauth_info_req(int, int, void *);
+void input_userauth_pk_ok(int, int, void *);
-int userauth_none(Authctxt *authctxt);
-int userauth_pubkey(Authctxt *authctxt);
-int userauth_passwd(Authctxt *authctxt);
-int userauth_kbdint(Authctxt *authctxt);
-int userauth_hostbased(Authctxt *authctxt);
+int userauth_none(Authctxt *);
+int userauth_pubkey(Authctxt *);
+int userauth_passwd(Authctxt *);
+int userauth_kbdint(Authctxt *);
+int userauth_hostbased(Authctxt *);
-void userauth(Authctxt *authctxt, char *authlist);
+void userauth(Authctxt *, char *);
static int sign_and_send_pubkey(Authctxt *, Key *, sign_cb_fn *);
static void clear_auth_state(Authctxt *);