ffmap-backend/nodes2bathosts.py
2012-09-19 11:28:24 +02:00

12 lines
216 B
Python
Executable file

#!/usr/bin/env python3
import json
import sys
nodes = json.load(sys.stdin)
for node in nodes['nodes']:
if node['name']:
for mac in node['macs'].split(','):
print("%s %s" % (mac.strip(), node['name']))