netsnmp 0.6.3 → 0.6.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ff50c7291ee08e73da4c20435990ba7d4699a0489bbb454beb0577184988e865
4
- data.tar.gz: 77e25540c9816c6c92e8c2783a276426149a468a9ea9c8f21130f260bbfcc1ce
3
+ metadata.gz: 3349a60dfb4bd19c4ae8b1f1f0ad76638ab3e384ed4d03419ddc71ab4770ada7
4
+ data.tar.gz: 54c2d8c1414abff53cdd3687a69265447d24923ad3ee5dfd97f0e4395257696c
5
5
  SHA512:
6
- metadata.gz: b6b15908f819e3363ebb80d8bb556256025f8ef560abf796336b675cd22e487e5cc65f985ef993e771733dcc738d8b73625e124a2e3b42866bdb743fb9848e46
7
- data.tar.gz: 9886d5aa5a0de7bbb8f71b1ef8a9eb9aacf29faa5363b09362b1ebb78ad6de8075a60251d2b0891d18fd7f1c6fa6d05a4ba20c91da55eeace0837f3d8a7d4437
6
+ metadata.gz: 48d7735ee7785d200a27318df71a8f60cc25fb7b9902c203471768b0f8da4333faf4a304eb8c23ff44f6a11c7e08e74c76afe7a993470c938d24af47576d34cf
7
+ data.tar.gz: 557778f9e177cff84382ffcbae103d0245f6ece90f8169e41b3dffdbd7f6a505630d7ff9ace61980765824b2c5554ee5ca71f9d7bca0792933dc91dbed1abf02
@@ -3,7 +3,7 @@
3
3
  module NETSNMP
4
4
  module Loggable
5
5
  DEBUG = ENV.key?("NETSNMP_DEBUG") ? $stderr : nil
6
- DEBUG_LEVEL = (ENV["NETSNMP_DEBUG"] || 1).to_i
6
+ DEBUG_LEVEL = ENV.fetch("NETSNMP_DEBUG", 1).to_i
7
7
 
8
8
  def initialize_logger(debug: DEBUG, debug_level: DEBUG_LEVEL, **)
9
9
  @debug = debug
@@ -131,9 +131,13 @@ module NETSNMP
131
131
  # https://datatracker.ietf.org/doc/html/rfc7860#section-4.2.2 part 3
132
132
  # https://datatracker.ietf.org/doc/html/rfc3414#section-6.3.2 part 3
133
133
  def authnone(auth_protocol)
134
+ # https://datatracker.ietf.org/doc/html/rfc3414#section-3.1 part 8b
135
+ return OpenSSL::ASN1::OctetString.new("").with_label(:auth_mask) unless auth_protocol
136
+
134
137
  # The digest in the msgAuthenticationParameters field is replaced by the 12 zero octets.
135
138
  # 24 octets for sha256
136
139
  number_of_octets = auth_protocol == :sha256 ? 24 : 12
140
+
137
141
  OpenSSL::ASN1::OctetString.new("\x00" * number_of_octets).with_label(:auth_mask)
138
142
  end
139
143
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module NETSNMP
4
- VERSION = "0.6.3"
4
+ VERSION = "0.6.4"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: netsnmp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.6.3
4
+ version: 0.6.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tiago Cardoso
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-04-04 00:00:00.000000000 Z
11
+ date: 2022-05-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: parslet