]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
Don't try to sniff 'default' interface
authorEric Leblond <eric@regit.org>
Tue, 26 Mar 2013 17:24:46 +0000 (18:24 +0100)
committerVictor Julien <victor@inliniac.net>
Thu, 28 Mar 2013 08:53:47 +0000 (09:53 +0100)
Whan running suricata via 'suricata --af-packet', the list of interfaces
was containing the 'default' interface and sniffing it was attempted.
This was not wanted.

src/util-device.c

index f5ace7da73814f01903fda43be8efdfe017916a2..14459f004040804918909e86f4dd19fa85092390 100644 (file)
@@ -141,6 +141,8 @@ int LiveBuildDeviceList(char * runmode)
             ConfNode *subchild;
             TAILQ_FOREACH(subchild, &child->head, next) {
                 if ((!strcmp(subchild->name, "interface"))) {
+                    if (!strcmp(subchild->val, "default"))
+                        break;
                     SCLogInfo("Adding interface %s from config file",
                               subchild->val);
                     LiveRegisterDevice(subchild->val);