arpdb 0.1.4 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +14 -5
- data/lib/arpdb/arp.rb +1 -1
- data/lib/arpdb/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: b5f2fe18f2945fe8e97fe7320b4f7f182f1f6997
|
4
|
+
data.tar.gz: 0477241a4888de261a3cf64c7a05a643dcae6314
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bb461504b1c2c8ab18595b77925988aae8857071332cda99c84f2ce0b778d885f8fcd9151c1db91960220d0baec3b9165767b26335292bf860360911e2499310
|
7
|
+
data.tar.gz: f08a0d82111b933b4ae9d43e3fd6129b4a091c5678633fcae49c8bf3a52086c3077c229809159297de118988ad2f433b381f365b5304792ba830f5fb724cd6ed
|
data/README.md
CHANGED
@@ -25,14 +25,23 @@ Or install it yourself as:
|
|
25
25
|
## Usage
|
26
26
|
```ruby
|
27
27
|
require 'arpdb'
|
28
|
+
include Arpdb
|
28
29
|
|
29
|
-
|
30
|
-
|
30
|
+
devices = %w(10.40.5.1 10.43.5.1)
|
31
|
+
community = 'public'
|
31
32
|
|
32
|
-
|
33
|
+
a = Arp.new(devices, 'srxread')
|
34
|
+
|
35
|
+
a.scan
|
36
|
+
|
37
|
+
puts a.mac_to_ip "7a70dec81b02"
|
38
|
+
puts a.ip_to_mac "172.27.50.2"
|
39
|
+
|
40
|
+
puts a.locate_mac "7a70dec81b02"
|
41
|
+
puts a.locate_ip "172.27.50.2"
|
42
|
+
|
43
|
+
a.refresh
|
33
44
|
|
34
|
-
puts adb.mac_to_ip 'aa:bb:cc:dd:ee:ff'
|
35
|
-
puts adb.ip_to_mac '192.168.1.100'
|
36
45
|
```
|
37
46
|
|
38
47
|
## Development
|
data/lib/arpdb/arp.rb
CHANGED
data/lib/arpdb/version.rb
CHANGED