mirror of
https://github.com/bettercap/bettercap
synced 2025-08-14 02:36:57 -07:00
fix regexp to match default gateway IPv4 address and interface name
This commit is contained in:
parent
a9ceae3b4f
commit
fd3efcac09
1 changed files with 1 additions and 1 deletions
|
@ -12,7 +12,7 @@ import (
|
|||
)
|
||||
|
||||
// only matches gateway lines
|
||||
var IPv4RouteParser = regexp.MustCompile(`^(default|[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)\svia\s([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)\sdev\s(\w+)(?:\s.*|)$`)
|
||||
var IPv4RouteParser = regexp.MustCompile(`^(default|[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)\svia\s([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)\sdev\s(\S+)\s*$`)
|
||||
var IPv4RouteTokens = 4
|
||||
var IPv4RouteCmd = "ip"
|
||||
var IPv4RouteCmdOpts = []string{"route"}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue