I have a list of DHCP lease details in a file, here is an example of the entries:
lease 172.16.20.11 { starts 4 2014/10/09 18:33:57; ends 4 2014/10/09 18:43:57; cltt 4 2014/10/09 18:33:57; binding state active; next binding state free; rewind binding state free; hardware ethernet XX:XX:XX:XX:XX:XX; client-hostname "phone"; }
I am looking for a method to convert this information into JSON format for use in Dojo.
The desired JSON output format is:
{"leases": ["address":"172.16.20.11", "starts":"2014/10/09 18:33:57", "ends":"2014/10/09 18:43:57","
client-hostname":"phone"]}
Is there a solution available to achieve this conversion?
Thank you, Tim T