主机是否出网判断命令


协议:ICMP、TCP、UDP、http、DNS

ICMP

ping ip/domain
tracert ip/domain
ping www.baidu.com	# ICMP
tracert baidu.com	# ICMP

TCP/UDP

telnet ip port
nc -zv ip port
nc -zuv ip port
telnet 192.168.1.108 22		# TCP
nc -zv 192.168.1.108 80		# TCP
nc -zuv 192.168.1.108 80	# UDP

HTTP/HTTPS

curl ip or domain
curl http://www.baidu.com	# HTTP
curl https://www.baidu.com	# HTTPS
Linux: wget curl
Windows: certutil powershell bitsadmin regsrv....

DNS

linux:
dig @8.8.8.8 www.baidu.com		#DNS

windows:
nslookup www.baidu.com 8.8.8.8 	        #DNS

参考:http://aiyuanzhen.com/index.php/archives/232/


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM