Reputation: 6533
In our enterprise I don't have access to MSSQL Server, so I can'r access the system tables.
Upvotes: 1
Views: 317
Reputation: 126
If you have elevated rights to SQL but not the OS, you can query the log.
If you don't have access to the OS but can run queries, perhaps try:
USE master
GO
xp_readerrorlog 0, 1, N'Server is listening on'
GO
If you don't have elevated rights to SQL, from the client-side windows machine with an active connection, you could run a netstat command and see on which ports you are connected to the target. Filter on IP address of the host.
netstat -an | find "10.1.10.xxx"
You'll see that I have connections to the host on 3389 and 1433. Maybe this helps narrow it down.
Upvotes: 0
Reputation: 6533
What works for me is:
Wireshark
(run as Administrator, select Network Interface),while opening connection to server.ping
ip.dst == x.x.x.x
The port is shown in the column info
in the format src.port -> dst.port
Upvotes: 2