|
junchen2
高级用户
   
积分 537
发帖 219
注册 2007-8-4 来自 杭州--半山
状态 离线
|
『楼 主』:
两台电脑局域网互连,谢谢!
使用 LLM 解释/回答一下
请问两台电脑局域网互连命令这么实现,
还有添加到网上邻居的方法,就是能在网上邻居上看到对方
非常谢谢!!!
Last edited by junchen2 on 2007-11-12 at 12:25 PM ]
How to implement the command for two computers to be interconnected in a local area network, and the method to add to Network Neighborhood, that is, to be able to see the other party in Network Neighborhood. Thank you very much!!!
Last edited by junchen2 on 2007-11-12 at 12:25 PM ]
|
|
2007-11-11 22:58 |
|
|
afeichai
初级用户
 
积分 171
发帖 78
注册 2006-11-22
状态 离线
|
『第 2 楼』:
使用 LLM 解释/回答一下
红叶的
@ ECHO OFF
color 1b
title 开通局域网共享
@ ECHO.
@ ECHO. 说 明
@ ECHO --------------------------------------------------------------------
@ ECHO 本批处理执行后,将作以下一些设置:
@ ECHO 1、允许SAM帐户和共享的匿名枚举
@ ECHO 2、本机帐户若空密码,允许其它机访问本机。
@ ECHO 3、Windows防火墙:允许文件和打印机共享。
@ ECHO 4、共享方式:本地用户以来宾身份验证。
@ ECHO 5、来宾帐户:启用。
@ ECHO.
@ ECHO 采用这种共享方式,其它机访问本机都不用输用户名和密码。举例来说,家庭
@ ECHO 局域网,彼此都是可以信任的,请使用这种方式。
@ ECHO.
@ ECHO 无论采用哪一种共享方式,共享只是方便内部使用,在用路由器上网的场合,
@ ECHO 外网不能访问到您的机,无需担心共享了就会被入侵。您只需记住,单机拨号
@ ECHO 上网时,不要打开共享就可以了。
@ ECHO --------------------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v "restrictanonymous" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "restrictanonymous" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "limitblankpassworduse" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v "limitblankpassworduse" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Epoch /v "Epoch" /t REG_DWORD /d 0x000001ED /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Print\Providers /v "LogonTime" /t REG_BINARY /d E8318E4F6495C601 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Epoch /v "Epoch" /t REG_DWORD /d 0x000001ED /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "forceguest" /t REG_DWORD /d 0x00000001 /F>nul
cls
@ ECHO.
@ ECHO --------------------------------------------------------------------
@ ECHO 操作完成。
@ ECHO 注意:本机要重启后才会生效。
@ ECHO.
@ ECHO --------------------------------------------------------------------
@ ECHO.
@ ECHO 疑难问题补充:
@ ECHO 如果以前的共享方式是“本地用户以自己自己身份验证”时共享了文件夹,
@ ECHO 则现在改为以来宾身份验证后再访问该文件夹,会弹出错误:无法访问,您
@ ECHO 没有权限使用网络资源。解决办法是,把该文件夹原共享属性取消,然后再
@ ECHO 次共享,就行了。
@ ECHO --------------------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
Last edited by afeichai on 2007-11-12 at 09:09 AM ]
Red Maple Leaf's
@ ECHO OFF
color 1b
title Enable LAN Sharing
@ ECHO.
@ ECHO. Instructions
@ ECHO --------------------------------------------------------------------
@ ECHO After executing this batch processing, the following settings will be made:
@ ECHO 1. Allow anonymous enumeration of SAM accounts and shares
@ ECHO 2. If the local account has an empty password, allow other machines to access this machine.
@ ECHO 3. Windows Firewall: Allow file and printer sharing.
@ ECHO 4. Sharing method: Local users authenticate as guests.
@ ECHO 5. Guest account: Enable.
@ ECHO.
@ ECHO With this sharing method, other machines can access this machine without entering a username or password. For example, in a home LAN where everyone is trustworthy, use this method.
@ ECHO.
@ ECHO No matter which sharing method is used, sharing is only for internal use. In the case of using a router to access the Internet, the external network cannot access your machine, so there is no need to worry about being invaded if sharing is enabled. You only need to remember that when dialing up alone, do not enable sharing.
@ ECHO --------------------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v "restrictanonymous" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "restrictanonymous" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "limitblankpassworduse" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v "limitblankpassworduse" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Epoch /v "Epoch" /t REG_DWORD /d 0x000001ED /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Print\Providers /v "LogonTime" /t REG_BINARY /d E8318E4F6495C601 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Epoch /v "Epoch" /t REG_DWORD /d 0x000001ED /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "forceguest" /t REG_DWORD /d 0x00000001 /F>nul
cls
@ ECHO.
@ ECHO --------------------------------------------------------------------
@ ECHO Operation completed.
@ ECHO Note: It will take effect after this machine restarts.
@ ECHO.
@ ECHO --------------------------------------------------------------------
@ ECHO.
@ ECHO Supplementary questions and answers:
@ ECHO If the previous sharing method was "Local users authenticate as themselves" when sharing a folder,
@ ECHO then when switching to authenticating as a guest and then accessing that folder, an error will pop up: Cannot access, you do not have permission to use the network resource. The solution is to cancel the original sharing properties of that folder, and then share it again.
@ ECHO --------------------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
Last edited by afeichai on 2007-11-12 at 09:09 AM ]
|
|
2007-11-12 09:02 |
|
|
afeichai
初级用户
 
积分 171
发帖 78
注册 2006-11-22
状态 离线
|
『第 3 楼』:
使用 LLM 解释/回答一下
@ ECHO OFF
color 1b
title 开通局域网共享
@ ECHO.
@ ECHO. 说 明
@ ECHO --------------------------------------------------------------------
@ ECHO 本批处理执行后,将作以下一些设置:
@ ECHO 1、允许SAM帐户和共享的匿名枚举(
@ ECHO 2、本机帐户若空密码,允许其它机访问本机。
@ ECHO 3、Windows防火墙:允许文件和打印机共享。
@ ECHO 4、共享方式:本地用户以自己的身份验证。
@ ECHO 5、来宾帐户:不启用。
@ ECHO.
@ ECHO 采用这种共享方式,访问本机时必须要输入正确的用户名和密码,才能访问。
@ ECHO.
@ ECHO 无论采用哪一种共享方式,共享只是方便内部使用,在用路由器上网的场合,
@ ECHO 外网不能访问到您的机,无需担心共享了就会被入侵。您只需记住,单机拨号
@ ECHO 上网时,不要打开共享就可以了。
@ ECHO --------------------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v "restrictanonymous" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "restrictanonymous" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "limitblankpassworduse" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v "limitblankpassworduse" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Epoch /v "Epoch" /t REG_DWORD /d 0x000001ED /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Print\Providers /v "LogonTime" /t REG_BINARY /d E8318E4F6495C601 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Epoch /v "Epoch" /t REG_DWORD /d 0x000001ED /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "forceguest" /t REG_DWORD /d 0x00000000 /F>nul
cls
@ ECHO.
@ ECHO ------------------------------------------------
@ ECHO 操作完成。
@ ECHO 注意:本机要重启后才会生效。
@ ECHO.
@ ECHO -------------------------------------------------------------------
@ ECHO.
@ ECHO 常见疑问:
@ ECHO 如果改后再访问本机,仍不提示输帐号和密码,这是因为其他电脑的帐户
@ ECHO 名称跟本机的一样(比如大家都是administrator),且本机无密码,所以直接
@ ECHO 就进去了。您应该把本机帐户改名,或加密码。未经授权的用户就不能随意
@ ECHO 访问您共享的资源了。
@ ECHO -------------------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
Last edited by afeichai on 2007-11-12 at 09:09 AM ]
@ECHO OFF
color 1b
title Enable LAN Sharing
@ECHO.
@ECHO. Description
@ECHO --------------------------------------------------------------------
@ECHO After executing this batch script, the following settings will be made:
@ECHO 1. Allow anonymous enumeration of SAM accounts and shares (
@ECHO 2. If the local account has an empty password, allow other machines to access this machine.
@ECHO 3. Windows Firewall: Allow file and printer sharing.
@ECHO 4. Sharing method: Local users authenticate with their own identities.
@ECHO 5. Guest account: Not enabled.
@ECHO.
@ECHO With this sharing method, you must enter the correct username and password to access this machine when visiting.
@ECHO.
@ECHO Regardless of which sharing method is used, sharing is only for internal use. In the case of using a router to access the Internet,
@ECHO the external network cannot access your machine, so there is no need to worry about being hacked if shared. You only need to remember that when dialing up with a single computer,
@ECHO do not turn on sharing.
@ECHO --------------------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v "restrictanonymous" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "restrictanonymous" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "limitblankpassworduse" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v "limitblankpassworduse" /t REG_DWORD /d 0x00000000 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Epoch /v "Epoch" /t REG_DWORD /d 0x000001ED /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Print\Providers /v "LogonTime" /t REG_BINARY /d E8318E4F6495C601 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Enabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Enabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Epoch /v "Epoch" /t REG_DWORD /d 0x000001ED /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v "forceguest" /t REG_DWORD /d 0x00000000 /F>nul
cls
@ECHO.
@ECHO ------------------------------------------------
@ECHO Operation completed.
@ECHO Note: It will take effect only after the machine is restarted.
@ECHO.
@ECHO -------------------------------------------------------------------
@ECHO.
@ECHO Common Questions:
@ECHO If after modification, accessing this machine still does not prompt for account and password, it is because the account names of other computers are the same as this machine's (for example, both are administrator), and this machine has no password, so it directly enters. You should rename the local account or set a password. Unauthorized users will not be able to randomly access the resources you shared.
@ECHO -------------------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
Last edited by afeichai on 2007-11-12 at 09:09 AM ]
|
|
2007-11-12 09:04 |
|
|
afeichai
初级用户
 
积分 171
发帖 78
注册 2006-11-22
状态 离线
|
『第 4 楼』:
使用 LLM 解释/回答一下
@ ECHO OFF
color 1b
title 关闭局域网共享
@ ECHO.
@ ECHO. 说 明
@ ECHO ----------------------------------------------------------
@ ECHO 本批处理执行后,将作以下一些设置:
@ ECHO 1、不允许SAM帐户和共享的匿名枚举(原版系统默认是允许的)。
@ ECHO 2、本机帐户若空密码,不允许其它机访问本机。
@ ECHO 3、Windows防火墙:不允许文件和打印机共享。
@ ECHO 4、来宾帐户:禁用。
@ ECHO.
@ ECHO 如果您不需要常在局域网内互传文件,可以关闭共享功能以提高
@ ECHO 安全性。尤其是单机拨号上网的用户,更应关闭共享。
@ ECHO ----------------------------------------------------------
for /l %%i in (1,1,5000) do @echo %%i>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v restrictanonymous /t REG_DWORD /d 0x00000001 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v restrictanonymous /t REG_DWORD /d 0x00000001 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v limitblankpassworduse /t REG_DWORD /d 0x00000001 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v limitblankpassworduse /t REG_DWORD /d 0x00000001 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Disabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Disabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Disabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Disabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Epoch /v Epoch /t REG_DWORD /d 0x000001FC /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Disabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Disabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Disabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Disabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Epoch /v Epoch /t REG_DWORD /d 0x000001FC /F>nul
cls
@ ECHO.
@ ECHO ----------------------------------------------------------
@ ECHO 操作完成。
@ ECHO 不必重启,设置已生效。
@ ECHO ----------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
exit
@ECHO OFF
color 1b
title Close LAN Sharing
@ECHO.
@ECHO. INSTRUCTIONS
@ECHO ----------------------------------------------------------
@ECHO After executing this batch script, the following settings will be made:
@ECHO 1. Disable anonymous enumeration of SAM accounts and shares (originally allowed in default systems).
@ECHO 2. Do not allow other machines to access this machine if the local account has an empty password.
@ECHO 3. Windows Firewall: Do not allow file and printer sharing.
@ECHO 4. Guest account: Disable.
@ECHO.
@ECHO If you do not often need to transfer files within the LAN, you can close the sharing function to improve
@ECHO security. Especially users who dial up to the Internet with a single computer should close the sharing.
@ECHO ----------------------------------------------------------
for /l %%i in (1,1,5000) do @echo %%i>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v restrictanonymous /t REG_DWORD /d 0x00000001 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v restrictanonymous /t REG_DWORD /d 0x00000001 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa /v limitblankpassworduse /t REG_DWORD /d 0x00000001 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Lsa /v limitblankpassworduse /t REG_DWORD /d 0x00000001 /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Disabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "138:UDP:LocalSubNet:Disabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Disabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Disabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SharedAccess\Epoch /v Epoch /t REG_DWORD /d 0x000001FC /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "445:TCP" /d "445:TCP:LocalSubNet:Disabled:@xpsp2res.dll,-22005" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "137:UDP" /d "137:UDP:LocalSubNet:Disabled:@xpsp2res.dll,-22001" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "138:UDP" /d "138:UDP:LocalSubNet:Disabled:@xpsp2res.dll,-22002" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Parameters\FirewallPolicy\StandardProfile\GloballyOpenPorts\List /v "139:TCP" /d "139:TCP:LocalSubNet:Disabled:@xpsp2res.dll,-22004" /F>nul
reg add HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Services\SharedAccess\Epoch /v Epoch /t REG_DWORD /d 0x000001FC /F>nul
cls
@ECHO.
@ECHO ----------------------------------------------------------
@ECHO Operation completed.
@ECHO No restart is required, the settings have taken effect.
@ECHO ----------------------------------------------------------
for /l %%i in (1,1,10000) do @echo %%i>nul
exit
|
|
2007-11-12 09:04 |
|
|
junchen2
高级用户
   
积分 537
发帖 219
注册 2007-8-4 来自 杭州--半山
状态 离线
|
『第 5 楼』:
使用 LLM 解释/回答一下
谢谢兄弟,我试一下。
Thanks, brother. I'll give it a try.
|
|
2007-11-12 10:41 |
|
|
junchen2
高级用户
   
积分 537
发帖 219
注册 2007-8-4 来自 杭州--半山
状态 离线
|
『第 6 楼』:
使用 LLM 解释/回答一下
再次谢谢afeichai兄,改动成功谢谢!!!
Thanks again to brother afeichai, the modification was successful, thank you!!!
|
|
2007-11-12 11:12 |
|
|
junchen2
高级用户
   
积分 537
发帖 219
注册 2007-8-4 来自 杭州--半山
状态 离线
|
|
2007-11-12 11:14 |
|
|
qq82015930
中级用户
  
积分 235
发帖 109
注册 2006-8-24
状态 离线
|
|
2007-12-8 13:16 |
|
|