mirror of
https://github.com/nmap/nmap.git
synced 2026-08-04 14:49:29 +00:00
Don't try to start NPF if o.isr00t is false (in other words, the --unprivileged
option was used). This idea was from Michael Pattrick.
This commit is contained in:
parent
df19889e22
commit
ab3b1f409d
1 changed files with 5 additions and 1 deletions
|
|
@ -236,7 +236,11 @@ void win_init()
|
|||
if(o.debugging)
|
||||
printf("Winpcap present, dynamic linked to: %s\n", pcap_lib_version());
|
||||
|
||||
o.have_pcap = o.have_pcap && start_npf();
|
||||
/* o.is00t will be false at this point if the used asked for
|
||||
--unprivileged. In that case don't bother them with a
|
||||
potential UAC dialog when starting NPF. */
|
||||
if (o.isr00t)
|
||||
o.have_pcap = o.have_pcap && start_npf();
|
||||
}
|
||||
#ifdef _MSC_VER
|
||||
__except (1) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue