pwn 0.5.172 → 0.5.174

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: 7a28028e7963e92af030938974180fd92e06a97a26356b503605587d62d5c70b
4
- data.tar.gz: e6d967fd284c4bde42b12430d247033814e1c3d3cc6a160cf66bee3b902991ff
3
+ metadata.gz: 2941eb1a5d3b51c3c5ca5b577a3c672076c4aba487b56fe53c8ccf2c81de4618
4
+ data.tar.gz: 7781e6c421ae89bb944bb93c44d0613bc76863c5bf9810f86f669b0393c3e698
5
5
  SHA512:
6
- metadata.gz: 68abce7493b7babaa9f2265da24497f9a3d521d1d608098426db9b9288104c4aa2def7c1a35be2ff3a58d46fa2e0e36b0638d5c323f796b51a77c53d81947009
7
- data.tar.gz: 0db2a7cb852145907eec23779ded6cdaeb9286a9bdbf0847b81b02dde64536c2cf119ae5a8b7da13958d0bd85a53afe0672962f5fc19d2b9dd0fcc67757ab108
6
+ metadata.gz: ba0704805b057c2a875280faf0acaf39e3bc15971fbf37b7ba7f088877b9dbe3c8959b12ac48f2c44cf314caf5940bca00241d543e0d4efb6c224cb1fb32fdc7
7
+ data.tar.gz: 5500bdff4b838fb34fa89d4b8c24fb0e8780e65c98cfe15ba80d92ee0dc755af5fe6cea18c8ef300ce1ae186805a02d8bbe12ffe010000e1efc9936b75160d07
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.172]:001 >>> PWN.help
40
+ pwn[v0.5.174]: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.172]:001 >>> PWN.help
55
+ pwn[v0.5.174]: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.172]:001 >>> PWN.help
65
+ pwn[v0.5.174]: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:
@@ -25,11 +25,11 @@ module PWN
25
25
  # Supported Method Parameters::
26
26
  # verify_devtools_browser(
27
27
  # browser_obj: 'required - browser_obj returned from #open method',
28
- # supported: 'optional - array of supported browser types (defaults to [:chrome, :headless_chrome, :firefox, :headless_firefox])'
28
+ # supported: 'optional - array of supported browser types (defaults to [:chrome, :headless_chrome, :firefox, :headless_firefox, :headless])'
29
29
  # )
30
30
  private_class_method def self.verify_devtools_browser(opts = {})
31
31
  browser_obj = opts[:browser_obj]
32
- supported = opts[:supported] ||= %i[chrome headless_chrome firefox headless_firefox]
32
+ supported = opts[:supported] ||= %i[chrome headless_chrome firefox headless_firefox headless]
33
33
 
34
34
  browser_type = browser_obj[:type]
35
35
  raise "ERROR: browser_type must be #{supported}" unless supported.include?(browser_type)
@@ -130,8 +130,9 @@ module PWN
130
130
  args: args,
131
131
  accept_insecure_certs: true
132
132
  )
133
+
134
+ options.web_socket_url = true
133
135
  options.profile = this_profile
134
- # driver = Selenium::WebDriver.for(:firefox, capabilities: options)
135
136
  driver = Selenium::WebDriver.for(:firefox, options: options)
136
137
  browser_obj[:browser] = Watir::Browser.new(driver)
137
138
 
@@ -155,8 +156,8 @@ module PWN
155
156
  accept_insecure_certs: true
156
157
  )
157
158
 
159
+ options.web_socket_url = true
158
160
  options.profile = this_profile
159
- # driver = Selenium::WebDriver.for(:chrome, capabilities: options)
160
161
  driver = Selenium::WebDriver.for(:chrome, options: options)
161
162
  browser_obj[:browser] = Watir::Browser.new(driver)
162
163
 
@@ -218,6 +219,7 @@ module PWN
218
219
  accept_insecure_certs: true
219
220
  )
220
221
 
222
+ options.web_socket_url = true
221
223
  options.profile = this_profile
222
224
  driver = Selenium::WebDriver.for(:firefox, options: options)
223
225
  browser_obj[:browser] = Watir::Browser.new(driver)
@@ -239,6 +241,7 @@ module PWN
239
241
  accept_insecure_certs: true
240
242
  )
241
243
 
244
+ options.web_socket_url = true
242
245
  options.profile = this_profile
243
246
  driver = Selenium::WebDriver.for(:chrome, options: options)
244
247
  browser_obj[:browser] = Watir::Browser.new(driver)
@@ -279,13 +282,14 @@ module PWN
279
282
  end
280
283
 
281
284
  browser_type = browser_obj[:type]
282
- supported = %i[chrome headless_chrome firefox headless_firefox]
285
+ supported = %i[chrome headless_chrome firefox headless_firefox headless]
283
286
  if with_devtools && supported.include?(browser_type)
284
287
  browser_obj[:browser].goto('about:blank')
285
288
  rand_tab = SecureRandom.hex(8)
286
289
  browser_obj[:browser].execute_script("document.title = '#{rand_tab}'")
287
290
 
288
291
  browser_obj[:devtools] = browser_obj[:browser].driver.devtools
292
+ browser_obj[:bidi] = browser_obj[:browser].driver.bidi
289
293
 
290
294
  # browser_obj[:devtools].send_cmd('DOM.enable')
291
295
  # browser_obj[:devtools].send_cmd('Log.enable')
@@ -523,7 +527,7 @@ module PWN
523
527
 
524
528
  case action.to_s.downcase.to_sym
525
529
  when :pause
526
- console('browser_obj': browser_obj, js: 'debugger')
530
+ console(browser_obj: browser_obj, js: 'debugger')
527
531
 
528
532
  # devtools.send_cmd('Debugger.enable')
529
533
  # devtools.send_cmd(
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.172'
4
+ VERSION = '0.5.174'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pwn
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.172
4
+ version: 0.5.174
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-06-21 00:00:00.000000000 Z
11
+ date: 2024-06-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport