Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Slight change in output format

And fixed another bug.
  • Loading branch information...
commit 7318308bc58686961b644d3e0ff33401634a906b 1 parent 88df727
@bitplane authored
Showing with 7 additions and 5 deletions.
  1. +1 −1  Discoverer.py
  2. +6 −4 Discoverer_Arp.py
View
2  Discoverer.py
@@ -100,7 +100,7 @@ def startDiscovery(output, intrusive=False):
try:
instance = klass(output)
instances.append(instance)
- discoverer.start()
+ instance.start()
except Exception as e:
# Don't crash because someone didn't read the docs
logging.error(e)
View
10 Discoverer_Arp.py
@@ -28,10 +28,12 @@ def runOnce(self):
if tokens[1] != 1 or not tokens[2] & 2:
continue
- out = {'device':
- {'ipv4.address': tokens[0],
- 'eth.address' : tokens[3],
- 'if.name' : tokens[5]}}
+ out = {'devices':
+ [{'ipv4': {'address' : tokens[0]},
+ 'eth' : {'address' : tokens[3],
+ 'interface': tokens[5]}}],
+ 'interfaces': [{'name':tokens[5]}] }
+
self.output.put(out)
input.close()
Please sign in to comment.
Something went wrong with that request. Please try again.