Deleted Added
full compact
rshd.c (76134) rshd.c (79452)
1/*-
2 * Copyright (c) 1988, 1989, 1992, 1993, 1994
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 28 unchanged lines hidden (view full) ---

37 The Regents of the University of California. All rights reserved.\n";
38#endif /* not lint */
39
40#ifndef lint
41#if 0
42static const char sccsid[] = "@(#)rshd.c 8.2 (Berkeley) 4/6/94";
43#endif
44static const char rcsid[] =
1/*-
2 * Copyright (c) 1988, 1989, 1992, 1993, 1994
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 28 unchanged lines hidden (view full) ---

37 The Regents of the University of California. All rights reserved.\n";
38#endif /* not lint */
39
40#ifndef lint
41#if 0
42static const char sccsid[] = "@(#)rshd.c 8.2 (Berkeley) 4/6/94";
43#endif
44static const char rcsid[] =
45 "$FreeBSD: head/libexec/rshd/rshd.c 76134 2001-04-29 17:50:29Z markm $";
45 "$FreeBSD: head/libexec/rshd/rshd.c 79452 2001-07-09 09:24:06Z brian $";
46#endif /* not lint */
47
48/*
49 * remote shell server:
50 * [port]\0
51 * remuser\0
52 * locuser\0
53 * command\0

--- 648 unchanged lines hidden (view full) ---

702 }
703 login_close(lc);
704
705 endpwent();
706 if (log_success || pwd->pw_uid == 0) {
707 syslog(LOG_INFO|LOG_AUTH, "%s@%s as %s: cmd='%.80s'",
708 remuser, fromhost, locuser, cmdbuf);
709 }
46#endif /* not lint */
47
48/*
49 * remote shell server:
50 * [port]\0
51 * remuser\0
52 * locuser\0
53 * command\0

--- 648 unchanged lines hidden (view full) ---

702 }
703 login_close(lc);
704
705 endpwent();
706 if (log_success || pwd->pw_uid == 0) {
707 syslog(LOG_INFO|LOG_AUTH, "%s@%s as %s: cmd='%.80s'",
708 remuser, fromhost, locuser, cmdbuf);
709 }
710 execl(pwd->pw_shell, cp, "-c", cmdbuf, 0);
710 execl(pwd->pw_shell, cp, "-c", cmdbuf, (char *)0);
711 perror(pwd->pw_shell);
712 exit(1);
713}
714
715/*
716 * Report error to client. Note: can't be used until second socket has
717 * connected to client, or older clients will hang waiting for that
718 * connection first.

--- 126 unchanged lines hidden ---
711 perror(pwd->pw_shell);
712 exit(1);
713}
714
715/*
716 * Report error to client. Note: can't be used until second socket has
717 * connected to client, or older clients will hang waiting for that
718 * connection first.

--- 126 unchanged lines hidden ---