Copy Code code as follows:
' On Error Resume Next
Const Allow_all = 0
Port = Array ("4900", "5000", "5100", "5500", "5600", "6000", "7000", "7100", "7200", "7300", "7400", "3389", "80")
StrComputer = "."
Set objWMIService = GetObject ("winmgmts:\\" & StrComputer & "\root\cimv2")
Set Colnetcards = objWMIService.ExecQuery _
("SELECT * from Win32_NetworkAdapterConfiguration Where ipenabled = True")
For each objnetcard in Colnetcards
Arrpermittedtcpports = Port
Arrpermittedudpports = Array (Allow_all)
Arrpermittedipprotocols = Array (Allow_all)
Objnetcard.enableipsec arrpermittedtcpports, Arrpermittedudpports, Arrpermittedipprotocols
Next
After execution, to
My Network Neighborhood--right------------------------------------------------------"Internet Protocol (TCP/IP)--> properties
The above code is just an example, the server does not run Ah, if you want to set up the server, please go to the Cloud Community Server Software Download Center, view the relevant textbooks.