From 1155196df5c7fd19dde657671dc4a65f7d421101 Mon Sep 17 00:00:00 2001 From: david Date: Sat, 6 Oct 2012 20:48:32 +0000 Subject: [PATCH] Allow -PO (protocol/NH ping) for IPv6. Works for me. --- NmapOps.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/NmapOps.cc b/NmapOps.cc index 3a08719db..fdfbc99a5 100644 --- a/NmapOps.cc +++ b/NmapOps.cc @@ -425,8 +425,8 @@ dialog where you can start NPF if you have administrator privileges."; fatal("Sorry, SCTP INIT Ping (-PY) only works if you are root (because we need to read raw responses off the wire)"); } - if ((pingtype & PINGTYPE_PROTO) && (!isr00t || af() != AF_INET)) { - fatal("Sorry, IPProto Ping (-PO) only works if you are root (because we need to read raw responses off the wire) and only for IPv4"); + if ((pingtype & PINGTYPE_PROTO) && (!isr00t)) { + fatal("Sorry, IPProto Ping (-PO) only works if you are root (because we need to read raw responses off the wire)"); } if (ipprotscan && (TCPScan() || UDPScan() || SCTPScan())) {