bettercap 1.3.9 → 1.4.0
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/lib/bettercap/discovery/agents/base.rb +18 -6
- data/lib/bettercap/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 214e440979cb074a4c28623b1f460d109b6ab387
|
4
|
+
data.tar.gz: 33ffe4a92b00400ec8b6ef6571f39eea61f2f391
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4f54113d707ce98a6d32dbd0449f6de4642f2bc4db864682d5a3e672c1ccb7daf8caa74cab9c1a6a3a10fb92efc8f3cffdca98e9c24298e8eaf374f43fefe21d
|
7
|
+
data.tar.gz: 237137662023bd41e07f8fd0ba5c7f408ccb76fe7037999a154873193cfd837f124abe7151bfa0442d6c529142b487f3d7d4a99f32fc816ec5444ec97770fe5f
|
@@ -35,7 +35,10 @@ class Base
|
|
35
35
|
ip = ip.succ
|
36
36
|
end
|
37
37
|
else
|
38
|
-
|
38
|
+
if skip_address?(@address)
|
39
|
+
Logger.debug "Skipping #{@address} ..."
|
40
|
+
else
|
41
|
+
Logger.debug "Probing #{@address} ..."
|
39
42
|
@ctx.packets.push( get_probe(@address) )
|
40
43
|
end
|
41
44
|
end
|
@@ -46,11 +49,20 @@ class Base
|
|
46
49
|
# Return true if +ip+ must be skipped during discovery, otherwise false.
|
47
50
|
def skip_address?(ip)
|
48
51
|
# don't send probes to the gateway
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
52
|
+
if ip == @ctx.gateway
|
53
|
+
return true
|
54
|
+
# don't send probes to our device
|
55
|
+
elsif ip == @local_ip
|
56
|
+
return true
|
57
|
+
# don't stress endpoints we already discovered
|
58
|
+
else
|
59
|
+
target = @ctx.find_target( ip.to_s, nil )
|
60
|
+
# known target?
|
61
|
+
return false if target.nil?
|
62
|
+
# do we still need to get the mac for this target?
|
63
|
+
return ( target.mac.nil?? false : true )
|
64
|
+
end
|
65
|
+
|
54
66
|
end
|
55
67
|
|
56
68
|
# Each Discovery::Agent::Base derived class should implement this method.
|
data/lib/bettercap/version.rb
CHANGED
@@ -12,7 +12,7 @@ This project is released under the GPL 3 license.
|
|
12
12
|
=end
|
13
13
|
module BetterCap
|
14
14
|
# Current version of bettercap.
|
15
|
-
VERSION = '1.
|
15
|
+
VERSION = '1.4.0'
|
16
16
|
# Program banner.
|
17
17
|
BANNER = File.read( File.dirname(__FILE__) + '/banner' ).gsub( '#VERSION#', "v#{VERSION}")
|
18
18
|
end
|