DataSoft / Honeyd

virtual honeypots
GNU General Public License v2.0
348 stars 101 forks source link

The --verify-config option always exits with status code 1 #83

Closed mojotoad closed 11 years ago

mojotoad commented 11 years ago

As stated above, the exit code is 1 even if parsing the config file was successful. In addition, root is required in order to do this...it would be more useful if non-privileged accounts could check the syntax of config files.

PherricOxide commented 11 years ago

You shouldn't reed root to run --verify-config; does it give you a specific error when you run it without root?

mojotoad commented 11 years ago

Here's what I'm seeing:

[honeyd@localhost ~]$ honeyd --verify-config -f ./honeyd.conf Honeyd V1.6d Copyright (c) 2002-2007 Niels Provos honeyd[22436]: started with --verify-config -f ./honeyd.conf Error: Could not change owner of ~/.config/honeyd: Operation not permitted honeyd[22436]: pcap_lookupdev: no suitable device found

Also...I think this must be something else entirely, but if I use "-f honeyd.conf" (no preceding "./") then it core dumps...no idea what that is.

EDIT: Just for completeness, if I pass it a nonexistent path it's the same result:

[honeyd@localhost ~]$ honeyd --verify-config -f /flurble/bubble.conf Honeyd V1.6d Copyright (c) 2002-2007 Niels Provos honeyd[22700]: started with -d --verify-config -f /flurble/bubble.conf Error: Could not change owner of ~/.config/honeyd: Operation not permitted honeyd[22700]: pcap_lookupdev: no suitable device found

PherricOxide commented 11 years ago

What are the permissions on ~/.config/honeyd?