Is there a way to know how to catch the username of the users connected to my system? So, I've a WiFi router with a wep key setted, me and friend are making some test.
Considered that my friend has encrypted the key and use my network, is it possible to know using him IP and MAC address detecting his username?? He also use an Ubuntu.
Thanks a lot!!!
I'm not sure I understand your question correctly, but if you want to know the user names logged on to you machine, via ssh over the network or directly in front of it, you could run the
w
command in a terminal:There are two different levels of authentication/connectivity involved.
More specifically:
First level:
The user provides a password, based on the selected security protocol (WEP, WPA, WPA2,etc) of your wireless router, in order to become a member of your local network and access various services (e.g. file services on your Ubuntu machine, shell access, or direct outbound Internet access).
This kind of information will be provided directly from your wireless router (probably by a web-based administration page).
Second level:
The user is already connected to the local network (so the first level of authentication has completed), has a local IP address and can access the various hosts of the network. When the user connects to your Ubuntu machine through telnet or SSH, a relevant entry will be shown by using the commands
w
,who
orusers
.One - possibly - important detail:
The commands above display currently logged on users on your system; that is, users connected remotely or locally to the system through command-line (shell access) or GUI (X session). Users connected to specific services (such as FTP) will not be visible. It is up to the specific application/daemon to log/display the users accessing the relevant service.
Use the command
users
. It will output you all users currently connected to your system :You have the
who
command which shows "Who is connected" (And its small kidw
which is the abbreviated version of it) and you also have theusers
command which shows "Users connected".