A little noip ddns api for python.
- socket
- requests
- cryptography
- BeautifulSoup4
login
function logs you in with your username and passwordsaveLoginInfo
function save your username and password encrypted in noip.config fileloadLoginInfo
function loads your username and password from noip.config filegetCurrent
function returns current ip saved in your hostnamesetDNS
function sets given ip to your hostnamegetMyIP
function returns your current public ip addresstestOpenPort
function returns if your port is open, closed or filtered(when the routers firewall is blocking it)
import noip_api
username = ""
password = ""
hostname = ""
DDNS = noip_api.noip(hostname)
DDNS.login(username=username, password=password)
print(DDNS.getMyIP())
print(DDNS.getCurrent())
DDNS.setDNS(ip=DDNS.getMyIP())
import noip_api
username = ""
password = ""
hostname = ""
DDNS = noip_api.noip(hostname)
DDNS.saveLoginInfo(username=username, password=password)
import noip_api
username = ""
password = ""
hostname = ""
DDNS = noip_api.noip(hostname)
DDNS.loadLoginInfo()
DDNS.setDNS(ip=DDNS.getMyIP())