Using "screen" command in linux?

JP

Limp Gawd
Joined
May 7, 2001
Messages
256
I am not sure if that is what its called, but basically what I want is this:

If I give someone SSH access to modify a file, or checkup up on something, I can see on my screen everything they type or do while SSH in.

How would I do this? whats the command? Does something have to be installed? Does the other user have to type something?
 
screen is a program used to multiplex terminal windows, similar to hitting ctrl+alt+F1-F6 for virtual consoles.

I don't know of a program like a keylogger as you describe, it sounds like a security/privacy nightmare, but if you want to know someones commands you (as root or some other priveledged user) can always setup their sessions so they save their command history to a file, then read it at your conveiniece (sp)
 
If you know the password of the user in question (assuming that you're root), you could login as that person, then open a new screen session (using screen with no parameters). Detach from the session by doing pressing CTRL+A then hitting 'd' (no quotes). Reconnect to the session by using
Code:
screen -x

Have the other person connect to the session by using the above command.

Unfortunately, this method is not very secure. The user could connect to this session and be typing in commands that he or she thinks that you want to see and think of as safe, but could still be connected to another SSH session typing in stuff that you don't want them to do.
 
so in short there is no secure to keep track of what they are doing?

how do i make that log as the other poster stated? to see everything they typed in the session?
 
e740Samurai said:
If you know the password of the user in question (assuming that you're root)

root doesn't need the password, just "su <user>" will switch to that user ;) unless of course you meant "assuming that you're *not* root)
 
Sorry, I meant assuming he owns the server. Root does not, in fact, need the password. Root can also be dangerous, but this probably isn't the place for that discussion.
 
Back
Top