diff options
author | Matthias Cramer <matthias.cramer@iway.ch> | 2017-06-16 11:52:47 +0200 |
---|---|---|
committer | Matthias Cramer <matthias.cramer@iway.ch> | 2017-06-16 11:52:47 +0200 |
commit | b7569965d1ec6112d0cd588ebd0b13a541bb6ef7 (patch) | |
tree | fbf410ebdfc268e55df73571fc85c426e8b25dbf /lib/oxidized/model/firewareos.rb | |
parent | bb06ac367daeed2f11682b8ef6e1182923570b42 (diff) | |
parent | dc425ce5bc3143cf4b8322602d7b7521aca37134 (diff) |
Merge branch 'master' of https://github.com/ytti/oxidized
Diffstat (limited to 'lib/oxidized/model/firewareos.rb')
-rw-r--r-- | lib/oxidized/model/firewareos.rb | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/oxidized/model/firewareos.rb b/lib/oxidized/model/firewareos.rb index f2bef4c..f456c60 100644 --- a/lib/oxidized/model/firewareos.rb +++ b/lib/oxidized/model/firewareos.rb @@ -1,12 +1,18 @@ class FirewareOS < Oxidized::Model - prompt /^\[?\w*\]?\w*<?\w*>?#\s*$/ + prompt /^([\w.@-]+[#>]\s?)$/ comment '-- ' cmd :all do |cfg| cfg.each_line.to_a[1..-2].join end + # Handle Logon Disclaimer added in XTM 11.9.3 + expect /^I have read and accept the Logon Disclaimer message. \(yes or no\)\? $/ do |data, re| + send "yes\n" + data.sub re, '' + end + cmd 'show sysinfo' do |cfg| # avoid commits due to uptime cfg = cfg.each_line.select { |line| not line.match /(.*time.*)|(.*memory.*)|(.*cpu.*)/ } |