pwn 0.4.827 → 0.4.829

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: bdc9a2b7f219a0702dae4e7e3991817656b099ef38d89c9caf2a56bc4d5f98ea
4
- data.tar.gz: ce6535b4acd5a43892b2489831e838c417ef35ecd019474484c0175e64fba3b1
3
+ metadata.gz: b789d393560ee1cb713d1be03ab2e9ebf4a6fe50c14fd90fd6970693524704a6
4
+ data.tar.gz: f20d67c217dbd5d21b08a628cd34d7ab0a9bc5e30546585614bfd1f7c1f171f7
5
5
  SHA512:
6
- metadata.gz: 0c7b6fcf8c0a9a42d4fd28b59df5d1d125922b080f9d456028251d834d21acc3e0c17864d11d21aa800eedb59a9224802ab4f3aa28322d766d5a5c52a635349b
7
- data.tar.gz: ce7c22e7d7b758c91b6b9700639244de40e075ed7620b0de7880397ba5779f485dd100c3469f0e11b3ce04506b51f5c3b8c8345bb755b79d1a2bb0474758ddf6
6
+ metadata.gz: 53a8a2a233a5c0b70d33dce7150b82f1aeb4ad551d724e3fbed30827df7e4e1730837cd0052e1362334fcf798eb63623e389af73fca10ff60f376f8f1a3e933f
7
+ data.tar.gz: 397a0753f45dfe1aee4d16fd2cc447c997375c2501d88276835175415ef94c9918052841dbf9380fb6f2e1a02b74887518eec489b7c69c747be52dd6d7ddfc1d
data/Gemfile CHANGED
@@ -26,7 +26,7 @@ gem 'colorize', '1.1.0'
26
26
  gem 'credit_card_validations', '6.0.0'
27
27
  gem 'eventmachine', '1.2.7'
28
28
  gem 'executable-hooks', '1.6.1'
29
- gem 'faker', '3.2.0'
29
+ gem 'faker', '3.2.1'
30
30
  gem 'faye-websocket', '0.11.3'
31
31
  gem 'ffi', '1.15.5'
32
32
  gem 'fftw3', '0.3'
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.827]:001 >>> PWN.help
40
+ pwn[v0.4.829]: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.827]:001 >>> PWN.help
55
+ pwn[v0.4.829]:001 >>> PWN.help
56
56
  ```
57
57
 
58
58
 
@@ -20,6 +20,10 @@ OptionParser.new do |options|
20
20
  opts[:query_file] = q
21
21
  end
22
22
 
23
+ options.on('-rFLOAT', '--rate-limit=FLOAT', '<Optional - Rate Limit Between API Calls (Default: 1.0, must be >= 1.0)>') do |r|
24
+ opts[:rate_limit_duration] = r
25
+ end
26
+
23
27
  options.on('-oFILE', '--output-results-file=FILE', '<Optional - Defaults to /tmp/shodan-results-Time.now.strftime("%y-%m-%d.%H:%M:%S").txt>') do |o|
24
28
  opts[:output_results_file] = o
25
29
  end
@@ -41,6 +45,10 @@ begin
41
45
  query_file = opts[:query_file].to_s
42
46
  raise "ERROR: #{query_file} does not exist." unless File.exist?(query_file)
43
47
 
48
+ rate_limit_duration = opts[:rate_limit_duration].to_f
49
+ rate_limit_duration = 1.0 if rate_limit_duration.zero?
50
+ raise 'ERROR: Rate Limit must be >= 1.0' unless rate_limit_duration.positive?
51
+
44
52
  queries = File.readlines(query_file)
45
53
 
46
54
  timestamp = Time.now.strftime('%Y-%m-%d.%H:%M:%S')
@@ -59,7 +67,6 @@ begin
59
67
  query: query
60
68
  )
61
69
  puts " >>> Matches: #{search_results[:total]}"
62
- sleep 1
63
70
 
64
71
  raw_results = {}
65
72
  raw_results[:query] = query
@@ -72,6 +79,8 @@ begin
72
79
  f.puts "TCP Port: #{m[:port]}"
73
80
  f.puts "Data: #{m[:data]}\n\n\n"
74
81
  end
82
+
83
+ sleep rate_limit_duration
75
84
  end
76
85
  end
77
86
  File.write(raw_query_results_file, JSON.pretty_generate(raw_results_arr))
@@ -85,7 +85,7 @@ module PWN
85
85
  raise e
86
86
  end
87
87
  ensure
88
- spinner.stop
88
+ spinner.stop unless spinner.nil?
89
89
  end
90
90
 
91
91
  # Supported Method Parameters::
@@ -59,7 +59,7 @@ module PWN
59
59
  #{self}.generate(
60
60
  data: 'required - data to encode',
61
61
  type: 'optional - :barcode || :qrcode (defaults to :qrcode)',
62
- path: 'optional - path to save image (defaults to \"./#{data}.png\")'
62
+ path: 'optional - path to save image (defaults to \"./\#{data}.png\")'
63
63
  )
64
64
 
65
65
  #{self}.authors
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.827'
4
+ VERSION = '0.4.829'
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.4.827
4
+ version: 0.4.829
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-08-11 00:00:00.000000000 Z
11
+ date: 2023-08-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -212,14 +212,14 @@ dependencies:
212
212
  requirements:
213
213
  - - '='
214
214
  - !ruby/object:Gem::Version
215
- version: 3.2.0
215
+ version: 3.2.1
216
216
  type: :runtime
217
217
  prerelease: false
218
218
  version_requirements: !ruby/object:Gem::Requirement
219
219
  requirements:
220
220
  - - '='
221
221
  - !ruby/object:Gem::Version
222
- version: 3.2.0
222
+ version: 3.2.1
223
223
  - !ruby/object:Gem::Dependency
224
224
  name: faye-websocket
225
225
  requirement: !ruby/object:Gem::Requirement