Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.setup > #4365 > unrolled thread

Pre-logon (warning) Banner

Started by"J.B. Wood" <arl_123234@hotmail.com>
First post2019-08-05 08:10 -0400
Last post2019-08-05 14:17 -0500
Articles 11 — 5 participants

Back to article view | Back to comp.os.linux.setup


Contents

  Pre-logon (warning) Banner "J.B. Wood" <arl_123234@hotmail.com> - 2019-08-05 08:10 -0400
    Re: Pre-logon (warning) Banner Robert Heller <heller@deepsoft.com> - 2019-08-05 10:35 -0500
      Re: Pre-logon (warning) Banner "J.B. Wood" <arl_123234@hotmail.com> - 2019-08-05 12:06 -0400
        Re: Pre-logon (warning) Banner Eli the Bearded <*@eli.users.panix.com> - 2019-08-05 18:36 +0000
          Re: Pre-logon (warning) Banner "David W. Hodgins" <dwhodgins@nomail.afraid.org> - 2019-08-05 16:34 -0400
            Re: Pre-logon (warning) Banner Robert Heller <heller@deepsoft.com> - 2019-08-05 15:47 -0500
              Re: Pre-logon (warning) Banner "David W. Hodgins" <dwhodgins@nomail.afraid.org> - 2019-08-05 17:36 -0400
            Re: Pre-logon (warning) Banner Eli the Bearded <*@eli.users.panix.com> - 2019-08-05 23:02 +0000
            Re: Pre-logon (warning) Banner Bit Twister <BitTwister@mouse-potato.com> - 2019-08-05 19:26 -0500
          Re: Pre-logon (warning) Banner "J.B. Wood" <arl_123234@hotmail.com> - 2019-08-06 06:39 -0400
        Re: Pre-logon (warning) Banner Robert Heller <heller@deepsoft.com> - 2019-08-05 14:17 -0500

#4365 — Pre-logon (warning) Banner

From"J.B. Wood" <arl_123234@hotmail.com>
Date2019-08-05 08:10 -0400
SubjectPre-logon (warning) Banner
Message-ID<qi96c2$1ijt$1@gioia.aioe.org>
Hello, everyone.  I've been a long-time Fedora w/Gnome desktop user. 
I'm currently using Fedora 29 and Gnome 3.30.2.  Many versions ago 
Fedora/Gnome had a "greeter" capability to display a GUI text banner 
along with the user(s) logon name/passwd prompt(s).  For console logins 
using the /etc/issue accomplishes this but then requires the user to use 
startx to launch the GUI.  (In Windows 10, the text warning banner is 
easily accomplished via a few registry entries.)

Does anyone know of a technique to accomplish a GUI Fedora warning 
banner (e.g. "Use of this computer is restricted to...")?  Thanks for 
your time and comment.  Sincerely,

-- 
J. B. Wood	            e-mail: arl_123234@hotmail.com

[toc] | [next] | [standalone]


#4366

FromRobert Heller <heller@deepsoft.com>
Date2019-08-05 10:35 -0500
Message-ID<HMOdnYMRcpUm0dXAnZ2dnUU7-InNnZ2d@giganews.com>
In reply to#4365
At Mon, 5 Aug 2019 08:10:43 -0400 "J.B. Wood" <arl_123234@hotmail.com> wrote:

> 
> Hello, everyone.  I've been a long-time Fedora w/Gnome desktop user. 
> I'm currently using Fedora 29 and Gnome 3.30.2.  Many versions ago 
> Fedora/Gnome had a "greeter" capability to display a GUI text banner 
> along with the user(s) logon name/passwd prompt(s).  For console logins 
> using the /etc/issue accomplishes this but then requires the user to use 
> startx to launch the GUI.  (In Windows 10, the text warning banner is 
> easily accomplished via a few registry entries.)
> 
> Does anyone know of a technique to accomplish a GUI Fedora warning 
> banner (e.g. "Use of this computer is restricted to...")?  Thanks for 
> your time and comment.  Sincerely,

Look at /etc/gdm3/greeter.dconf-defaults

You configure the greeter.dconf using the dconf editor.  

> 

-- 
Robert Heller             -- 978-544-6933
Deepwoods Software        -- Custom Software Services
http://www.deepsoft.com/  -- Linux Administration Services
heller@deepsoft.com       -- Webhosting Services
                                                                                                        

[toc] | [prev] | [next] | [standalone]


#4367

From"J.B. Wood" <arl_123234@hotmail.com>
Date2019-08-05 12:06 -0400
Message-ID<qi9k5k$1iaf$1@gioia.aioe.org>
In reply to#4366
On 8/5/19 11:35 AM, Robert Heller wrote:
>
> Look at /etc/gdm3/greeter.dconf-defaults
> 
> You configure the greeter.dconf using the dconf editor.
> 

Thanks for the prompt reply, Robert.  I don't see a "gdm3" directory in 
/etc, only a "gdm" directory and there is no greeter.dconf-defaults file 
there. This file does exist in /usr/share/gdm, however.  Sincerely,

-- 
J. B. Wood	            e-mail: arl_123234@hotmail.com

[toc] | [prev] | [next] | [standalone]


#4368

FromEli the Bearded <*@eli.users.panix.com>
Date2019-08-05 18:36 +0000
Message-ID<eli$1908051429@qaz.wtf>
In reply to#4367
In comp.os.linux.misc, J.B. Wood <arl_123234@hotmail.com> wrote:
> Thanks for the prompt reply, Robert.  I don't see a "gdm3" directory in 
> /etc, only a "gdm" directory and there is no greeter.dconf-defaults file 
> there. This file does exist in /usr/share/gdm, however.  Sincerely,

So you've got /etc/issue for text mode console and greeter.dconf for gui
mode console, whatcha gonna do for ssh logins?

Answer: use the Banner setting in /etc/ssh/sshd_config. It takes a
filename, and the contents of that will be shown before login.

Elijah
------
considers it a fun novelty but not really useful

[toc] | [prev] | [next] | [standalone]


#4370

From"David W. Hodgins" <dwhodgins@nomail.afraid.org>
Date2019-08-05 16:34 -0400
Message-ID<op.z52grdwba3w0dxdave@hodgins.homeip.net>
In reply to#4368
On Mon, 05 Aug 2019 14:36:34 -0400, Eli the Bearded <*@eli.users.panix.com> wrote:

> Answer: use the Banner setting in /etc/ssh/sshd_config. It takes a
> filename, and the contents of that will be shown before login.

Interesting idea, in that I could put escape codes in the file shown
that would change the foreground and/or background colours with different
ones on different systems, however it would have the problem of leaving
those colours set on exiting from the ssh session, as there is no option
to display a file on exiting.

I normally leave a konsole session open at all times. As this is the first
time I've made this mistake in at least a decade, I've decided to just get
into the habit of closing all konsole sessions, when not currently in use.
In this case, I'd closed the wrong konsole session (a localhost one, instead
of the one ssh connected), so closing both would have prevented the problem.

Regards, Dave Hodgins

-- 
Change dwhodgins@nomail.afraid.org to davidwhodgins@teksavvy.com for
email replies.

[toc] | [prev] | [next] | [standalone]


#4371

FromRobert Heller <heller@deepsoft.com>
Date2019-08-05 15:47 -0500
Message-ID<he2dnVbFVrdCCNXAnZ2dnUU7-fXNnZ2d@giganews.com>
In reply to#4370
At Mon, 05 Aug 2019 16:34:15 -0400 "David W. Hodgins" <dwhodgins@nomail.afraid.org> wrote:

> 
> On Mon, 05 Aug 2019 14:36:34 -0400, Eli the Bearded <*@eli.users.panix.com> wrote:
> 
> > Answer: use the Banner setting in /etc/ssh/sshd_config. It takes a
> > filename, and the contents of that will be shown before login.
> 
> Interesting idea, in that I could put escape codes in the file shown
> that would change the foreground and/or background colours with different
> ones on different systems, however it would have the problem of leaving
> those colours set on exiting from the ssh session, as there is no option
> to display a file on exiting.

Assumes the users are using "color" terminals, etc.  Not really a good idea 
*unless* you are sure of what hardware and software your users are using.  
Generally, this is a really *bad* idea.

> 
> I normally leave a konsole session open at all times. As this is the first
> time I've made this mistake in at least a decade, I've decided to just get
> into the habit of closing all konsole sessions, when not currently in use.
> In this case, I'd closed the wrong konsole session (a localhost one, instead
> of the one ssh connected), so closing both would have prevented the problem.
> 
> Regards, Dave Hodgins
> 

-- 
Robert Heller             -- 978-544-6933
Deepwoods Software        -- Custom Software Services
http://www.deepsoft.com/  -- Linux Administration Services
heller@deepsoft.com       -- Webhosting Services
                                

[toc] | [prev] | [next] | [standalone]


#4372

From"David W. Hodgins" <dwhodgins@nomail.afraid.org>
Date2019-08-05 17:36 -0400
Message-ID<op.z52jmvmba3w0dxdave@hodgins.homeip.net>
In reply to#4371
On Mon, 05 Aug 2019 16:47:27 -0400, Robert Heller <heller@deepsoft.com> wrote:

> Assumes the users are using "color" terminals, etc.  Not really a good idea
> *unless* you are sure of what hardware and software your users are using.
> Generally, this is a really *bad* idea.

All of the computers involved are on my local lan, and I'm the only user.
They are all running versions of Mageia linux. Some Mageia 6, some Mageia 7,
with a mix of i586 and x86_64 installs. I'm on the qa team for Mageia, so
it's handy to have them all available for testing things such as kernel
updates that have to be tested both on real hardware, and in virtualbox and
xen guests.

Regards, Dave Hodgins

-- 
Change dwhodgins@nomail.afraid.org to davidwhodgins@teksavvy.com for
email replies.

[toc] | [prev] | [next] | [standalone]


#4373

FromEli the Bearded <*@eli.users.panix.com>
Date2019-08-05 23:02 +0000
Message-ID<eli$1908051902@qaz.wtf>
In reply to#4370
In comp.os.linux.misc, David W. Hodgins <dwhodgins@nomail.afraid.org> wrote:
> On Mon, 05 Aug 2019 14:36:34 -0400, Eli the Bearded <*@eli.users.panix.com> wrote:
> > Answer: use the Banner setting in /etc/ssh/sshd_config. It takes a
> > filename, and the contents of that will be shown before login.
> Interesting idea, in that I could put escape codes in the file shown
> that would change the foreground and/or background colours with different
> ones on different systems, however it would have the problem of leaving
> those colours set on exiting from the ssh session, as there is no option
> to display a file on exiting.

Escape codes for a terminal when you don't know what the terminal is is
bad form. How hard, really, is a just a plain text message about who can
use the machine?

If you want to change colors on login / exit, consider using .login /
.logout controls; those files will be able to access terminal type. But
.logout won't run on a connection that just dies, and .profile outputing
text for non-interactive logins will break, eg, scp. The sshd Banner
method will be printed for scp (and will not break scp).

In sh like shells, you can use code like this for only setting things
during interactive sessions:

   case "$-" in *i*) # only run on interactive shells
     case "$TERM" in
       *xterm*) : xterm settings ;;
       linux) : console settings ;;
       tvi925) : TeleVideo 925 settings ;;
       *) : fallback terminal settings -- probably best none ;; 
     esac # case "$TERM"
   ;; esac


> I normally leave a konsole session open at all times. As this is the first
> time I've made this mistake in at least a decade, I've decided to just get
> into the habit of closing all konsole sessions, when not currently in use.

Not sure how konsole relates to my suggesion.

Elijah
------
"console" is being (faking) right in front of the computer as opposed to remote

[toc] | [prev] | [next] | [standalone]


#4374

FromBit Twister <BitTwister@mouse-potato.com>
Date2019-08-05 19:26 -0500
Message-ID<slrnqkhia7.7j8.BitTwister@wb.home.test>
In reply to#4370
On Mon, 05 Aug 2019 16:34:15 -0400, David W. Hodgins wrote:
> On Mon, 05 Aug 2019 14:36:34 -0400, Eli the Bearded <*@eli.users.panix.com> wrote:
>
>> Answer: use the Banner setting in /etc/ssh/sshd_config. It takes a
>> filename, and the contents of that will be shown before login.
>
> Interesting idea, in that I could put escape codes in the file shown
> that would change the foreground and/or background colours with different
> ones on different systems, however it would have the problem of leaving
> those colours set on exiting from the ssh session, as there is no option
> to display a file on exiting.

Use ~/.bash_logout to do whatever you like at that point. I test the
environment variable SSH_CLIENT to make decisions about what to do
during log in/out.

[toc] | [prev] | [next] | [standalone]


#4375

From"J.B. Wood" <arl_123234@hotmail.com>
Date2019-08-06 06:39 -0400
Message-ID<qiblc3$bvl$1@gioia.aioe.org>
In reply to#4368
On 8/5/19 2:36 PM, Eli the Bearded wrote:

> So you've got /etc/issue for text mode console and greeter.dconf for gui
> mode console, whatcha gonna do for ssh logins?
> 
> Answer: use the Banner setting in /etc/ssh/sshd_config. It takes a
> filename, and the contents of that will be shown before login.
> 
> Elijah
> ------
> considers it a fun novelty but not really useful
> 

Hello, and yes, I've been aware of that and am configured as such. 
Sincerely,

-- 
J. B. Wood	            e-mail: arl_123234@hotmail.com

[toc] | [prev] | [next] | [standalone]


#4369

FromRobert Heller <heller@deepsoft.com>
Date2019-08-05 14:17 -0500
Message-ID<Gc2dnUnswdddHdXAnZ2dnUU7-IPNnZ2d@giganews.com>
In reply to#4367
At Mon, 5 Aug 2019 12:06:13 -0400 "J.B. Wood" <arl_123234@hotmail.com> wrote:

> 
> On 8/5/19 11:35 AM, Robert Heller wrote:
> >
> > Look at /etc/gdm3/greeter.dconf-defaults
> > 
> > You configure the greeter.dconf using the dconf editor.
> > 
> 
> Thanks for the prompt reply, Robert.  I don't see a "gdm3" directory in 
> /etc, only a "gdm" directory and there is no greeter.dconf-defaults file 
> there. This file does exist in /usr/share/gdm, however.  Sincerely,

OK, Ubuntu 18.04 != Fedora 29 :-).  Different distros... But that would be the 
file to mess with.  (Actually you need to munge it into the DConf db -- there 
is babble in the man pages for that...)

> 

-- 
Robert Heller             -- 978-544-6933
Deepwoods Software        -- Custom Software Services
http://www.deepsoft.com/  -- Linux Administration Services
heller@deepsoft.com       -- Webhosting Services
                                                                          

[toc] | [prev] | [standalone]


Back to top | Article view | comp.os.linux.setup


csiph-web