From fa5d6becb482da75e65683b0ae690d35fa3eade6 Mon Sep 17 00:00:00 2001 From: kaotisk Date: Tue, 27 Feb 2024 07:20:27 +0200 Subject: Refactor Arching Kaos ID to node_info --- bin/ak-cjdns-scanner | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'bin/ak-cjdns-scanner') diff --git a/bin/ak-cjdns-scanner b/bin/ak-cjdns-scanner index aee1fd2..81c3814 100755 --- a/bin/ak-cjdns-scanner +++ b/bin/ak-cjdns-scanner @@ -13,18 +13,18 @@ dumpLinks \ | uniq \ | while read -r ip || [ -n "$ip" ] do - akid="`curl \ + node_info="`curl \ -A 'akd/0.1.0; https://github.com/arching-kaos' \ --connect-timeout 3 \ - "http://[$(publictoip6 $ip)]:8610/v0/akid" 2>/dev/null`" + "http://[$(publictoip6 $ip)]:8610/v0/node_info" 2>/dev/null`" if [ "$?" == "0" ] then if [ "$counter" -ne "0" ] then printf ',' >> walk.aknet fi - printf '{"cjdnsPublicKey":"%s","cjdnsIp":"%s","akid":%s}' \ - "$ip" "`publictoip6 $ip`" "$akid" >> walk.aknet + printf '{"cjdns":{"public_key":"%s","ip":"%s"},"node_info":%s}' \ + "$ip" "`publictoip6 $ip`" "$node_info" >> walk.aknet counter="`expr $counter + 1`" fi done -- cgit v1.2.3