pwn 0.5.298 → 0.5.299

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: be4a660a466617ce369499193c9480e167218321a3228cf93c330b7524f1b447
4
- data.tar.gz: 005c66a5e7324753917f9af6e0928234348363e7b4e21afeef011e25fc3692aa
3
+ metadata.gz: af46a593739423417d1dd15c931f7f37c55ed52926549f004968d546e7586205
4
+ data.tar.gz: 8692d44970df90db4f6a93a14918b7af5ef77fa10082e3f222431ce8b0ab230f
5
5
  SHA512:
6
- metadata.gz: 35a10cb79b1cc2758faad2d95932e75b261993e0d6463fee4ecd3cc1213b0e94e8ab99ef1a03fb897c100986d8546c60925dd2f14bcd7718d87a1086199c4dad
7
- data.tar.gz: e23f6cb197d77102e5bc19007c7d3bd06c38284f163b678c43d4e8e6a8ca9167dd53dd6e893a63273a591822067f5f312f612a0dca3316a42d92c30441191ff6
6
+ metadata.gz: 8836abe59e41a4cca98606832090f847cc3b4882b3009fd758745ec4743eda1f09464c0a06182f1761d136be8689b6fdc644d2a6a4d01ca6a0457f0ac4bb6eff
7
+ data.tar.gz: 1297d4272044241237fc52d22a8bd6d00e9c9e39e67e9144685bf387819be86e3df1f9695fc5a3ef464502c57a2ed8ad75f54129695343d923dccec84ad93cfe
data/README.md CHANGED
@@ -37,7 +37,7 @@ $ cd /opt/pwn
37
37
  $ ./install.sh
38
38
  $ ./install.sh ruby-gem
39
39
  $ pwn
40
- pwn[v0.5.298]:001 >>> PWN.help
40
+ pwn[v0.5.299]: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.4.4@pwn
52
52
  $ gem uninstall --all --executables pwn
53
53
  $ gem install --verbose pwn
54
54
  $ pwn
55
- pwn[v0.5.298]:001 >>> PWN.help
55
+ pwn[v0.5.299]:001 >>> PWN.help
56
56
  ```
57
57
 
58
58
  If you're using a multi-user install of RVM do:
@@ -62,7 +62,7 @@ $ rvm use ruby-3.4.4@pwn
62
62
  $ rvmsudo gem uninstall --all --executables pwn
63
63
  $ rvmsudo gem install --verbose pwn
64
64
  $ pwn
65
- pwn[v0.5.298]:001 >>> PWN.help
65
+ pwn[v0.5.299]:001 >>> PWN.help
66
66
  ```
67
67
 
68
68
  PWN periodically upgrades to the latest version of Ruby which is reflected in `/opt/pwn/.ruby-version`. The easiest way to upgrade to the latest version of Ruby from a previous PWN installation is to run the following script:
@@ -148,7 +148,8 @@ module PWN
148
148
  # user = PWN::Plugins::JiraServer.get_user(
149
149
  # base_api_uri: 'required - base URI for Jira (e.g. https:/jira.corp.com/rest/api/latest)',
150
150
  # token: 'required - personal access token',
151
- # username: 'required - username to lookup (e.g. jane.doe)'
151
+ # username: 'required - username to lookup (e.g. jane.doe)',
152
+ # params: 'optional - additional parameters to pass in the URI (e.g. expand, etc.)'
152
153
  # )
153
154
 
154
155
  public_class_method def self.get_user(opts = {})
@@ -162,7 +163,10 @@ module PWN
162
163
  username = opts[:username]
163
164
  raise 'ERROR: username cannot be nil.' if username.nil?
164
165
 
165
- params = { username: username }
166
+ params = { key: username }
167
+ additional_params = opts[:params]
168
+
169
+ params.merge!(additional_params) if additional_params.is_a?(Hash)
166
170
 
167
171
  rest_call(
168
172
  base_api_uri: base_api_uri,
@@ -276,7 +280,7 @@ module PWN
276
280
 
277
281
  http_body = {
278
282
  multipart: true,
279
- file: attachments.map { |attachment| File.new(attachment, 'rb') }
283
+ file: attachments.map { |attachment| File.binread(attachment) }
280
284
  }
281
285
 
282
286
  rest_call(
@@ -329,7 +333,7 @@ module PWN
329
333
  if attachments.any?
330
334
  http_body = {
331
335
  multipart: true,
332
- file: attachments.map { |attachment| File.new(attachment, 'rb') }
336
+ file: attachments.map { |attachment| File.binread(attachment) }
333
337
  }
334
338
 
335
339
  rest_call(
@@ -395,7 +399,8 @@ module PWN
395
399
  user = #{self}.get_user(
396
400
  base_api_uri: 'required - base URI for Jira (e.g. https:/jira.corp.com/rest/api/latest)',
397
401
  token: 'required - personal access token',
398
- username: 'required - username to lookup (e.g. jane.doe')'
402
+ username: 'required - username to lookup (e.g. jane.doe')',
403
+ params: 'optional - additional parameters to pass in the URI (e.g. expand, etc.)'
399
404
  )
400
405
 
401
406
  issue_resp = #{self}.get_issue(
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.5.298'
4
+ VERSION = '0.5.299'
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.5.298
4
+ version: 0.5.299
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.