最新消息:新席地网:网页制作,360度全景摄影,微信营销推广,详情见:新席地网xxidi.com,电话:13913571631

记录远程桌面IP策略

技术 admin 2623浏览 0评论

下面的代码复制一下存成一个批处理文件后双击即可!
3389IP日志路径是C:WINDOWSPDPLOGRDPlog.txt

MD C:WINDOWSPDPLOG
echo date /t ^>^>RDPlog.txt >>C:WINDOWSPDPLOGPdPLOG.CMD
echo time /t ^>^>RDPlog.txt >>C:WINDOWSPDPLOGPdPLOG.CMD
echo netstat -n -p tcp ^| find ":3389"^>^>RDPlog.txt >>C:WINDOWSPDPLOGPdPLOG.CMD
echo start Explorer >>C:WINDOWSPDPLOGPdPLOG.CMD

:: 添加用户每次进入远程桌面时自动记录下来所用IP,可用来发现黑客踪迹!
REG ADD "HKEY_LOCAL_MACHINESYSTEMControlSet001ControlTerminal ServerWinStationsRDP-Tcp" /v fInheritInitialProgram /t REG_DWORD /d "00000000" /f
REG ADD "HKEY_LOCAL_MACHINESYSTEMControlSet001ControlTerminal ServerWinStationsRDP-Tcp" /v WorkDirectory /t REG_SZ /d C:WINDOWSPDPLOG /f
REG ADD "HKEY_LOCAL_MACHINESYSTEMControlSet001ControlTerminal ServerWinStationsRDP-Tcp" /v InitialProgram /t REG_SZ /d "C:WINDOWSPDPLOGPdPLOG.CMD" /f
REG ADD "HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlTerminal ServerWinStationsRDP-Tcp" /v fInheritInitialProgram /t REG_DWORD /d "00000000" /f
REG ADD "HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlTerminal ServerWinStationsRDP-Tcp" /v WorkDirectory /t REG_SZ /d C:WINDOWSPDPLOG /f
REG ADD "HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlTerminal ServerWinStationsRDP-Tcp" /v InitialProgram /t REG_SZ /d "C:WINDOWSPDPLOGPdPLOG.CMD" /f

Echo 记录远程桌面IP策略添加完毕! 请按任意键退出!
PAUSE >nul



分享到: 更多

转载请注明:梦寻天涯的博客 » 记录远程桌面IP策略

发表我的评论
取消评论

表情

Hi,您需要填写昵称和邮箱!

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址