diff options
author | Saku Ytti <saku@ytti.fi> | 2014-12-03 15:22:19 +0200 |
---|---|---|
committer | Saku Ytti <saku@ytti.fi> | 2014-12-03 15:22:19 +0200 |
commit | 53daa6fab0b87c6ef6dc3efda9f0eff0f6af5e3e (patch) | |
tree | c2f3e679f5770941d2dbc8036266a8617a3340c7 /lib/oxidized/model/asa.rb | |
parent | 32733012e2bcda5373406aec8156dcb9c00a58ce (diff) | |
parent | 6132f0f825d281c2d5c7d918239eeec80b3e87be (diff) |
Merge branch 'master' into cfg_as_object
Diffstat (limited to 'lib/oxidized/model/asa.rb')
-rw-r--r-- | lib/oxidized/model/asa.rb | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/oxidized/model/asa.rb b/lib/oxidized/model/asa.rb index 3ee4e2d..8335b1d 100644 --- a/lib/oxidized/model/asa.rb +++ b/lib/oxidized/model/asa.rb @@ -3,7 +3,7 @@ class ASA < Oxidized::Model # Cisco ASA model # # Only SSH supported for the sake of security - prompt /^\r*([\w]+[#>]\s?)$/ + prompt /^\r*([\w.@()-\/]+[#>]\s?)$/ comment '! ' cmd :all do |cfg| @@ -16,11 +16,10 @@ class ASA < Oxidized::Model cfg end - cmd 'show clock' do |cfg| - comment cfg - end - cmd 'show version' do |cfg| + # avoid commits due to uptime / ixo-router01 up 2 mins 28 secs / ixo-router01 up 1 days 2 hours + cfg = cfg.each_line.select { |line| not line.match /\s+up\s+\d+\s+/ } + cfg = cfg.join comment cfg end |