gstuartj / cf-ddns.sh

A simple client for automatically updating CloudFlare DNS with your current IP address
MIT License
81 stars 35 forks source link

Testing on DD-WRT v3 - some minor issues #6

Open B-C-C opened 6 years ago

B-C-C commented 6 years ago

Found that using named zone and named record generates errors. due to curl version issue.... have no idea what version of curl is on there... busybox ash is the cli -

due to the boxes being very small - there is not https certs installed sure that is a space issue.

so curl -k will allow the https to be insecure - not sure if there is a a work around for that. However removing zone and record Id and only using names:

I believe its tied again to limited busybox / version of grep.

./cf-ddns.sh --get-zone-id grep: unrecognized option: P BusyBox v1.28.4 (2018-06-29 12:24:51 CEST) multi-call binary.

shows another issue in grep it looks like. this simple change from -Po to -Eo doesn't work

so the regex is no bueno for busybox ash which is pretty common in most dd-wrt / router installs..

if you manually enter the records the script works great...

well except it thinks the LAN ip is the same as external... probably again due to different flavors of DD-WRT.

anyway pretty close - only issue I could find so far is that Grep is REALLY incompatible due to not being able to parse perl regex.