luci-mod-network: enforce IPv4 mode for traceroute call
Recent busybox traceroute applet versions support both IPv4 and IPv6 and default to IPv6 when running a route trace to an IPv6 enabled target host. Pass the `-4` flag to enforce IPv4 mode in this case. Fixes: #5155 Signed-off-by: Jo-Philipp Wich <jo@mein.io> (cherry picked from commit c4f429461545d1401429e7ba133f24a55d1015b6)
This commit is contained in:
parent
165e411cd4
commit
49aa9c61db
@ -36,7 +36,7 @@ return view.extend({
|
||||
handleTraceroute: function(ev, cmd) {
|
||||
var exec = cmd || 'traceroute',
|
||||
addr = ev.currentTarget.parentNode.previousSibling.value,
|
||||
args = (exec == 'traceroute') ? [ '-q', '1', '-w', '1', '-n', addr ] : [ '-q', '1', '-w', '2', '-n', addr ];
|
||||
args = (exec == 'traceroute') ? [ '-4', '-q', '1', '-w', '1', '-n', addr ] : [ '-q', '1', '-w', '2', '-n', addr ];
|
||||
|
||||
return this.handleCommand(exec, args);
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user