Link to home
Start Free TrialLog in
Avatar of koossa
koossa

asked on

Add SQL Server Port to exceptions in Windows Firewall from vb.net

I'm looking for a way to get the Port number SQL server is running on (if possible)
and then add that port as an exception to the windows firewall for a VB.net application.
Avatar of Apothis
Apothis
Flag of United States of America image

SQL Server is a Winsock application that communicates over TCP/IP by using the sockets network library. SQL Server listens for incoming connections on a particular port. The default port for SQL Server is 1433. The port doesn't need to be 1433, but 1433 is the official Internet Assigned Number Authority (IANA) socket number for SQL Server.

Gathered from here:

http://support.microsoft.com

Hope that's what you were looking for.
Avatar of koossa
koossa

ASKER

Hi

I know what the port is, but what I'm looking for is from Visual basic .net, how do I add this port to the firewall's exception list.
In other word, I want to write a piece of code that adds port 1433 to the exception list.
ASKER CERTIFIED SOLUTION
Avatar of koossa
koossa

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of koossa

ASKER

Correct