wgengine/router: Increase range of rule priorities when detecting mwan3

Context: https://github.com/tailscale/tailscale/pull/5588#issuecomment-1260655929

It seems that if the interface at index 1 is down, the rule is not installed. As such,
we increase the range we detect up to 2004 in the hope that at least one of the interfaces
1-4 will be up.

Signed-off-by: Tom DNetto <tom@tailscale.com>
This commit is contained in:
Tom DNetto 2022-09-28 11:01:05 -07:00 committed by Tom
parent 9214b293e3
commit ab591906c8

View File

@ -1713,7 +1713,7 @@ func checkOpenWRTUsingMWAN3() (bool, error) {
//
// We dont match on the mask because it can vary, or the
// table because I'm not sure if it can vary.
if r.Priority == 2001 && r.Mark != 0 {
if r.Priority >= 2001 && r.Priority <= 2004 && r.Mark != 0 {
return true, nil
}
}