pwn 0.4.734 → 0.4.735

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: c5f460760589e0c081afe01205d7d24891656dbff6558679ac284487f84084bc
4
- data.tar.gz: 56de2d97a21b51bf923510b3f58f28496655bdd371828fda5d0c1fe7fe106d6e
3
+ metadata.gz: 91ea0aaa9a3d3f2f0e7e6a38c58a4199bd770cf7784486cc59e99e4add3ec9c3
4
+ data.tar.gz: c047b603b26553c23b13ac4e4c856a11556908f1020d3d6bd5b4160d380a0b9d
5
5
  SHA512:
6
- metadata.gz: 7b6a29b4149b52f3b2341b4c85eff17280eb13739a4cb8ff4fa58286b1331d199711e03a8b63d89100581135b38e9271ed4e099c0305f28e1a129b3fc9a4cd6a
7
- data.tar.gz: 9347646e9f559feb861627144722b2eb34ead3ed71d5f62a4ae88d1187d31aa5f3306188662eea797ee2cfc224573692d08e3f50159bb3076bb4717697c628a7
6
+ metadata.gz: 45e128055e6a8bf97a62d2c9dae4cfe44589648ed297d677df52142bec308c83f0416a8ce19f500ab20113955a666bee8ebf56408770e3e83f6746f2f27654e6
7
+ data.tar.gz: 11cdcd0233d414543d90e85b6c78d51b9af6e1de24b6b1e8f95ba66d251d3d1448d66f3330f0f622b991b655625002e52c29491b6c26c33b7e25d5a4fab3dd3f
data/README.md CHANGED
@@ -37,7 +37,7 @@ $ rvm use ruby-3.2.2@pwn
37
37
  $ rvm list gemsets
38
38
  $ gem install --verbose pwn
39
39
  $ pwn
40
- pwn[v0.4.734]:001 >>> PWN.help
40
+ pwn[v0.4.735]:001 >>> PWN.help
41
41
  ```
42
42
 
43
43
  [![Installing the pwn Security Automation Framework](https://raw.githubusercontent.com/0dayInc/pwn/master/documentation/pwn_install.png)](https://youtu.be/G7iLUY4FzsI)
@@ -52,7 +52,7 @@ $ rvm use ruby-3.2.2@pwn
52
52
  $ gem uninstall --all --executables pwn
53
53
  $ gem install --verbose pwn
54
54
  $ pwn
55
- pwn[v0.4.734]:001 >>> PWN.help
55
+ pwn[v0.4.735]:001 >>> PWN.help
56
56
  ```
57
57
 
58
58
 
@@ -29,6 +29,13 @@ module PWN
29
29
  end
30
30
  rest_call = opts[:rest_call].to_s.scrub
31
31
  params = opts[:params]
32
+
33
+ headers = opts[:http_headers]
34
+ headers ||= {
35
+ content_type: content_type,
36
+ authorization: "Bearer #{token}"
37
+ }
38
+
32
39
  http_body = opts[:http_body]
33
40
  base_bd_bin_analysis_api_uri = 'https://protecode-sc.com/api'
34
41
  token = opts[:token]
@@ -43,12 +50,7 @@ module PWN
43
50
 
44
51
  case http_method
45
52
  when :delete, :get
46
- headers = opts[:http_headers]
47
- headers ||= {
48
- content_type: content_type,
49
- authorization: "Bearer #{token}",
50
- params: params
51
- }
53
+ headers[:params] = params
52
54
  response = rest_client.execute(
53
55
  method: http_method,
54
56
  url: "#{base_bd_bin_analysis_api_uri}/#{rest_call}",
@@ -57,10 +59,6 @@ module PWN
57
59
  )
58
60
 
59
61
  when :post, :put
60
- headers = opts[:http_headers]
61
- headers ||= {
62
- authorization: "Bearer #{token}"
63
- }
64
62
  response = rest_client.execute(
65
63
  method: :post,
66
64
  url: "#{base_bd_bin_analysis_api_uri}/#{rest_call}",
data/lib/pwn/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module PWN
4
- VERSION = '0.4.734'
4
+ VERSION = '0.4.735'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pwn
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.734
4
+ version: 0.4.735
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.