From 3695115c6516ab2c570be7a192c1d464273cf984 Mon Sep 17 00:00:00 2001 From: kris Date: Mon, 29 Jan 2007 03:22:15 +0000 Subject: [PATCH] Changed location of IP options + root privs check in NmapOps.cc. It's now just checked along with the other things that require root privileges, and now uses privreq instead just saying 'you must be root'. --- NmapOps.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/NmapOps.cc b/NmapOps.cc index c47a4fd96..c39fc6b85 100644 --- a/NmapOps.cc +++ b/NmapOps.cc @@ -398,6 +398,9 @@ void NmapOps::ValidateOptions() { if (osscan) { fatal("TCP/IP fingerprinting (for OS scan) requires %s. Sorry, dude.\n", privreq); } + + if (o.ipoptionslen) + fatal("Sorry, using ip options requires %s.", privreq); } @@ -459,9 +462,6 @@ void NmapOps::ValidateOptions() { if (min_parallelism > max_parallelism) max_parallelism = min_parallelism; - if(o.ipoptionslen && ! o.isr00t) - fatal("To use ip options you must be root."); - if(o.ipoptions && o.osscan) error("WARNING: Ip options are NOT used while OS scanning!");