pwn 0.5.191 → 0.5.192
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +3 -3
- data/lib/pwn/plugins/transparent_browser.rb +11 -8
- 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: 943acf516461b6defab89c118dce50021fbe4a54149e383cb94be08570cb4735
|
4
|
+
data.tar.gz: 88ed9ddeec7d76c97a0b4665b26d14db609b9a820786905ab81a2d1f9115f65b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 15fea999df3f0b8f05358f285980cf34851d3dde2992e325f8b1cc3d550be9e24a18fe78a7147531d811992f8b15b9ef2e89300cade9d9873534addc513ecd65
|
7
|
+
data.tar.gz: 13f05cebbee3ddd043f8f397a733a78daa7e8aa1efae393659d2e8f9bd493cc940bcea1d953fd2bcebeaece47eb29f9abad9184f41ce5a3b587e6285a981beb0
|
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.192]: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.3.3@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.192]: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.3.3@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.192]: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:
|
@@ -41,7 +41,7 @@ module PWN
|
|
41
41
|
# browser_obj1 = PWN::Plugins::TransparentBrowser.open(
|
42
42
|
# browser_type: 'optional - :firefox|:chrome|:headless|:rest|:websocket (defaults to :chrome)',
|
43
43
|
# proxy: 'optional - scheme://proxy_host:port || tor (defaults to nil)',
|
44
|
-
#
|
44
|
+
# devtools: 'optional - boolean (defaults to true)',
|
45
45
|
# url: 'optional - URL to navigate to after opening browser (Defaults to about:about#RANDID)'
|
46
46
|
# )
|
47
47
|
|
@@ -60,8 +60,8 @@ module PWN
|
|
60
60
|
end
|
61
61
|
|
62
62
|
devtools_supported = %i[chrome headless_chrome firefox headless_firefox headless]
|
63
|
-
|
64
|
-
|
63
|
+
devtools = opts[:devtools] ||= false
|
64
|
+
devtools = true if devtools_supported.include?(browser_type) && devtools
|
65
65
|
|
66
66
|
url = opts[:url] ||= "about:about##{SecureRandom.hex(8)}"
|
67
67
|
|
@@ -130,7 +130,7 @@ module PWN
|
|
130
130
|
end
|
131
131
|
end
|
132
132
|
|
133
|
-
args.push('--devtools') if
|
133
|
+
args.push('--devtools') if devtools
|
134
134
|
options = Selenium::WebDriver::Firefox::Options.new(
|
135
135
|
args: args,
|
136
136
|
accept_insecure_certs: true
|
@@ -151,7 +151,7 @@ module PWN
|
|
151
151
|
args.push("--proxy-server=#{proxy}")
|
152
152
|
end
|
153
153
|
|
154
|
-
if
|
154
|
+
if devtools
|
155
155
|
args.push('--auto-open-devtools-for-tabs')
|
156
156
|
args.push('--disable-hang-monitor')
|
157
157
|
end
|
@@ -258,6 +258,7 @@ module PWN
|
|
258
258
|
browser_obj[:browser].proxy = proxy
|
259
259
|
end
|
260
260
|
end
|
261
|
+
puts browser_obj[:browser].get(url).body if url
|
261
262
|
|
262
263
|
when :websocket
|
263
264
|
if proxy
|
@@ -285,10 +286,10 @@ module PWN
|
|
285
286
|
|
286
287
|
if devtools_supported.include?(browser_type)
|
287
288
|
rand_tab = SecureRandom.hex(8)
|
288
|
-
browser_obj[:browser].goto(
|
289
|
+
browser_obj[:browser].goto(url)
|
289
290
|
browser_obj[:browser].execute_script("document.title = '#{rand_tab}'")
|
290
291
|
|
291
|
-
if
|
292
|
+
if devtools
|
292
293
|
driver = browser_obj[:browser].driver
|
293
294
|
browser_obj[:devtools] = driver.devtools
|
294
295
|
|
@@ -308,6 +309,7 @@ module PWN
|
|
308
309
|
|
309
310
|
browser_obj[:bidi] = driver.bidi
|
310
311
|
|
312
|
+
jmp_devtools_panel(browser_obj: browser_obj, panel: :elements)
|
311
313
|
browser_obj[:browser].send_keys(:escape)
|
312
314
|
end
|
313
315
|
end
|
@@ -703,6 +705,7 @@ module PWN
|
|
703
705
|
end
|
704
706
|
|
705
707
|
# Have to call twice for Chrome, otherwise devtools stays closed
|
708
|
+
browser.body.click
|
706
709
|
browser.send_keys(hotkey)
|
707
710
|
browser.send_keys(hotkey) if chrome_types.include?(browser_type)
|
708
711
|
rescue StandardError => e
|
@@ -747,7 +750,7 @@ module PWN
|
|
747
750
|
browser_obj1 = #{self}.open(
|
748
751
|
browser_type: 'optional - :firefox|:chrome|:headless|:rest|:websocket (defaults to :chrome)',
|
749
752
|
proxy: 'optional scheme://proxy_host:port || tor (defaults to nil)',
|
750
|
-
|
753
|
+
devtools: 'optional - boolean (defaults to true)'
|
751
754
|
)
|
752
755
|
browser = browser_obj1[:browser]
|
753
756
|
puts browser.public_methods
|
data/lib/pwn/version.rb
CHANGED