* /etc/issue
@ 1995-02-20 22:01 AFSAR
1995-02-21 9:02 ` /etc/issue Michael Sternberg
1995-02-22 14:11 ` /etc/issue Todd S. Aven
0 siblings, 2 replies; 5+ messages in thread
From: AFSAR @ 1995-02-20 22:01 UTC (permalink / raw)
I have got an Alpha 2100. I was wondering if anybody knows what is the
file name for login in anoncement. I am not talking about "/etc/motd" what I
am looking for is when you log in to system you get this message that says:
OSF/1 (your host name) (#ttyp2)
Login: xyz
Password:
The file name for this kind of annoncements are found on Cray and Convex
systems in /etc/issue and I want to know what is file name in OSF1 systems.
Please let me know of this file. Thanks much.
afsar@jaguar.litc.lockheed.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /etc/issue
1995-02-20 22:01 /etc/issue AFSAR
@ 1995-02-21 9:02 ` Michael Sternberg
1995-02-22 14:11 ` /etc/issue Todd S. Aven
1 sibling, 0 replies; 5+ messages in thread
From: Michael Sternberg @ 1995-02-21 9:02 UTC (permalink / raw)
AFSAR@jaguar.litc.lockheed.com writes:
>what I
>am looking for is when you log in to system you get this message that says:
>
>OSF/1 (your host name) (#ttyp2)
[..]
>The file name for this kind of annoncements are found on Cray and Convex
>systems in /etc/issue and I want to know what is file name in OSF1 systems.
Same for Linux.
On OSF/1, at least for the console, this is an issue of getty :-)
See gettydefs(4) for the definition of the login prompt on the console.
If you log in via rsh or rlogin, you don't get a login banner at all.
(just "login:" and "Password:" - if the client is not in the .rhosts
mechanism)
If you do telnet, the login banner is an issue of the server's telnetd.
Looking closely via "strings /usr/sbin/telnetd | grep /" reveals
(among other things):
OSF/1 (%h) (%t)
/etc/gettydefs
That is, your quoted line above is hard wired in telnetd.
I haven't looked into it further. Maybe you can manipulate /etc/gettydefs
to force telnetd to give another banner. Note that telnetd does seem to
NOT call getty but instead interprete gettydefs itself.
See getty(8), login(1) etc.
Hope it helps, Michael
--
"Who disturrrbs me at this time?" << Zaphod Beeblebrox IV >>
Michael Sternberg http://www.tu-chemnitz.de/~mst Theoretical Physics III
sternberg@physik.tu-chemnitz.de LabPhone: +49(0)371 531 3148
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /etc/issue
1995-02-20 22:01 /etc/issue AFSAR
1995-02-21 9:02 ` /etc/issue Michael Sternberg
@ 1995-02-22 14:11 ` Todd S. Aven
1995-02-22 15:27 ` /etc/issue Wuxu Peng
1 sibling, 1 reply; 5+ messages in thread
From: Todd S. Aven @ 1995-02-22 14:11 UTC (permalink / raw)
> AFSAR@jaguar.litc.lockheed.com writes:
> I have got an Alpha 2100. I was wondering if anybody knows what is the
> file name for login in anoncement. I am not talking about "/etc/motd" what I
> am looking for is when you log in to system you get this message that says:
>
> OSF/1 (your host name) (#ttyp2)
>
> Login: xyz
> Password:
>
>>>>
The file is /etc/gettydefs. I have the following entry at the top:
default# # #\r\nUnauthorized access is forbidden.\r\n\r\n#default
This causes the output to look like this when I telnet to the system:
Unauthorized access is forbidden.
login:
Regards,
Todd Aven
avents@btco.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /etc/issue
1995-02-22 14:11 ` /etc/issue Todd S. Aven
@ 1995-02-22 15:27 ` Wuxu Peng
0 siblings, 0 replies; 5+ messages in thread
From: Wuxu Peng @ 1995-02-22 15:27 UTC (permalink / raw)
Todd S. Aven (avents@btco.com) wrote:
: > AFSAR@jaguar.litc.lockheed.com writes:
: > I have got an Alpha 2100. I was wondering if anybody knows what is the
: > file name for login in anoncement. I am not talking about "/etc/motd" what I
: > am looking for is when you log in to system you get this message that says:
: >
: > OSF/1 (your host name) (#ttyp2)
: >
: > Login: xyz
: > Password:
: >
: >>>>
: The file is /etc/gettydefs. I have the following entry at the top:
: default# # #\r\nUnauthorized access is forbidden.\r\n\r\n#default
: This causes the output to look like this when I telnet to the system:
: Unauthorized access is forbidden.
: login:
Or you can use the wrapper, which is more flexible without
messing up /etc/gettydefs file. I am not sure the exact
location of the most recent wrapper, but it should be easy
to find by asking archie.
--
--wuxu peng (peng@pirates.cs.swt.edu)
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: /etc/issue
@ 1995-03-05 16:47 Matthew Harrell
0 siblings, 0 replies; 5+ messages in thread
From: Matthew Harrell @ 1995-03-05 16:47 UTC (permalink / raw)
: On OSF/1, at least for the console, this is an issue of getty :-)
: See gettydefs(4) for the definition of the login prompt on the console.
: If you log in via rsh or rlogin, you don't get a login banner at all.
: (just "login:" and "Password:" - if the client is not in the .rhosts
: mechanism)
: That is, your quoted line above is hard wired in telnetd.
: I haven't looked into it further. Maybe you can manipulate /etc/gettydefs
: to force telnetd to give another banner. Note that telnetd does seem to
: NOT call getty but instead interprete gettydefs itself.
: See getty(8), login(1) etc.
If you want to display a file during a telnet login, the following file
can help:
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#define ISSUE "/etc/issue"
#ifdef __linux__
# define TELNETD "/usr/sbin/in.telnetd"
#elif defined (OSF1)
# define TELNETD "/usr/sbin/in.telnetd"
#endif
void main ( int argc, char **argv )
{
FILE *Input; /* Issue file */
char Buff; /* Character buffer */
if ( (FILE *) NULL == ( Input = fopen ( ISSUE, "r" ) ) ) {
fprintf ( stderr, "%s: Unable to open %s\n", argv [0], ISSUE );
exit ( 1 );
}
while ( fread ( &Buff, sizeof ( char ), 1, Input ) ) {
if ( Buff != 0x0a )
putchar ( Buff );
else {
putchar ( Buff );
putchar ( 0x0d );
}
}
fclose ( Input );
if ( !fork () )
execv ( TELNETD, argv );
exit ( 0 );
}
Just change the definition of ISSUE to whatever you want to display,
compile, and change /etc/inetd.conf to reflect the new program to
use. For example, I typically stick this program in /usr/sbin/tcpd-telnet
and then change the telnet line in /etc/inetd.conf to
telnet stream tcp nowait root /usr/sbin/tcpd-telnet telnetd
This way, tcpd-telnet gets run first, outputs the issue message, then execs
telnetd.
--
/-------------------\ Phonenet address:
/ Matthew Harrell \ 202.767.4085
/ Naval Research Lab \
/ Code 7640 \ Internet address:
\ Washington, DC ___==== / harrell@uap.nrl.navy.mil
|--------------------\
|====================/ Friends don't let friends do DOS.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~1995-03-05 16:47 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1995-03-05 16:47 /etc/issue Matthew Harrell
-- strict thread matches above, loose matches on Subject: below --
1995-02-20 22:01 /etc/issue AFSAR
1995-02-21 9:02 ` /etc/issue Michael Sternberg
1995-02-22 14:11 ` /etc/issue Todd S. Aven
1995-02-22 15:27 ` /etc/issue Wuxu Peng
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox