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 +4 -4
- data/README.md +3 -3
- data/lib/pwn/plugins/jira_server.rb +10 -5
- data/lib/pwn/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: af46a593739423417d1dd15c931f7f37c55ed52926549f004968d546e7586205
|
4
|
+
data.tar.gz: 8692d44970df90db4f6a93a14918b7af5ef77fa10082e3f222431ce8b0ab230f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
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.
|
40
|
+
pwn[v0.5.299]:001 >>> PWN.help
|
41
41
|
```
|
42
42
|
|
43
43
|
[](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.
|
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.
|
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 = {
|
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.
|
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.
|
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