Koozali.org: home of the SME Server

SSH Welcome Banner

Jim Danvers

SSH Welcome Banner
« on: October 06, 2003, 07:23:05 PM »
Anyone (this is not a big deal - just cosmetic I suppose...  ;) ) know how/if I can change the welcome banner when I log onto my 5.6 box?  See screen capture below:

login as: root
Sent username "root"
root@bikeguy.myip.org's password:
Last login: Mon Oct  6 09:59:25 2003 from rrcs-nys-12-345-678-901.biz.rr.com
Welcome to the Mitel Networks SME Server.
[root@compzilla root]#


I'd like to simply change the 'Welcome to the Mitel Networks SME Server'.  I had a look in /etc/ssh at two files - sshd_config and ssh_config.  Didn't see anything that looked promising.. (could have overlooked it though...)  There are other files in that directory that I can look at - just thought I'd throw this out anyway...

No biggie.... I'll keep looking.  I know that if/whatever file needs to be changed ~won't~ be there (/etc/ssh).  It'll likely be one of the templates that e-smith uses to build stuff at startup, yes?

TIA...

-=- jd -=-

Dan Brown

Re: SSH Welcome Banner
« Reply #1 on: October 06, 2003, 07:27:07 PM »
/etc/motd

Jim Danvers

Re: SSH Welcome Banner
« Reply #2 on: October 06, 2003, 07:29:36 PM »
... btw, I ~did~ search these forums a bit before posting the question!  ;)  I just went google'ing and came up with this ---->  (may wrap)  http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&oe=UTF-8&threadm=016601c17ba1%242c0264b0%240a00000a_atkielski.com%40ns.sol.net&rnum=1&prev=/groups%3Fhl%3Den%26lr%3D%26ie%3DUTF-8%26oe%3DUTF-8%26q%3Dssh%2Blogin%2Bbanner%26sa%3DN%26tab%3Dwg

I'll keep looking, and in the meantime - hopefully some of you will come back with some bits 'o wisdom.   ;)

-=- jd -=-

Jim Danvers

Re: SSH Welcome Banner
« Reply #3 on: October 06, 2003, 07:31:03 PM »
Dan...

You are quick on the trigger, aren't you?  ;)  Found that too (I believe in the same thread that I just posted).

Thanks...

-=- jd -=-

Jeff Peters

Re: SSH Welcome Banner
« Reply #4 on: October 08, 2003, 04:15:53 AM »
Edit the /etc/motd  file (motd = message of the day)

Use vi, pico or mc to edit that file.

Jim Danvers

Re: SSH Welcome Banner
« Reply #5 on: October 08, 2003, 05:07:06 AM »
Yup...

Got it guys - and have been having some fun with it too (I found this really great little ascii art web page that has all sorts of fun stuff on it...  ;) )

(( ... sometimes I'm easily humored....  ))  lol!!

-=- jd -=-

Guck Puppy

Re: SSH Welcome Banner
« Reply #6 on: October 08, 2003, 07:01:07 AM »
Others are easily amused too - why not post it? ;)

G

Jim Danvers

Re: SSH Welcome Banner
« Reply #7 on: October 08, 2003, 07:41:23 AM »
lol!!  I kinda knew that this might be coming and I did (really) sorta mean to post it, but forgot in my haste in replying earlier (not to mention the fact that I forgot where the link was.... )

Anyway...  tada... http://www.chris.com

I don't know who this guy is, but he has some real good stuff there.  ;)

Tip before using / doing:

I discovered a great little text editor called 'metapad'  (http://www.liquidninja.com/metapad/) that is a kind of replacement for notepad on win machines.  It has the ability to save in unix format.  Use it, or some other editor of your choice when grabbing the pictures from chris.com and save them in unix format before writing them to your motd file.  I really cheat on it - I just highlight the drawing that I'd like to use, r click & choose copy, then paste it into the text editor.  Make any changes/mods to as req'd, then hit save (in unix format).  Highlight all and r click again to copy, then using putty for shell to sme box - open motd w/vi (pico might work too) r click in putty window - pastes it in.  ;)

Save file.  Log out, log back in to test.  ;)

Have fun....  ;)

-=- jd -=-

Robert Harlow

Re: SSH Welcome Banner
« Reply #8 on: October 08, 2003, 04:16:41 PM »
Jim

What package are you using to upload your text to the forum?

Mozilla 1.5rc2 seems to think it must show the whole thread in a really wide window and is therefore not wrapping your text, or the Mitel banner line stuff, until the edge of that *wide* window. Changing the size of the active panel onscreen doesn't cause a rubber-banding effect and subsequent re-rendering to the new panel size.

Whereas IE5.5 has it onscreen just fine.

Just wondering if it's what/how you're sending it or just a Mozzy quirk that I might try and amend.

best wishes, Robert

Jim Danvers

Re: SSH Welcome Banner
« Reply #9 on: October 08, 2003, 04:52:50 PM »
Bob...

Yeah... ain't t that a drag??  I noticed that also - kinda annoying, and yes - I'm using mozilla 1.4 here.  I'm thinking same as you - perhaps something strange about the way that mozilla posted that long url...  ( I just copied & pasted it in, and that the way that it went in... yikes! )  I have seen similar looking posts here in these threads - but not very often - guessing that those guys maybe using same...??

Apologies to all ...  if anyone happens to know how to prevent it, it sure would be nice to know.  ;)

-=- jd -=-

matt

Re: SSH Welcome Banner
« Reply #10 on: October 08, 2003, 05:03:00 PM »
I’ve been following this one and finally gotten a couple minutes to respond. While some of the previous responses WILL work, if you want to modify the SSH BANNER (which will do some interesting things with different clients, like ssh.com's Windoze client) look at the following

You’ll have to add a line in your /etc/ssh/sshd_config file that says "Banner" and where that actual banner file is. From my config file it looks like this;

Banner /etc/ssh/banner_message

the actual banner message can be anything, I have a rather crass message about not logging into this machine unless you know you have an account, my buddies message is rather bawdy!

I think you will find this works nicely in conjunction with /etc/motd type edits also. Just be sure to modify the templates and restart the sshd daemon after you do.

Robert Harlow

Re: SSH Welcome Banner
« Reply #11 on: October 08, 2003, 05:19:48 PM »
>if anyone happens to know how to prevent it,
>it sure would be nice to know.

Jim

Sheer guess...  a possibility. Looking at the likely culprit, that long URL, I notice that it's in passive text rather than as a live URL. Maybe encoding with enclosing chevrons, which the forum code then activates when rendering the message, would do the trick. This forum looks like it uses Phorum Open Source code...
http://phorum.org
...and I don't remember a similar issue coming up when I used to run some local forums. The administrator hasn't enabled the user-edit option so you can't now re-edit your post but the administrator could... And any one posting in a thread has an overall effect on the whole of the thread's rendering because of the FlatView functionality. So try *activating* a really long link (before posting) next time and maybe that'll do it.

best wishes, Robert

Andy MacDonald

Re: SSH Welcome Banner
« Reply #12 on: October 10, 2003, 10:12:15 AM »
Thanks for that site, and the motd tweak thoughts
This:
http://www.chris.com/ascii/art/html/neumanalfrede.html
is PERFECT for my servers at work...
It's going to be on ALL of them..