Sign in to follow this  
Followers 0
jezznar

Get Remote Connection Information

8 posts in this topic

Hi, I'm not really that new to AUTOIT coding but I don't really have all the grasp in all of its commands.

does anybody know how to get Remote Connection Information?

I am starting a project regarding Remote Connection Monitoring. Here are what my application would do.

1. Wait for remote connection

2. If remote connection is available, get the "Remote User Info" (Computer Name, IP Address and if possible, UserName of the

one doing the Remote Control)

3. Continuously append these information to a certain log or database

4. A "Remote Connection Monitor" will query this log or database to get the "Remote Connection History" and the current user and be able to identify if it is still active or not since #3 condition should be met.

any inputs please? ;)

Share this post


Link to post
Share on other sites



Hi, jessnar, welcome to the forum. To begin with your number 1 step - can you better define "remote connection"? Is this going to be solely RDP, or Offer Assistance, or perhaps some 3rd party tool? That will make all the difference in how you monitor the connection.


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

Hi Jlogan3o13,

I will only be using sole RDP (mstsc.exe). ;)

Share this post


Link to post
Share on other sites

#4 ·  Posted (edited)

In that case, my suggestion (at a high level) would be:

Use ProcessExists to check for RDPClip.exe

1. Wait for remote connection

Check open sessions on the machine for username, or use netstat to get information on the active network connections to the box.

2. If remote connection is available, get the "Remote User Info" (Computer Name, IP Address and if possible, UserName of the

one doing the Remote Control)

Write results to a file using FileWriteLine, or delve into the SQLite functions in the help file for using a db.

3. Continuously append these information to a certain log or database

Step 4 will be another script altogether, so I would say start with these. Read through the help file and see what you can come up with. If you encounter any difficulties, feel free to post what you have here and we'll do what we can to help. ;)

Edited by JLogan3o13

√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

ingenius! but the thing is that, I do not know how to do your suggest about #1. I do not know which commands I'd use. but basically

i can study how to use the commands if you can suggest some of it ;)

Check open sessions on the machine for username, or use netstat to get information on the active network connections to the box.

all the other suggestions, I think I can handle them :)

Edited by jezznar

Share this post


Link to post
Share on other sites

Try the native windows "net session" command. You should be able to call this, which will show you session information, and then output the data to your file or db.


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites

well currently I tried doing that manually. Apparently, I RDP'd to another desktop and tried "net session" using cmd but im getting this:

tried net user, net view still not getting my PC's username or Computer Name.

mmmmm..

Share this post


Link to post
Share on other sites

#8 ·  Posted (edited)

"there are no entries in the list"

ill probably be using their IP addresses instead. thanks for the input. i'll try to post my code ones I get to start with it ;)

Edited by jezznar

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0