mirror of git://anongit.mindrot.org/openssh.git
- stevesk@cvs.openbsd.org 2002/08/29 15:57:25
[monitor.c session.c sshlogin.c sshlogin.h] pass addrlen with sockaddr *; from Hajimu UMEMOTO <ume@FreeBSD.org> NOTE: there are also p-specific parts to this patch. ok markus@
This commit is contained in:
parent
af65304a3c
commit
ebc2306629
|
@ -38,6 +38,10 @@
|
|||
- stevesk@cvs.openbsd.org 2002/08/27 17:18:40
|
||||
[ssh_config.5]
|
||||
some warning text for ForwardAgent and ForwardX11; ok markus@
|
||||
- stevesk@cvs.openbsd.org 2002/08/29 15:57:25
|
||||
[monitor.c session.c sshlogin.c sshlogin.h]
|
||||
pass addrlen with sockaddr *; from Hajimu UMEMOTO <ume@FreeBSD.org>
|
||||
NOTE: there are also p-specific parts to this patch. ok markus@
|
||||
|
||||
20020820
|
||||
- OpenBSD CVS Sync
|
||||
|
@ -1579,4 +1583,4 @@
|
|||
- (stevesk) entropy.c: typo in debug message
|
||||
- (djm) ssh-keygen -i needs seeded RNG; report from markus@
|
||||
|
||||
$Id: ChangeLog,v 1.2437 2002/09/04 06:40:37 djm Exp $
|
||||
$Id: ChangeLog,v 1.2438 2002/09/04 06:45:09 djm Exp $
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
*/
|
||||
|
||||
#include "includes.h"
|
||||
RCSID("$OpenBSD: monitor.c,v 1.23 2002/08/02 14:43:15 millert Exp $");
|
||||
RCSID("$OpenBSD: monitor.c,v 1.24 2002/08/29 15:57:25 stevesk Exp $");
|
||||
|
||||
#include <openssl/dh.h>
|
||||
|
||||
|
@ -1002,8 +1002,8 @@ mm_record_login(Session *s, struct passwd *pw)
|
|||
* the address be 0.0.0.0.
|
||||
*/
|
||||
memset(&from, 0, sizeof(from));
|
||||
fromlen = sizeof(from);
|
||||
if (packet_connection_is_on_socket()) {
|
||||
fromlen = sizeof(from);
|
||||
if (getpeername(packet_get_connection_in(),
|
||||
(struct sockaddr *) & from, &fromlen) < 0) {
|
||||
debug("getpeername: %.100s", strerror(errno));
|
||||
|
@ -1013,7 +1013,7 @@ mm_record_login(Session *s, struct passwd *pw)
|
|||
/* Record that there was a login on that tty from the remote host. */
|
||||
record_login(s->pid, s->tty, pw->pw_name, pw->pw_uid,
|
||||
get_remote_name_or_ip(utmp_len, options.verify_reverse_mapping),
|
||||
(struct sockaddr *)&from);
|
||||
(struct sockaddr *)&from, fromlen);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
*/
|
||||
|
||||
#include "includes.h"
|
||||
RCSID("$OpenBSD: session.c,v 1.147 2002/08/22 21:45:41 markus Exp $");
|
||||
RCSID("$OpenBSD: session.c,v 1.148 2002/08/29 15:57:25 stevesk Exp $");
|
||||
|
||||
#include "ssh.h"
|
||||
#include "ssh1.h"
|
||||
|
@ -671,8 +671,8 @@ do_pre_login(Session *s)
|
|||
* the address be 0.0.0.0.
|
||||
*/
|
||||
memset(&from, 0, sizeof(from));
|
||||
fromlen = sizeof(from);
|
||||
if (packet_connection_is_on_socket()) {
|
||||
fromlen = sizeof(from);
|
||||
if (getpeername(packet_get_connection_in(),
|
||||
(struct sockaddr *) & from, &fromlen) < 0) {
|
||||
debug("getpeername: %.100s", strerror(errno));
|
||||
|
@ -737,7 +737,7 @@ do_login(Session *s, const char *command)
|
|||
record_login(pid, s->tty, pw->pw_name, pw->pw_uid,
|
||||
get_remote_name_or_ip(utmp_len,
|
||||
options.verify_reverse_mapping),
|
||||
(struct sockaddr *)&from);
|
||||
(struct sockaddr *)&from, fromlen);
|
||||
|
||||
#ifdef USE_PAM
|
||||
/*
|
||||
|
|
|
@ -39,7 +39,7 @@
|
|||
*/
|
||||
|
||||
#include "includes.h"
|
||||
RCSID("$OpenBSD: sshlogin.c,v 1.4 2002/06/23 03:30:17 deraadt Exp $");
|
||||
RCSID("$OpenBSD: sshlogin.c,v 1.5 2002/08/29 15:57:25 stevesk Exp $");
|
||||
|
||||
#include "loginrec.h"
|
||||
|
||||
|
@ -65,7 +65,7 @@ get_last_login_time(uid_t uid, const char *logname,
|
|||
*/
|
||||
void
|
||||
record_login(pid_t pid, const char *ttyname, const char *user, uid_t uid,
|
||||
const char *host, struct sockaddr * addr)
|
||||
const char *host, struct sockaddr * addr, socklen_t addrlen)
|
||||
{
|
||||
struct logininfo *li;
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $OpenBSD: sshlogin.h,v 1.3 2001/06/26 17:27:25 markus Exp $ */
|
||||
/* $OpenBSD: sshlogin.h,v 1.4 2002/08/29 15:57:25 stevesk Exp $ */
|
||||
|
||||
/*
|
||||
* Author: Tatu Ylonen <ylo@cs.hut.fi>
|
||||
|
@ -16,7 +16,7 @@
|
|||
|
||||
void
|
||||
record_login(pid_t, const char *, const char *, uid_t,
|
||||
const char *, struct sockaddr *);
|
||||
const char *, struct sockaddr *, socklen_t);
|
||||
void record_logout(pid_t, const char *, const char *);
|
||||
u_long get_last_login_time(uid_t, const char *, char *, u_int);
|
||||
|
||||
|
|
Loading…
Reference in New Issue