sensu-plugins-strongswan 2.1.0 → 2.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6874e8d33f5a7e18a4cacee0a01b7dfb5429bb8655f3ce7fd1422cb3f699154d
4
- data.tar.gz: f2ae3f153952899dfd0c1455acc8cdf0b19ecd0daaabbd5e2bc531a8221cade0
3
+ metadata.gz: 0329cb2c898285db4f94bbdbd83505c86a8fe9eb718b7428263a479fdec90f89
4
+ data.tar.gz: feb9f53a008682514b4464ea20f3210fd579b1712cc4bc998fda1b7db74451d8
5
5
  SHA512:
6
- metadata.gz: 8d9959de1a83620f7fe43400886c7be11e0ca7250d04095861173c9e270883f377087068c106c6b65af35fe28db07e0cb96f2f9f6da9243ce74f5569c9d0e1f1
7
- data.tar.gz: 6d1ea2931b01f1136154cb20ff9c3da158802de5e1f6b6e8712b02f8481ea2bac4292107acabcf490b03957e37b1c75591b1e57b27d5f8d1c48c2e274858d019
6
+ metadata.gz: 38ca0fdcccc8aae776e1ee39841e7cc8213818393365255f1e8318a4802f8a8a8610f2f1d2a4194fc7ef49bf934fc658b3c6d1d579f2ebe23577d83e56e745e5
7
+ data.tar.gz: 4d8c1b10ddff2739acef72610875a0c22bae11231e741407ffab2f0bef7ba80c9e68119d3d4853caac8e9236613721b3bcd74701935c1a2d4bc0abbe368dae0e
@@ -5,6 +5,11 @@ This CHANGELOG follows the format listed [here](https://github.com/sensu-plugins
5
5
 
6
6
  ## [Unreleased]
7
7
 
8
+ ## [2.1.1] - 2018-03-28
9
+ ### Fixed
10
+ - (metrics-strongswan.rb, metrics-strongswan-connection.rb) Fixed bug with regexp (@yuri-zubov)
11
+
12
+
8
13
  ## [2.1.0] - 2018-03-17
9
14
  ### Added
10
15
  - Added ability to check all existing connection and get metrics from all connections (@yuri-zubov)
@@ -54,7 +59,8 @@ This CHANGELOG follows the format listed [here](https://github.com/sensu-plugins
54
59
  ### Added
55
60
  - add check-strongswan.rb and metrics-strongswan.rb plugins
56
61
 
57
- [Unreleased]: https://github.com/sensu-plugins/sensu-plugins-strongswan/compare/2.1.0...HEAD
62
+ [Unreleased]: https://github.com/sensu-plugins/sensu-plugins-strongswan/compare/2.1.1...HEAD
63
+ [2.1.1]: https://github.com/sensu-plugins/sensu-plugins-strongswan/compare/2.1.0...2.1.1
58
64
  [2.1.0]: https://github.com/sensu-plugins/sensu-plugins-strongswan/compare/2.0.0...2.1.0
59
65
  [2.0.0]: https://github.com/sensu-plugins/sensu-plugins-strongswan/compare/1.2.0...2.0.0
60
66
  [1.2.0]: https://github.com/sensu-plugins/sensu-plugins-strongswan/compare/1.1.0...1.2.0
@@ -48,13 +48,13 @@ class CheckStrongswanConnection < Sensu::Plugin::Check::CLI
48
48
  connection_names = Set.new
49
49
  established_connection_name = Set.new
50
50
  ipsec_status.each_line do |line|
51
- if line.match(/^Connections:/) .. line.match(/^Security Associations/)
52
- result = line.match(/^(?<name>(.*)):.*local/)
51
+ if line.match(/^Connections:/) .. line.match(/^Security Associations|Routed Connections/)
52
+ result = line.match(/^[[:space:]]*(?<name>(.*?)): .*TUNNEL/)
53
53
  connection_names << result[:name] if result
54
54
  end
55
55
 
56
56
  if line.match(/^Security Associations/) .. false
57
- result = line.match(/^(?<name>(.*))\{.*INSTALLED, TUNNEL,/)
57
+ result = line.match(/^[[:space:]]*(?<name>(.*?))\{.*INSTALLED, TUNNEL,/)
58
58
  established_connection_name << result[:name] if result
59
59
  end
60
60
  end
@@ -54,7 +54,7 @@ class MetricsStrongswanStrongswanConnection < Sensu::Plugin::Metric::CLI::Graphi
54
54
 
55
55
  found = false
56
56
  ipsec_status.each_line do |line|
57
- result = line.match(/(?<name>.*)\{.* (?<bytes_i>\d+)\ bytes_i.*\ (?<bytes_o>\d+)\ bytes_o/)
57
+ result = line.match(/[[:space:]]*(?<name>.*?)\{.* (?<bytes_i>\d+)\ bytes_i.*\ (?<bytes_o>\d+)\ bytes_o/)
58
58
  next unless result
59
59
 
60
60
  found = true
@@ -2,7 +2,7 @@ module SensuPluginsStrongswan
2
2
  module Version
3
3
  MAJOR = 2
4
4
  MINOR = 1
5
- PATCH = 0
5
+ PATCH = 1
6
6
 
7
7
  VER_STRING = [MAJOR, MINOR, PATCH].compact.join('.')
8
8
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sensu-plugins-strongswan
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sensu-Plugins and contributors
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-03-17 00:00:00.000000000 Z
11
+ date: 2018-03-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sensu-plugin