linuxubuntunetwork-programmingsnort

SNORT list interfaces on Linux Ubuntu


Using SNORT in Windows you can execute:

C:\Snort\bin> snort -W

This will provide a numbered list of interfaces similar to the image below:

SNORT - list of interfaces

On Linux, there is no -W option. How do you print a numbered list of interfaces in Linux? (I am not looking for answers about $ ifconfig -a)


Solution

  • You can run ip link show.

    $ ip link show
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN 
        link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 9000 qdisc mq state UP qlen 1000
        link/ether 02:00:17:02:40:5e brd ff:ff:ff:ff:ff:ff
    

    From Linux: Show / Display Available Network Interfaces