ddns: Added new provider Domain-Offensive (http://do.de)
Message ID | 1487870272-31233-1-git-send-email-dirk.wagner@ipfire.org |
---|---|
State | Accepted |
Headers |
Return-Path: <ddns-bounces@lists.ipfire.org> Received: from mail01.ipfire.org (unknown [172.28.1.200]) by web02.ipfire.org (Postfix) with ESMTP id 0A56561FA9 for <patchwork@ipfire.org>; Thu, 23 Feb 2017 18:18:23 +0100 (CET) Received: from mail01.ipfire.org (localhost [IPv6:::1]) by mail01.ipfire.org (Postfix) with ESMTP id B0E337DD; Thu, 23 Feb 2017 18:18:22 +0100 (CET) Received: from server.wagner-budenheim.de (ip5b43b5c5.dynamic.kabel-deutschland.de [91.67.181.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 90790D5; Thu, 23 Feb 2017 18:18:20 +0100 (CET) From: Dirk Wagner <dirk.wagner@ipfire.org> To: ddns@lists.ipfire.org Subject: [PATCH] ddns: Added new provider Domain-Offensive (http://do.de) Date: Thu, 23 Feb 2017 18:17:52 +0100 Message-Id: <1487870272-31233-1-git-send-email-dirk.wagner@ipfire.org> X-Mailer: git-send-email 2.1.4 X-BeenThere: ddns@lists.ipfire.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List for the IPFire dynamic DNS client <ddns.lists.ipfire.org> List-Unsubscribe: <http://lists.ipfire.org/mailman/options/ddns>, <mailto:ddns-request@lists.ipfire.org?subject=unsubscribe> List-Archive: <http://lists.ipfire.org/pipermail/ddns/> List-Post: <mailto:ddns@lists.ipfire.org> List-Help: <mailto:ddns-request@lists.ipfire.org?subject=help> List-Subscribe: <http://lists.ipfire.org/mailman/listinfo/ddns>, <mailto:ddns-request@lists.ipfire.org?subject=subscribe> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ddns-bounces@lists.ipfire.org Sender: "ddns" <ddns-bounces@lists.ipfire.org> |
Message
Dirk Wagner
Feb. 24, 2017, 4:17 a.m. UTC
Signed-off-by: Dirk Wagner <dirk.wagner@ipfire.org>
---
README | 1 +
src/ddns/errors.py | 8 +++++++-
src/ddns/providers.py | 15 ++++++++++++++-
src/ddns/system.py | 4 ++++
4 files changed, 26 insertions(+), 2 deletions(-)
mode change 100644 => 100755 README
mode change 100644 => 100755 src/ddns/errors.py
mode change 100644 => 100755 src/ddns/providers.py
mode change 100644 => 100755 src/ddns/system.py
Comments
Hello Dirk, thanks for sending the patch. I've divided your changes into two patches and merged them. Best regards, -Stefan > Signed-off-by: Dirk Wagner <dirk.wagner@ipfire.org> > --- > README | 1 + > src/ddns/errors.py | 8 +++++++- > src/ddns/providers.py | 15 ++++++++++++++- > src/ddns/system.py | 4 ++++ > 4 files changed, 26 insertions(+), 2 deletions(-) > mode change 100644 => 100755 README > mode change 100644 => 100755 src/ddns/errors.py > mode change 100644 => 100755 src/ddns/providers.py > mode change 100644 => 100755 src/ddns/system.py > > diff --git a/README b/README > old mode 100644 > new mode 100755 > index 40f1e7f..5f1911d > --- a/README > +++ b/README > @@ -55,6 +55,7 @@ SUPPORTED PROVIDERS: > dns.lightningwirelabs.com > dnsmadeeasy.com > dnspark.com > + do.de > domains.google.com > domopoli.de > dtdns.com > diff --git a/src/ddns/errors.py b/src/ddns/errors.py > old mode 100644 > new mode 100755 > index 58a5ba9..e5383dc > --- a/src/ddns/errors.py > +++ b/src/ddns/errors.py > @@ -2,7 +2,7 @@ > #################################################################### > ########### > # > # > # ddns - A dynamic DNS client for > IPFire # > -# Copyright (C) 2012 IPFire development > team # > +# Copyright (C) 2012-2017 IPFire development > team # > # > # > # This program is free software: you can redistribute it and/or > modify # > # it under the terms of the GNU General Public License as published > by # > @@ -160,6 +160,12 @@ class > DDNSServiceUnavailableError(DDNSNetworkError): > """ > reason = N_("Service unavailable") > > + > +class DDNSTooManyRequests(DDNSError): > + """ > + Raised when too many requests occured. > + """ > + reason = N_("Too many requests") > > class DDNSUpdateError(DDNSError): > """ > diff --git a/src/ddns/providers.py b/src/ddns/providers.py > old mode 100644 > new mode 100755 > index 2c30d42..2a74511 > --- a/src/ddns/providers.py > +++ b/src/ddns/providers.py > @@ -2,7 +2,7 @@ > #################################################################### > ########### > # > # > # ddns - A dynamic DNS client for > IPFire # > -# Copyright (C) 2012 IPFire development > team # > +# Copyright (C) 2012-2017 IPFire development > team # > # > # > # This program is free software: you can redistribute it and/or > modify # > # it under the terms of the GNU General Public License as published > by # > @@ -840,7 +840,20 @@ class DDNSProviderDynDNS(DDNSProtocolDynDNS2, > DDNSProvider): > > url = "https://members.dyndns.org/nic/update" > > + > +class DDNSProviderDomainOffensive(DDNSProtocolDynDNS2, > DDNSProvider): > + handle = "do.de" > + name = "Domain-Offensive" > + website = "http://dyn.com/dns/" > + protocols = ("ipv4",) > + > + # Detailed information about the request and response codes > + # are available on the providers webpage. > + # https://www.do.de/wiki/FlexDNS_-_Entwickler > + > + url = "https://ddns.do.de/" > > + > class DDNSProviderDynU(DDNSProtocolDynDNS2, DDNSProvider): > handle = "dynu.com" > name = "Dynu" > diff --git a/src/ddns/system.py b/src/ddns/system.py > old mode 100644 > new mode 100755 > index c268ba5..67ea553 > --- a/src/ddns/system.py > +++ b/src/ddns/system.py > @@ -194,6 +194,10 @@ class DDNSSystem(object): > elif e.code == 404: > raise DDNSNotFound(e.reason) > > + # 429 - Too Many Requests > + elif e.code == 429: > + raise DDNSTooManyRequests(e.reason) > + > # 500 - Internal Server Error > elif e.code == 500: > raise > DDNSInternalServerError(e.reason)