From 34c4559c845bd6ba239bbf1013fcebbd8041e6c3 Mon Sep 17 00:00:00 2001 From: Stefan Schlesinger Date: Thu, 23 Oct 2014 18:11:31 +0200 Subject: model/asa: fixing prompt - hostname regex taken from ios model --- lib/oxidized/model/asa.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/oxidized/model') diff --git a/lib/oxidized/model/asa.rb b/lib/oxidized/model/asa.rb index 3ee4e2d..b2c3e01 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| -- cgit v1.2.1 From 764ebd865a8360057dea1b913cd41d6361e0a01f Mon Sep 17 00:00:00 2001 From: Stefan Schlesinger Date: Thu, 23 Oct 2014 18:59:44 +0200 Subject: model/asa: removing >show clock and ignoring uptime in >show version --- lib/oxidized/model/asa.rb | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'lib/oxidized/model') diff --git a/lib/oxidized/model/asa.rb b/lib/oxidized/model/asa.rb index b2c3e01..11db547 100644 --- a/lib/oxidized/model/asa.rb +++ b/lib/oxidized/model/asa.rb @@ -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 -- cgit v1.2.1