Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Beide Seiten der vorigen Revision Vorhergehende Überarbeitung Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
netzwerktools [09/08/2023 - 08:59] – gelöscht - Externe Bearbeitung (Unbekanntes Datum) 127.0.0.1 | netzwerktools [21/11/2024 - 10:04] (aktuell) – [SS] thommie_netzwissen.de | ||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
+ | ====== NMAP ====== | ||
+ | |||
+ | udp Scan für openvpn | ||
+ | |||
+ | < | ||
+ | nmap -Pn -sU -p 1194 dvsdnet2.devoteam.de | ||
+ | </ | ||
+ | |||
+ | ====== SS - another utility to investigate sockets ====== | ||
+ | |||
+ | https:// | ||
+ | |||
+ | ss = alle offenen nicht horchenden sockets mit aktiven verbindungen | ||
+ | |||
+ | ===== horchende und nicht horchende ===== | ||
+ | |||
+ | < | ||
+ | ss -a | ||
+ | </ | ||
+ | |||
+ | ===== nur horchende===== | ||
+ | |||
+ | < | ||
+ | ss -l nur horchende | ||
+ | </ | ||
+ | |||
+ | ===== nur tcp ===== | ||
+ | |||
+ | < | ||
+ | ss -t nur tcp | ||
+ | </ | ||
+ | |||
+ | ===== alle tcp ===== | ||
+ | |||
+ | < | ||
+ | ss -at alle tcp | ||
+ | </ | ||
+ | |||
+ | ===== alle udp ===== | ||
+ | |||
+ | < | ||
+ | ss -u udp | ||
+ | |||
+ | ss -au alle udp | ||
+ | |||
+ | ss -lu alle horchenden udp | ||
+ | </ | ||
+ | |||
+ | ===== alle sockets ===== | ||
+ | |||
+ | < | ||
+ | ss -f unix alle unix sockets | ||
+ | |||
+ | ss -w alle raw sockets | ||
+ | </ | ||
+ | ===== spezielle zieladresse ===== | ||
+ | |||
+ | < | ||
+ | ss dst 104.21.3.132 | ||
+ | </ | ||
+ | |||
+ | ===== spezielle quelladresse ===== | ||
+ | |||
+ | < | ||
+ | ss src 192.168.100.2 | ||
+ | </ | ||
+ | |||
+ | ===== spezielle prozess-id ===== | ||
+ | |||
+ | < | ||
+ | ss -p process IDs | ||
+ | </ | ||
+ | |||
+ | ====== NETSTAT ====== | ||
+ | |||
+ | ===== Ports checken ===== | ||
+ | |||
+ | Alle TCP ports auflisten, auf denen jemand horcht, inklusive PID und name des daemons. | ||
+ | |||
+ | < | ||
+ | sudo netstat -plnt | ||
+ | |||
+ | </ | ||
+ | |||
+ | Beispiel | ||
+ | |||
+ | < | ||
+ | $ sudo netstat -plnt | ||
+ | Active Internet connections (only servers) | ||
+ | Proto Recv-Q Send-Q Local Address | ||
+ | tcp 0 0 0.0.0.0: | ||
+ | tcp 0 0 ::: | ||
+ | tcp 0 0 :::80 ::: | ||
+ | tcp 0 0 :::22 ::: | ||
+ | |||
+ | </ | ||
+ | |||
+ | ===== Liste filtern ===== | ||
+ | |||
+ | If the list of listening daemons is long, you can use '' | ||
+ | < | ||
+ | $ sudo netstat -plnt | grep ': | ||
+ | tcp | ||
+ | |||
+ | </ | ||
+ | |||
+ | ===== Analyze the results ===== | ||
+ | |||
+ | Common outcomes include the following results: | ||
+ | |||
+ | * Nothing is listening on the port. Check the service configuration files, and then restart the service. | ||
+ | * The correct service is listening on the correct port. In this case you need to test the service more thoroughly. Skip to the article on [[https:// | ||
+ | * Something other than the expected service appears to be listening on the port. | ||
+ | |||
+ | **Note**: A super-server, | ||
+ | |||
+ | If something else is listening on the port, you can disable the program by running '' | ||
+ | |||
+ | If you make any changes because the incorrect service is listening, run the '' | ||
+ | |||
+ | If you make changes at this point, be sure to test your setup to verify that you have resolved your issue. | ||
+ | |||
+ | If using the '' | ||
+ | |||
+ | ====== IPTABLES ====== | ||
+ | |||
+ | iptables -nvL | ||
+ | |||
+ | iptables -nvL -t nat | ||
+ | |||
+ | ====== TCPDUMP ====== | ||
+ | |||
+ | tcpdump -i vmbr0 -nn port 1194 | ||
+ | |||
+ | tcpdump -i vmbr1 -nn port 1194 | ||