pwn 0.4.850 → 0.4.852
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 +2 -2
- data/lib/pwn/version.rb +1 -1
- data/lib/pwn/www/hacker_one.rb +18 -6
- 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: 3620da462f7410a561287b4a8f26a68a3ca44b672535c13a13a8431cff258032
|
|
4
|
+
data.tar.gz: 6d1533199b589d331b6c8981ddf891c144c87a9898ead53b9add03b4a4d898b1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 41bf3efbd2ac76a88e1d9289fb1cdefd0338e70b3cc0abef44f1a3811feb43e7e3a6a0f3e25e0ad353233b1303e00aacd43ede7e283933b8e92381d6abecf84c
|
|
7
|
+
data.tar.gz: e65b0ac37ca3fa7db3ff89ec5b3327af4d4e678e1c05af107d59ecb8d0110a71f5f17840e9c5fc61ba6b2f3a7b45355055719bfea1bece9279a3adf9c43d8067
|
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.
|
|
40
|
+
pwn[v0.4.852]:001 >>> PWN.help
|
|
41
41
|
```
|
|
42
42
|
|
|
43
43
|
[](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.
|
|
55
|
+
pwn[v0.4.852]:001 >>> PWN.help
|
|
56
56
|
```
|
|
57
57
|
|
|
58
58
|
|
data/lib/pwn/version.rb
CHANGED
data/lib/pwn/www/hacker_one.rb
CHANGED
|
@@ -26,12 +26,15 @@ module PWN
|
|
|
26
26
|
# Supported Method Parameters::
|
|
27
27
|
# bb_prograns_arr = PWN::WWW::HackerOne.get_bounty_programs(
|
|
28
28
|
# browser_obj: 'required - browser_obj returned from #open method',
|
|
29
|
-
# proxy: 'optional - scheme://proxy_host:port || tor'
|
|
29
|
+
# proxy: 'optional - scheme://proxy_host:port || tor',
|
|
30
|
+
# min_payouts_enabled: 'optional - only display programs where payouts are > $0.00 (defaults to false)'
|
|
30
31
|
# )
|
|
31
32
|
|
|
32
33
|
public_class_method def self.get_bounty_programs(opts = {})
|
|
33
34
|
browser_obj = opts[:browser_obj]
|
|
34
35
|
browser = browser_obj[:browser]
|
|
36
|
+
min_payouts_enabled = true if opts[:min_payouts_enabled]
|
|
37
|
+
min_payouts_enabled ||= false
|
|
35
38
|
|
|
36
39
|
browser.goto('https://hackerone.com/bug-bounty-programs')
|
|
37
40
|
# Wait for JavaScript to load the DOM
|
|
@@ -39,15 +42,23 @@ module PWN
|
|
|
39
42
|
bb_programs_arr = []
|
|
40
43
|
browser.ul(class: 'program__meta-data').wait_until(&:present?)
|
|
41
44
|
browser.uls(class: 'program__meta-data').each do |ul|
|
|
42
|
-
|
|
45
|
+
min_payout = ul.text.split('$').last.split.first.to_f
|
|
46
|
+
|
|
47
|
+
next if min_payouts_enabled && min_payout.zero?
|
|
43
48
|
|
|
49
|
+
print '.'
|
|
44
50
|
link = ul.first.text
|
|
45
|
-
|
|
51
|
+
min_payout_fmt = format('$%0.2f', min_payout)
|
|
46
52
|
|
|
47
53
|
bounty_program_hash = {
|
|
48
54
|
name: link.split('/').last,
|
|
49
|
-
min_payout:
|
|
50
|
-
|
|
55
|
+
min_payout: min_payout_fmt,
|
|
56
|
+
policy: "#{link}?view_policy=true",
|
|
57
|
+
scope: "#{link}/policy_scopes",
|
|
58
|
+
hacktivity: "#{link}/hacktivity",
|
|
59
|
+
thanks: "#{link}/thanks",
|
|
60
|
+
updates: "#{link}/updates",
|
|
61
|
+
collaborators: "#{link}/collaborators"
|
|
51
62
|
}
|
|
52
63
|
bb_programs_arr.push(bounty_program_hash)
|
|
53
64
|
end
|
|
@@ -140,7 +151,8 @@ module PWN
|
|
|
140
151
|
|
|
141
152
|
bb_prograns_arr = #{self}.get_bounty_programs(
|
|
142
153
|
browser_obj: 'required - browser_obj returned from #open method',
|
|
143
|
-
proxy: 'optional - scheme://proxy_host:port || tor'
|
|
154
|
+
proxy: 'optional - scheme://proxy_host:port || tor',
|
|
155
|
+
min_payouts_enabled: 'optional - only display programs where payouts are > $0.00 (defaults to false)'
|
|
144
156
|
)
|
|
145
157
|
|
|
146
158
|
browser_obj = #{self}.login(
|