Allow remote SQL connections from specific IP addresses via windows firewall?

  • My MS SQL Server 2008 R2 instance is setup to allow remote connections. However, I only want to allow remote connections from specific IP addresses via windows firewall, and block all others. How do I do this?

  • You would setup your SQL instance to listen on a specified port and then configure your firewall to allow traffic only from specific IPs to connect using that port.

    How to: Configure a Windows Firewall for Database Engine Access

    Joie Andrew
    "Since 1982"

  • Joie Andrew (9/4/2011)


    You would setup your SQL instance to listen on a specified port and then configure your firewall to allow traffic only from specific IPs to connect using that port.

    How to: Configure a Windows Firewall for Database Engine Access

    OK, I've used my Windows firewall to block ALL incoming SQL connections (That works). Then, I created another rule to allow certain IP Address. However, the Block rule is overriding the Allow rule. How do I get the Allow rule to supersede the Block rule?

  • OK, I've used my Windows firewall to block ALL incoming SQL connections (That works). Then, I created another rule to allow certain IP Address. However, the Block rule is overriding the Allow rule. How do I get the Allow rule to supersede the Block rule?

    If the rule for the specific IP is set correctly then it should be blocking ALL connections made on your specified SQL port except for the IP address you specified. Therefore you shouldn't need the block ALL rule.

    Joie Andrew
    "Since 1982"

  • If the rule for the specific IP is set correctly then it should be blocking ALL connections made on your specified SQL port except for the IP address you specified. Therefore you shouldn't need the block ALL rule.

    Sorry, forgot to mention that my VPS provider has a default rule that cannot be changed and allows everything VIA port 1433. So, thats why i need a block all rule.

  • which operating system is the machine using?

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

  • Check this one

    http://www.sqlservercentral.com/Forums/Topic1031530-146-1.aspx

    Thank You,

    Best Regards,

    SQLBuddy

  • This was removed by the editor as SPAM

  • 6 year old post!

    -----------------------------------------------------------------------------------------------------------

    "Ya can't make an omelette without breaking just a few eggs" 😉

Viewing 9 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic. Login to reply