diff options
author | Christian Poessinger <christian@poessinger.com> | 2018-06-07 19:43:17 +0200 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2018-06-07 19:43:17 +0200 |
commit | e1cf8bffdadcfa2ec64db479f1d5ea78e9e47d3f (patch) | |
tree | 0e75123db610d740ccb1450e849a7049b6543a1c /src/conf_mode | |
parent | a9f57961008800f45ac96fc67e55fdba4d9943f9 (diff) | |
download | vyos-1x-e1cf8bffdadcfa2ec64db479f1d5ea78e9e47d3f.tar.gz vyos-1x-e1cf8bffdadcfa2ec64db479f1d5ea78e9e47d3f.zip |
T652: snmp.py: support SNMPv3 write groups
Diffstat (limited to 'src/conf_mode')
-rwxr-xr-x | src/conf_mode/snmp.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/conf_mode/snmp.py b/src/conf_mode/snmp.py index 3b02ffc3b..7623206b4 100755 --- a/src/conf_mode/snmp.py +++ b/src/conf_mode/snmp.py @@ -191,8 +191,13 @@ view {{ v.name }} included .{{ oid.oid }} # context sec.model sec.level match read write notif {% if v3_groups -%} {% for g in v3_groups %} +{% if g.mode == 'ro' %} access {{ g.name }} "" usm {{ g.seclevel }} exact {{ g.view }} none none access {{ g.name }} "" tsm {{ g.seclevel }} exact {{ g.view }} none none +{% elif g.mode == 'rw' %} +access {{ g.name }} "" usm {{ g.seclevel }} exact {{ g.view }} {{ g.view }} none +access {{ g.name }} "" tsm {{ g.seclevel }} exact {{ g.view }} {{ g.view }} none +{% endif %} {% endfor -%} {% endif %} |