pwn 0.5.312 → 0.5.313
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/transparent_browser.rb +16 -3
- 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: 637c524ecea5f16a96ee38e5fb449e6df52289ba726aac5447d7509511745ea5
|
4
|
+
data.tar.gz: f25475d8329111f5c71a79ebb0f75f677e8a2d2ebdc3f160fdb8623bdd845015
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4ab9ee157c8f6edfd2cfe30f77e0cdea7bd91926bcc1e44959241655e6a7a2665b872f8830cade196e6ba27cc4dec99741999fa22c60cbbc2c4e2e63d87c222d
|
7
|
+
data.tar.gz: eca463f21dc9ae0ac5c793154a91db82aaea6757212ab004873fade7077369e27401ba167576e2c0d91a8c2e284fb221425f7c64702f9e2121172904321b1a39
|
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.313]: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.313]: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.313]: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:
|
@@ -753,7 +753,7 @@ module PWN
|
|
753
753
|
# Supported Method Parameters::
|
754
754
|
# tab = PWN::Plugins::TransparentBrowser.jmp_tab(
|
755
755
|
# browser_obj: 'required - browser_obj returned from #open method)',
|
756
|
-
# keyword: '
|
756
|
+
# keyword: 'optional - keyword in title or url used to switch tabs (defaults to switching to next tab)',
|
757
757
|
# explicit: 'optional - boolean to indicate if the keyword is an exact match (Defaults to false)'
|
758
758
|
# )
|
759
759
|
|
@@ -762,7 +762,20 @@ module PWN
|
|
762
762
|
verify_devtools_browser(browser_obj: browser_obj)
|
763
763
|
|
764
764
|
keyword = opts[:keyword]
|
765
|
-
|
765
|
+
if keyword.nil?
|
766
|
+
# If no keyword is provided, switch to the next tab in the list
|
767
|
+
tab_list = list_tabs(browser_obj: browser_obj)
|
768
|
+
active_tab = tab_list.find { |tab| tab[:state] == :active }
|
769
|
+
# Next tab in the tab_list. If active tab is the last tab, switch to the first tab
|
770
|
+
next_tab_index = (tab_list.index(active_tab) + 1) % tab_list.size
|
771
|
+
next_tab = tab_list[next_tab_index]
|
772
|
+
|
773
|
+
if next_tab[:url] == active_tab[:url]
|
774
|
+
keyword = next_tab[:title]
|
775
|
+
else
|
776
|
+
keyword = next_tab[:url]
|
777
|
+
end
|
778
|
+
end
|
766
779
|
|
767
780
|
explicit = opts[:explicit] ||= false
|
768
781
|
|
@@ -1308,7 +1321,7 @@ module PWN
|
|
1308
1321
|
|
1309
1322
|
tab = #{self}.jmp_tab(
|
1310
1323
|
browser_obj: 'required - browser_obj returned from #open method)',
|
1311
|
-
keyword: '
|
1324
|
+
keyword: 'optional - keyword in title or url used to switch tabs (defaults to switching to next tab)',
|
1312
1325
|
)
|
1313
1326
|
|
1314
1327
|
tab = #{self}.new_tab(
|
data/lib/pwn/version.rb
CHANGED