LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 02-10-2007, 08:57 PM   #1
BlueTornJacket
LQ Newbie
 
Registered: Jan 2007
Distribution: Ubuntu 5.10 Breezy, Fedora Core 6, Mac OS X 10.4.8
Posts: 16

Rep: Reputation: 0
Manage Open SSH sessions


Is there any way I can view/monitor sessions that have been made from an external source to my ssh server?
I know there are various ftp clients out there that support session monitoring which lists things like connect time, active downloads etc. I'm simply looking for an SSH equivalent of this.
 
Old 02-10-2007, 09:02 PM   #2
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 76
Well the traffic is encrypted, so you're not supposed to know what they're doing... You can increase the log detail level, but that will reveal details like the user's passwords (if they use password authentication rather than public key).
 
Old 02-10-2007, 09:29 PM   #3
BlueTornJacket
LQ Newbie
 
Registered: Jan 2007
Distribution: Ubuntu 5.10 Breezy, Fedora Core 6, Mac OS X 10.4.8
Posts: 16

Original Poster
Rep: Reputation: 0
How would I go about increasing the log level detail? Is there a good log manager application you recommend so I don't have to manually go sifting through them?

Since the traffic itself is encrypted, but their shell is technically interacting with my hardware, can't i at least see what shares/files they may have open/be accessing?
 
Old 02-12-2007, 05:52 AM   #4
prasanta
Member
 
Registered: Mar 2005
Location: India
Distribution: Debian
Posts: 368

Rep: Reputation: 37
Just did a google search and found out this link. Shall try to implement it myself the same also. Hope it helps,

http://lists.freebsd.org/pipermail/f...ne/091000.html

--
Prasanta
 
Old 03-10-2007, 01:44 PM   #5
BlueTornJacket
LQ Newbie
 
Registered: Jan 2007
Distribution: Ubuntu 5.10 Breezy, Fedora Core 6, Mac OS X 10.4.8
Posts: 16

Original Poster
Rep: Reputation: 0
Although this post was made awhile back, I actually solved this issue and forgot to update the thread.

All commands than are run are actually stored in a file .bash_history in the users home directory.

The file only seems to store the last 1000 commands.

Running the command history dumps formatted output of this file. This file is user specific, so to get history of a specific users last bash commands first login to that user.

Hope that's helpful for any future readers who stumble over this.
 
Old 03-10-2007, 07:10 PM   #6
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290

Rep: Reputation: 378Reputation: 378Reputation: 378Reputation: 378
Just remember that users can modify their histories or turn off history file accounting, so the method is not good for real security work. If you're that paranoid, you can enable BSD style process accounting but it's generally not enabled in the kernel so you might have to recompile your kernel to get it working.

Edit: actually I take that last part back. Apparently it's configured by default at least for centOS 9and I assume Fedora) and Ubuntu systems. Note sure about others.

Last edited by btmiller; 03-10-2007 at 07:30 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[priv] in SSH Sessions stefaandk Linux - Security 2 09-22-2006 12:05 PM
SSH and SFTP sessions BigLar Linux - General 3 04-26-2006 10:18 AM
SSH help, concerning sessions frokid879 Linux - Newbie 4 11-11-2005 11:22 AM
dead ssh sessions babroga Linux - Networking 3 03-03-2002 06:43 PM
dead ssh sessions babroga Linux - Newbie 1 03-03-2002 08:16 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:54 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration