qualys 0.1.3 → 0.1.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
  SHA1:
3
- metadata.gz: e957c9f5a99607890d0f0c19e0e0cf76518a8a71
4
- data.tar.gz: 87dbbf0f630a150cc16d177c9c7a1e07e585fa24
3
+ metadata.gz: ac602898aecbc4ee66fe92c1bcb23cebe9bf745c
4
+ data.tar.gz: 57bb46bc7f9f685085252481c6beb1190446775a
5
5
  SHA512:
6
- metadata.gz: 2cba8be57e2c3d8dcf4a40139baf178f09f7e084d3c3aa2b5a9ecb3ffe3c766f0e14229dfca580c605b4e821c96ed6a548a09c6905e55f69f080c118b801989b
7
- data.tar.gz: ec85b2412fb86b9150b3d0f5e84c3dd6b11a2f6295fd88f1185c558d6a0825b21e71502b9b9af4082ab11be9e88c4deab9b2bf585cdd32e2fd08106e058dbb62
6
+ metadata.gz: ce3ecaaa399130b1d9b4d38b8321401b510f2cd729062dcc50758255b379be3097f3945335ca0d7fb8d2eb70801c320c7f5b3c5fe49e5f0be0be6126159c107b
7
+ data.tar.gz: 06c36c291e5aa06c2d0ba59581af9dcd1c229be65da84ce07dc1ccfade804668202e75fec8e044e216ca8a5c5b1d2c008ce408cda75bc7ad03ff00bd9c60afd6
data/README.md CHANGED
@@ -1,7 +1,7 @@
1
1
  # Ruby Qualys API v2
2
2
  A Ruby extension for interfacing with Qualys v2 API.
3
3
 
4
- [![](http://ruby-gem-downloads-badge.herokuapp.com/qualys)](https://rubygems.org/gems/qualys)
4
+ [![](http://ruby-gem-downloads-badge.herokuapp.com/qualys?type=total)](https://rubygems.org/gems/qualys)
5
5
 
6
6
  [![Dependency Status](https://gemnasium.com/mikemackintosh/ruby-qualys.svg)](https://gemnasium.com/mikemackintosh/ruby-qualys)
7
7
 
@@ -38,7 +38,13 @@ or configure using a `yaml` doc:
38
38
  ```ruby
39
39
  Qualys::Config.load!("config/qualys.yaml")
40
40
  ```
41
+ ### Login
41
42
 
43
+ Login before making other API calls:
44
+
45
+ ```ruby
46
+ Qualys::Auth.login
47
+ ```
42
48
  ### Getting Scans
43
49
 
44
50
  You can easily get a list of all scans within your Qualys account by accessing the following methods:
@@ -58,9 +64,19 @@ puts scans.first.details
58
64
  # {"ip"=>"x.x.x.x, "dns"=>"mikemackintosh.com", "netbios"=>nil, "qid"=>86001, "result"=>"Server Version\tServer Banner\nnginx\tnginx", "protocol"=>"tcp", "port"=>"443", "ssl"=>"no", "fqdn"=>""}
59
65
  ```
60
66
 
67
+
68
+ ### Set the URI
69
+
70
+ If your URL differs from the default, set it using:
71
+
72
+ ```ruby
73
+ Qualys::Api.base_uri = OTHER_PRODUCTION_ENDPOINT
74
+ ```
75
+
76
+
61
77
  ## References
62
78
 
63
79
  The API was built using the following documentation:
64
80
 
65
81
  - https://www.qualys.com/docs/qualys-api-v2-quick-reference.pdf
66
- - https://www.qualys.com/docs/qualys-api-v2-user-guide.pdf?_ga=1.246313805.857253578.1427813387
82
+ - https://www.qualys.com/docs/qualys-api-v2-user-guide.pdf?_ga=1.246313805.857253578.1427813387
@@ -62,5 +62,10 @@ module Qualys
62
62
  response
63
63
  end
64
64
 
65
+ #
66
+ # Sets the base URI.
67
+ def self.base_uri=(base_uri)
68
+ HTTParty::Basement.default_options.update(base_uri: base_uri)
69
+ end
65
70
  end
66
71
  end
@@ -1,3 +1,3 @@
1
1
  module Qualys
2
- VERSION = '0.1.3'
3
- end
2
+ VERSION = '0.1.4'
3
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: qualys
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Mackintosh
@@ -180,7 +180,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
180
180
  version: '0'
181
181
  requirements: []
182
182
  rubyforge_project:
183
- rubygems_version: 2.2.2
183
+ rubygems_version: 2.6.11
184
184
  signing_key:
185
185
  specification_version: 4
186
186
  summary: qualys API Client