diff options
author | ytti <saku@ytti.fi> | 2016-08-24 17:26:32 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-24 17:26:32 +0300 |
commit | 1f1672fa4c860f037e79310f53beb9172378f500 (patch) | |
tree | 58370062e7e56cdd34a90edb1a11f874a4b301f8 /lib/oxidized/model/acos.rb | |
parent | 2da8494f90d29d2278be616b20743233c91522f8 (diff) | |
parent | e2fa16b811791c7e2a0563d7b57140b4ccb2a9b4 (diff) |
Merge pull request #536 from funzoneq/master
A10 and ASA fixes
Diffstat (limited to 'lib/oxidized/model/acos.rb')
-rw-r--r-- | lib/oxidized/model/acos.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/oxidized/model/acos.rb b/lib/oxidized/model/acos.rb index bb9846e..47649a2 100644 --- a/lib/oxidized/model/acos.rb +++ b/lib/oxidized/model/acos.rb @@ -6,6 +6,13 @@ class ACOS < Oxidized::Model ##ACOS prompt changes depending on the state of the device prompt /^([-\w.\/:?\[\]\(\)]+[#>]\s?)$/ + cmd :secret do |cfg| + cfg.gsub!(/community read encrypted (\S+)/, 'community read encrypted <hidden>') # snmp + cfg.gsub!(/secret encrypted (\S+)/, 'secret encrypted <hidden>') # tacacs-server + cfg.gsub!(/password encrypted (\S+)/, 'password encrypted <hidden>') # user + cfg + end + cmd 'show version' do |cfg| cfg.gsub! /\s(Last configuration saved at).*/, ' \\1 <removed>' cfg.gsub! /\s(Memory).*/, ' \\1 <removed>' @@ -22,11 +29,20 @@ class ACOS < Oxidized::Model comment cfg end + cmd 'show partition-config all' do |cfg| + cfg.gsub! /(Current configuration).*/, '\\1 <removed>' + cfg.gsub! /(Configuration last updated at).*/, '\\1 <removed>' + cfg.gsub! /(Configuration last saved at).*/, '\\1 <removed>' + cfg.gsub! /(Configuration last synchronized at).*/, '\\1 <removed>' + cfg + end + cmd 'show running-config all-partitions' do |cfg| cfg.gsub! /(Current configuration).*/, '\\1 <removed>' cfg.gsub! /(Configuration last updated at).*/, '\\1 <removed>' cfg.gsub! /(Configuration last saved at).*/, '\\1 <removed>' cfg.gsub! /(Configuration last synchronized at).*/, '\\1 <removed>' + cfg end cmd 'show aflex all-partitions' do |cfg| |