pwn 0.5.177 → 0.5.178

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: 04bc92c4ffca1af44436a1957189c0fe42ee982f85c25fd1238d1cd98b52239a
4
- data.tar.gz: 498dd344a71c735a629e95089a95eaf2883eed36bbe1dcc327fec2c16a337407
3
+ metadata.gz: 689a88328dd337da1e607c85cb033503df3bbe2befbb459b16efc670f975c2ff
4
+ data.tar.gz: 94e412420f5d9993bee9fc13dcaa33bc0233ca56810c5480a41ad8c62961d9b9
5
5
  SHA512:
6
- metadata.gz: bc0b4ce8d5f4965065f2f03835f271ad2272a3105e88fe134e503b55d7af294e72d25121374744fe84c717da029dd8d1a8498eef8c62914b8a1a8342d4ad86f8
7
- data.tar.gz: bfcd3f6b1065006c2644ea1a891f8e9a6023b3304c7d4540baabc1df5624a65468488f19a755b97c8d1989e991aca72adc1770848bbc60003d2f0ac2140e78a0
6
+ metadata.gz: 8bd37d169981b0c945c7b7636f14dc786af41f3b533fae618459f2ddf211430bed07634f8b2a75ab625f182c7964edae65149c681ac2e945e7ce67f39657cd2e
7
+ data.tar.gz: 90392a8941be9e0271e63618202a7692dcfec9085064e4ee3f52abd5be7a2d7be2f6c50bcfd23de263cfd55bd55d03da5377dc787eaa2c91d7d61476292635fe
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.177]:001 >>> PWN.help
40
+ pwn[v0.5.178]: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.177]:001 >>> PWN.help
55
+ pwn[v0.5.178]: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.177]:001 >>> PWN.help
65
+ pwn[v0.5.178]: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:
@@ -438,9 +438,9 @@ module PWN
438
438
 
439
439
  browser = browser_obj[:browser]
440
440
  browser.windows.map do |tab|
441
- active = false
442
- active = true if browser.title == tab.title && browser.url == tab.url
443
- { title: tab.title, url: tab.url, active: active }
441
+ state = :inactive
442
+ state = :active if browser.title == tab.title && browser.url == tab.url
443
+ { title: tab.title, url: tab.url, state: state }
444
444
  end
445
445
  rescue StandardError => e
446
446
  raise e
@@ -462,7 +462,7 @@ module PWN
462
462
  browser = browser_obj[:browser]
463
463
  all_tabs = browser.windows
464
464
  tab_sel = all_tabs.select { |tab| tab.use if tab.title.include?(keyword) || tab.url.include?(keyword) }
465
- { title: tab_sel.last.title, url: tab_sel.last.url, active: true } if tab_sel.any?
465
+ { title: tab_sel.last.title, url: tab_sel.last.url, state: :active } if tab_sel.any?
466
466
  rescue StandardError => e
467
467
  raise e
468
468
  end
@@ -486,7 +486,7 @@ module PWN
486
486
  browser.execute_script("document.title = '#{rand_tab}'")
487
487
  browser.goto(url) unless url.nil?
488
488
 
489
- { title: browser.title, url: browser.url, active: true }
489
+ { title: browser.title, url: browser.url, state: :active }
490
490
  rescue StandardError => e
491
491
  raise e
492
492
  end
@@ -506,7 +506,8 @@ module PWN
506
506
 
507
507
  browser = browser_obj[:browser]
508
508
  all_tabs = browser.windows
509
- all_tabs.select { |tab| tab.close if tab.title.include?(keyword) || tab.url.include?(keyword) }
509
+ tab_sel = all_tabs.select { |tab| tab.close if tab.title.include?(keyword) || tab.url.include?(keyword) }
510
+ { title: tab_sel.last.title, url: tab_sel.last.url, state: :closed } if tab_sel.any?
510
511
  rescue StandardError => e
511
512
  raise e
512
513
  end
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.177'
4
+ VERSION = '0.5.178'
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.177
4
+ version: 0.5.178
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.