pwn 0.4.860 → 0.4.861

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: b2795e3f67e49e45e8e0eb10c3e650e0400c6a81d04f3137b54ce4fa75d6202e
4
- data.tar.gz: d6b9d0e18ed3362f8f1900f0294ca0e352298879d4e7bcb15a8800acdf6c3a9d
3
+ metadata.gz: 435d6ab8a183c16a0cecf49408a16c2f3a17d2b8eb8a416c78f9c198494caef5
4
+ data.tar.gz: 763c46943dd0a27a312a4f7ffd47e2216a7654eee3b1352d697db030f5f6a0eb
5
5
  SHA512:
6
- metadata.gz: 5a8deacb4383a561dd6fcbc2eb98df7abad707029fa772c18fc3a5d02707904b0d7402b069a1a77610ed1a09dfe93944fcfc66e748886f5f860d4dbd13ae630c
7
- data.tar.gz: ababa085deaf9bc79e76a0f3957af3b0b9b2b345cad6b46a195abd9c57d938fd4ac56980a8ac547a1649a42db17bf3db5b92cff4b10a41a0ee08a014628e1471
6
+ metadata.gz: b36dae98679bbd75d1b869b806bfae27607e808b1a5fa478e677293cfd8d74c0353e9c7a6dec2596729fdaa5e6e6b70a41b39a4a103e1ffe9bb9477aefba9cd6
7
+ data.tar.gz: 2d6913497daf81b36c38a3769ab16a55595f99d88d1f8b0e48e4d88ae7db18e37d6f9037864c7ce56843e57b8fb849ddb496d61c061b334c9a50959a3c37ff4f
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.860]:001 >>> PWN.help
40
+ pwn[v0.4.861]: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.2.2@pwn
52
52
  $ gem uninstall --all --executables pwn
53
53
  $ gem install --verbose pwn
54
54
  $ pwn
55
- pwn[v0.4.860]:001 >>> PWN.help
55
+ pwn[v0.4.861]:001 >>> PWN.help
56
56
  ```
57
57
 
58
58
 
@@ -274,6 +274,29 @@ module PWN
274
274
  raise e
275
275
  end
276
276
 
277
+ # Supported Method Parameters::
278
+ # browser_obj = PWN::Plugins::TransparentBrowser.find_element_by_text(
279
+ # browser_obj: browser_obj1,
280
+ # text: 'required - text to search for in the DOM'
281
+ # )
282
+
283
+ public_class_method def self.find_element_by_text(opts = {})
284
+ browser_obj = opts[:browser_obj]
285
+ text = opts[:text].to_s
286
+
287
+ elements_found = browser_obj[:browser].elements.each do |element|
288
+ element.text.include?(text)
289
+ end
290
+
291
+ elements_found.each do |element_found|
292
+ @@logger.info("#{element_found.html}\n\n\n")
293
+ end
294
+
295
+ browser_obj
296
+ rescue StandardError => e
297
+ raise e
298
+ end
299
+
277
300
  # Supported Method Parameters::
278
301
  # PWN::Plugins::TransparentBrowser.type_as_human(
279
302
  # string: 'required - string to type as human',
@@ -419,6 +442,11 @@ module PWN
419
442
  browser_obj: 'required - browser_obj returned from #open method)'
420
443
  )
421
444
 
445
+ browser_obj1 = #{self}.find_element_by_text(
446
+ browser_obj: 'required - browser_obj returned from #open method)',
447
+ text: 'required - text to search for in the DOM'
448
+ )
449
+
422
450
  #{self}.type_as_human(
423
451
  string: 'required - string to type as human',
424
452
  rand_sleep_float: 'optional - float timing in between keypress (defaults to 0.09)'
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.4.860'
4
+ VERSION = '0.4.861'
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.4.860
4
+ version: 0.4.861
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.