How to allow ftp (range of ports) over windows firewall in WS2008
Hi All,do somebody know how to allow a range of ports in windows firewall, i did type 1024-65535 but it's not accepted, any clue?!thanks for your help!
March 3rd, 2010 12:34am

This is not possible in W2K8/Vista - BUT: It's possible under W2K8 R2 and Windows 7. That means: Do it by scripting in the earlier versions or upgrade to R2 (this is the solution, MS likes to hear ;-D)...Cheers,Andre
Free Windows Admin Tool Kit Click here and download it now
March 3rd, 2010 12:45am

Thank you Andre, that was my guess also. so anyone know a script that can accomplish that please?thanks a lot for your help!
March 3rd, 2010 12:59am

Try the following VBScript-snipplet:For i = 1024 To 65535 set WSshell = createobject("wscript.shell") WSshell.run "cmd /c netsh advfirewall firewall add rule name='Open Port " & i & "' dir=in action=allow protocol=TCP localport=" & i, 1Next(Save it with the extension ".VBS", edit it and run it ;-D...Cheers,AndrePS: Note, that you will receive around 64000 inbound rules with executing this code...
Free Windows Admin Tool Kit Click here and download it now
March 3rd, 2010 1:13am

interesting! thanks a lot but i see TCP right there if i want to do it for UDP all i have to do is change it right, and also is that mean that i will have more than 64000 line when i open the exception tab in my firewal? does this have an impact on the server performance, and sorry for that much question, and thanks one more!
March 3rd, 2010 1:20am

Hi Khalid,Yes: You can just change it to UDP as well. About the performance: I've got no experience with this, because the best solution would be to upgrade to R2 in this case. But if we go one step backwards: For what you have to create this rules especially? Is it for a specific application? If yes: Why don't you create a rule, which includes the executable instead of the ports?Cheers,Andre
Free Windows Admin Tool Kit Click here and download it now
March 3rd, 2010 1:28am

Hi Andre,actually i need to open these ports for ftp server to work properly, thanks a lot for your help!
March 3rd, 2010 5:27pm

Do you use the FTP service of IIS 6 in Windows Server 2008?
Free Windows Admin Tool Kit Click here and download it now
March 3rd, 2010 5:39pm

Open up an elevated command prompt for /L %i in (12501,1,12750) do netsh firewall add portopening profile=all TCP %i "Port-range %i"Why bother having the firewall on if you are going to open it up so completely. By the way the profile set above is for all three profiles. The example above is for a much smaller range, set the range of what you want in the loop control (12501,1,12750)-- Paul BergsonMVP - Directory ServicesMCTS, MCT, MCSE, MCSA, Security+, BS CSci2008, 2003, 2000 (Early Achiever), NT4Microsoft's Thrive IT Pro of the Month - June 2009 http://www.pbbergs.com Please no e-mails, any questions should be posted in the NewsGroup Thisposting is provided "AS IS" with no warranties, and confers no rights.
March 3rd, 2010 8:41pm

Hi Guys,to Andre: i am using ftp 7.5 on IIS7.to Paul: yes i agree i don't know why i have to open so much port for the ftp to work (now i am juste disabling it), so please if you know (or can guess) what's the range of UDP port that ftp should have in hand to work properly (knowing that the max people that can connect at the same time is around 15 ).thank you!
Free Windows Admin Tool Kit Click here and download it now
March 3rd, 2010 11:08pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics