Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Sep 2005 13:19:39 +0200 (CEST)
From:      Oliver Fromme <olli@lurza.secnetix.de>
To:        freebsd-chat@FreeBSD.ORG
Subject:   Re: ssh pre-login message
Message-ID:  <200509151119.j8FBJdJp030498@lurza.secnetix.de>
In-Reply-To: <20050905124654.5e8f9fce@localhost>

next in thread | previous in thread | raw e-mail | index | archive | help
Jakob Breivik Grimstveit <jakob@grimstveit.no> wrote:
 > Aaron Holmes wrote on Mon, 05 Sep 2005 03:11:
 > > I'm not entirely sure this is the proper place for this, but how can i 
 > > get a pre-login message to show up before the "login as:" prompt  on
 > > freebsd 5x
 > 
 > From `man sshd_config`:
 > 
 >      Banner  In some jurisdictions, sending a warning message before authenti-
 >              cation may be relevant for getting legal protection.  The con-
 >              tents of the specified file are sent to the remote user before
 >              authentication is allowed.  This option is only available for
 >              protocol version 2.  By default, no banner is displayed.

In case the OP had local logins in mind (syscons, not ssh),
the have a look at the gettytab(5) manpage.  It documents
two capabilities that can be added to /etc/gettytab for
local logins:  The "im" capability for short banner strings
(one line) that will be printed before the login prompt,
and the "if" capability to specify a file name.

After changing the gettytab, you need to kill the getty
processes.  They will be restarted automatically by init(8).

Best regards
   Oliver

-- 
Oliver Fromme,  secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing
Any opinions expressed in this message may be personal to the author
and may not necessarily reflect the opinions of secnetix in any way.

"Python tricks" is a tough one, cuz the language is so clean. E.g.,
C makes an art of confusing pointers with arrays and strings, which
leads to lotsa neat pointer tricks; APL mistakes everything for an
array, leading to neat one-liners; and Perl confuses everything
period, making each line a joyous adventure <wink>.
        -- Tim Peters



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200509151119.j8FBJdJp030498>