diff options
author | Damien Miller <djm@mindrot.org> | 2000-04-16 11:18:38 +1000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2000-04-16 11:18:38 +1000 |
commit | 4af51306d9a51459a5bef922df1037f876ae51fe (patch) | |
tree | 09ecfc215fce82345a3259f8a0f384b9a67906f0 /login.c | |
parent | 5d1705ecf9bd3216dc99a84242bcdf2e7297d307 (diff) |
- OpenBSD CVS updates.
[ssh.1 ssh.c]
- ssh -2
[auth.c channels.c clientloop.c packet.c packet.h serverloop.c]
[session.c sshconnect.c]
- check payload for (illegal) extra data
[ALL]
- whitespace cleanup
Diffstat (limited to 'login.c')
-rw-r--r-- | login.c | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -1,24 +1,24 @@ | |||
1 | /* | 1 | /* |
2 | * | 2 | * |
3 | * login.c | 3 | * login.c |
4 | * | 4 | * |
5 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 5 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
6 | * | 6 | * |
7 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 7 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
8 | * All rights reserved | 8 | * All rights reserved |
9 | * | 9 | * |
10 | * Created: Fri Mar 24 14:51:08 1995 ylo | 10 | * Created: Fri Mar 24 14:51:08 1995 ylo |
11 | * | 11 | * |
12 | * This file performs some of the things login(1) normally does. We cannot | 12 | * This file performs some of the things login(1) normally does. We cannot |
13 | * easily use something like login -p -h host -f user, because there are | 13 | * easily use something like login -p -h host -f user, because there are |
14 | * several different logins around, and it is hard to determined what kind of | 14 | * several different logins around, and it is hard to determined what kind of |
15 | * login the current system has. Also, we want to be able to execute commands | 15 | * login the current system has. Also, we want to be able to execute commands |
16 | * on a tty. | 16 | * on a tty. |
17 | * | 17 | * |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include "includes.h" | 20 | #include "includes.h" |
21 | RCSID("$Id: login.c,v 1.22 2000/02/02 08:17:41 damien Exp $"); | 21 | RCSID("$Id: login.c,v 1.23 2000/04/16 01:18:43 damien Exp $"); |
22 | 22 | ||
23 | #if defined(HAVE_UTMPX_H) && defined(USE_UTMPX) | 23 | #if defined(HAVE_UTMPX_H) && defined(USE_UTMPX) |
24 | # include <utmpx.h> | 24 | # include <utmpx.h> |
@@ -49,7 +49,7 @@ RCSID("$Id: login.c,v 1.22 2000/02/02 08:17:41 damien Exp $"); | |||
49 | * is found). The name of the host used last time is returned in buf. | 49 | * is found). The name of the host used last time is returned in buf. |
50 | */ | 50 | */ |
51 | 51 | ||
52 | unsigned long | 52 | unsigned long |
53 | get_last_login_time(uid_t uid, const char *logname, | 53 | get_last_login_time(uid_t uid, const char *logname, |
54 | char *buf, unsigned int bufsize) | 54 | char *buf, unsigned int bufsize) |
55 | { | 55 | { |
@@ -135,7 +135,7 @@ get_last_login_time(uid_t uid, const char *logname, | |||
135 | * were more standardized. | 135 | * were more standardized. |
136 | */ | 136 | */ |
137 | 137 | ||
138 | void | 138 | void |
139 | record_login(int pid, const char *ttyname, const char *user, uid_t uid, | 139 | record_login(int pid, const char *ttyname, const char *user, uid_t uid, |
140 | const char *host, struct sockaddr * addr) | 140 | const char *host, struct sockaddr * addr) |
141 | { | 141 | { |
@@ -273,7 +273,7 @@ record_login(int pid, const char *ttyname, const char *user, uid_t uid, | |||
273 | 273 | ||
274 | /* Records that the user has logged out. */ | 274 | /* Records that the user has logged out. */ |
275 | 275 | ||
276 | void | 276 | void |
277 | record_logout(int pid, const char *ttyname) | 277 | record_logout(int pid, const char *ttyname) |
278 | { | 278 | { |
279 | #ifdef HAVE_LIBUTIL_LOGIN | 279 | #ifdef HAVE_LIBUTIL_LOGIN |