summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniil Baturin <daniil@baturin.org>2018-10-28 14:28:26 +0100
committerDaniil Baturin <daniil@baturin.org>2018-10-28 14:28:26 +0100
commit70142bb63b713211abfec5705993b4dd558e9268 (patch)
tree99a4cb055832d7ed171eb544b5e62101c800b08a
parentca551e0bd657afce7f366d245cbbeeb5449bc906 (diff)
downloadvyos-1x-70142bb63b713211abfec5705993b4dd558e9268.tar.gz
vyos-1x-70142bb63b713211abfec5705993b4dd558e9268.zip
T931: fix passing arguments to tcpdump filter option.
We need to pass all completion words rather than just the first since filters can contain whitespace.
-rw-r--r--op-mode-definitions/traffic-dump.xml4
1 files changed, 2 insertions, 2 deletions
diff --git a/op-mode-definitions/traffic-dump.xml b/op-mode-definitions/traffic-dump.xml
index 00a809a7c..6d86f7423 100644
--- a/op-mode-definitions/traffic-dump.xml
+++ b/op-mode-definitions/traffic-dump.xml
@@ -17,7 +17,7 @@
</properties>
<children>
<tagNode name="filter">
- <command>sudo tcpdump -n -i $4 $6</command>
+ <command>sudo tcpdump -n -i $4 "${@:6}"</command>
<properties>
<help>Monitor traffic matching filter conditions</help>
</properties>
@@ -29,7 +29,7 @@
</properties>
<children>
<tagNode name="filter">
- <command>sudo tcpdump -n -i $4 -w $6 $8</command>
+ <command>sudo tcpdump -n -i $4 -w $6 "${@:8}"</command>
<properties>
<help>Save a dump of traffic matching filter conditions to a file</help>
</properties>