webb 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +7 -2
- data/lib/webb/cli.rb +13 -7
- data/lib/webb/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 90af24f07003885e5aff5bcd87442d0a7a4c4821
|
4
|
+
data.tar.gz: bc43fecbf50e407192402ccf7a7043bbeb14c0ec
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a9bb3cead54eeaa25e1a2371abdcc362280aece49339438af8c97fbca620e98a986df0300aeed8d1ded551b6a1c02e16f7e4a77b19aa9951021253c4bed37a0c
|
7
|
+
data.tar.gz: 9fe0e82d665999a1e253ab3ea3c7cef41c8fa47d3a2fc66a1f0422c38c264563e4581ef51fe25220b9138fd12815b3dfdc4149a83f0c533a29cfc884c1b338e0
|
data/README.md
CHANGED
@@ -1,6 +1,9 @@
|
|
1
1
|
# Webb
|
2
2
|
|
3
|
-
|
3
|
+
Webb discovers active HTTP servers within a provided range and opens the addresses in Safari.
|
4
|
+
Named after the space telescope named after James E. Webb.
|
5
|
+
|
6
|
+
Powered by cedras GmbH, Winterthur, Switzerland.
|
4
7
|
|
5
8
|
## Installation
|
6
9
|
|
@@ -18,7 +21,9 @@ Or install it yourself as:
|
|
18
21
|
|
19
22
|
## Usage
|
20
23
|
|
21
|
-
|
24
|
+
$ webb scan 172.16.0.0
|
25
|
+
|
26
|
+
$ webb sweep 172.16.0.0 172.18.255.255
|
22
27
|
|
23
28
|
## Contributing
|
24
29
|
|
data/lib/webb/cli.rb
CHANGED
@@ -10,7 +10,7 @@ class Webb::CLI < Thor
|
|
10
10
|
|
11
11
|
desc "scan ADDRESS", "Scans a single address for responding webservers."
|
12
12
|
def scan(address)
|
13
|
-
request = Typhoeus::Request.new(address, followlocation: true)
|
13
|
+
request = Typhoeus::Request.new(address, followlocation: true, timeout: 2)
|
14
14
|
|
15
15
|
request.on_complete do |response|
|
16
16
|
%x{open http://#{address}} if response.success?
|
@@ -23,14 +23,20 @@ class Webb::CLI < Thor
|
|
23
23
|
range = (IPAddr.new(from)..IPAddr.new(to))
|
24
24
|
|
25
25
|
queue = Typhoeus::Hydra.new
|
26
|
-
range.
|
27
|
-
|
28
|
-
|
29
|
-
|
26
|
+
range.each_slice(64) do |slice|
|
27
|
+
puts "#{slice.first.to_s}..#{slice.last .to_s}"
|
28
|
+
slice.each do |ip|
|
29
|
+
request = Typhoeus::Request.new(ip.to_s, followlocation: true, timeout: 2)
|
30
|
+
request.on_complete do |response|
|
31
|
+
if response.success?
|
32
|
+
%x{open http://#{ip.to_s}}
|
33
|
+
puts ip.to_s
|
34
|
+
end
|
35
|
+
end
|
36
|
+
queue.queue(request)
|
30
37
|
end
|
31
|
-
queue.
|
38
|
+
queue.run
|
32
39
|
end
|
33
|
-
queue.run
|
34
40
|
end
|
35
41
|
|
36
42
|
end
|
data/lib/webb/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: webb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Juan Romero Abelleira
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-02-
|
11
|
+
date: 2014-02-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|