mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-07 17:52:46 +01:00
[fix] Fix cut command options
This commit is contained in:
@@ -1771,7 +1771,7 @@ set_network_dev_status_list() {
|
|||||||
|
|
||||||
set_main_ip() {
|
set_main_ip() {
|
||||||
MAINIP=$(ip route get 1 | awk '{print $7;exit}')
|
MAINIP=$(ip route get 1 | awk '{print $7;exit}')
|
||||||
MNIC_IP=$(ip a s "$MNIC" | grep -oE 'inet [0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}' | cut -d' ' -f)
|
MNIC_IP=$(ip a s "$MNIC" | grep -oE 'inet [0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}' | cut -d' ' -f2)
|
||||||
|
|
||||||
if [[ $MAINIP != $MNIC_IP ]]; then
|
if [[ $MAINIP != $MNIC_IP ]]; then
|
||||||
read -r -d '' message <<- EOM
|
read -r -d '' message <<- EOM
|
||||||
|
|||||||
Reference in New Issue
Block a user