nexpose 1.3.0 → 2.0.0

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
  SHA1:
3
- metadata.gz: beab7077de1b13a74723424d85b0c1b92763091f
4
- data.tar.gz: c662d6c50dff60831de0e8397001350215128624
3
+ metadata.gz: dda16614a7c92bd849c6706d4cffb1273bd1ee23
4
+ data.tar.gz: 0ead05096d3c51477afe8ade37212f5800ae70dc
5
5
  SHA512:
6
- metadata.gz: e8774a9048fbe64de1af8d0dd3fcefbf0a973208c2d3a7ebdc665b62bc2ca85a44575f799be46b545a2b03611e8c398c7a05a68f3b49f233c865504501463c56
7
- data.tar.gz: 2d0eaa7f7648314556fba63dcaa8670cd241ac03c885871edcab4275a8ef1a0d9602fbef1dcedf3f33635d0c9352b0c8b7882080a4a2408699ba46d8d1475d8c
6
+ metadata.gz: 4364d638e9c5619e15cc1b5db71864543230b292e136a047762acfc3f1de38e46372c2269ab81f4b4c318a85b11524632dd79ede786b22a765d1ff90c6bef66d
7
+ data.tar.gz: b0e835bfb6abcdf65deccff6888aa52921b526580d28c9e0c1f04108f4e34024363c1c3db2c812ea62535865e280acecf1c13aff3915a6829dc3cb191d296391
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- nexpose (1.3.0)
4
+ nexpose (2.0.0)
5
5
  rex (~> 2.0, >= 2.0.8)
6
6
 
7
7
  GEM
data/README.markdown CHANGED
@@ -9,6 +9,8 @@ Check out the [wiki](https://github.com/rapid7/nexpose-client/wiki) for walk-thr
9
9
 
10
10
  This gem is heavily used for internal, automated testing of the Nexpose product. It provides calls to the Nexpose XML APIs version 1.1 and 1.2, and JSON API 2.1. It also includes a number of helper methods which are not currently exposed through alternate means.
11
11
 
12
+ Since version 1.0 nexpose-client uses [Semantic Versioning](http://semver.org/). This allows for confident use of the [pessimistic operator](https://robots.thoughtbot.com/rubys-pessimistic-operator) in scripts or larger ruby projects.
13
+
12
14
  ## Release Notes
13
15
 
14
16
  Release notes are available on the [Releases](https://github.com/rapid7/nexpose-client/releases) page.
@@ -8,14 +8,16 @@ module Nexpose
8
8
  attr_accessor :capitals
9
9
  attr_accessor :digits
10
10
  attr_accessor :special_chars
11
+ attr_accessor :expiration_days
11
12
 
12
- def initialize(policy_name:, min_length:, max_length:, special_chars:, capitals:, digits:)
13
+ def initialize(policy_name:, min_length:, max_length:, special_chars:, capitals:, digits:, expiration_days: 0)
13
14
  @policy_name = policy_name.to_s
14
15
  @min_length = min_length.to_i
15
16
  @max_length = max_length.to_i
16
17
  @special_chars = special_chars.to_i
17
18
  @capitals = capitals.to_i
18
19
  @digits = digits.to_i
20
+ @expiration_days = expiration_days.to_i
19
21
  end
20
22
 
21
23
  def self.from_hash(hash)
@@ -24,7 +26,8 @@ module Nexpose
24
26
  max_length: hash[:maxLength],
25
27
  special_chars: hash[:specialChars],
26
28
  capitals: hash[:capitals],
27
- digits: hash[:digits])
29
+ digits: hash[:digits],
30
+ expiration_days: hash[:expirationDays])
28
31
  end
29
32
 
30
33
  def to_h
@@ -34,7 +37,8 @@ module Nexpose
34
37
  maxLength: @max_length,
35
38
  specialChars: @special_chars,
36
39
  capitals: @capitals,
37
- digits: @digits
40
+ digits: @digits,
41
+ expirationDays: @expiration_days
38
42
  }
39
43
  end
40
44
 
@@ -1,4 +1,4 @@
1
1
  module Nexpose
2
2
  # The latest version of the Nexpose gem
3
- VERSION = '1.3.0'
3
+ VERSION = '2.0.0'
4
4
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: nexpose
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.0
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - HD Moore
@@ -13,7 +13,7 @@ authors:
13
13
  autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
- date: 2015-07-07 00:00:00.000000000 Z
16
+ date: 2015-07-29 00:00:00.000000000 Z
17
17
  dependencies:
18
18
  - !ruby/object:Gem::Dependency
19
19
  name: rex