Codebase list python-certbot-dns-dnsimple / 1e599b0
New upstream release. Debian Janitor 2 years ago
10 changed file(s) with 49 addition(s) and 54 deletion(s). Raw diff Collapse all Expand all
00 Metadata-Version: 2.1
11 Name: certbot-dns-dnsimple
2 Version: 1.3.0
2 Version: 1.15.0
33 Summary: DNSimple DNS Authenticator plugin for Certbot
44 Home-page: https://github.com/certbot/certbot
55 Author: Certbot Project
6 Author-email: client-dev@letsencrypt.org
6 Author-email: certbot-dev@eff.org
77 License: Apache License 2.0
88 Description: UNKNOWN
99 Platform: UNKNOWN
1313 Classifier: License :: OSI Approved :: Apache Software License
1414 Classifier: Operating System :: POSIX :: Linux
1515 Classifier: Programming Language :: Python
16 Classifier: Programming Language :: Python :: 2
17 Classifier: Programming Language :: Python :: 2.7
1816 Classifier: Programming Language :: Python :: 3
19 Classifier: Programming Language :: Python :: 3.5
2017 Classifier: Programming Language :: Python :: 3.6
2118 Classifier: Programming Language :: Python :: 3.7
2219 Classifier: Programming Language :: Python :: 3.8
20 Classifier: Programming Language :: Python :: 3.9
2321 Classifier: Topic :: Internet :: WWW/HTTP
2422 Classifier: Topic :: Security
2523 Classifier: Topic :: System :: Installation/Setup
2624 Classifier: Topic :: System :: Networking
2725 Classifier: Topic :: System :: Systems Administration
2826 Classifier: Topic :: Utilities
29 Requires-Python: >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*
27 Requires-Python: >=3.6
3028 Provides-Extra: docs
22 completing a ``dns-01`` challenge (`~acme.challenges.DNS01`) by creating, and
33 subsequently removing, TXT records using the DNSimple API.
44
5 .. note::
6 The plugin is not installed by default. It can be installed by heading to
7 `certbot.eff.org <https://certbot.eff.org/instructions#wildcard>`_, choosing your system and
8 selecting the Wildcard tab.
59
610 Named Arguments
711 ---------------
00 """DNS Authenticator for DNSimple DNS."""
11 import logging
2 from typing import Optional
23
34 from lexicon.providers import dnsimple
45 import zope.interface
78 from certbot import interfaces
89 from certbot.plugins import dns_common
910 from certbot.plugins import dns_common_lexicon
11 from certbot.plugins.dns_common import CredentialsConfiguration
1012
1113 logger = logging.getLogger(__name__)
1214
2527 ttl = 60
2628
2729 def __init__(self, *args, **kwargs):
28 super(Authenticator, self).__init__(*args, **kwargs)
29 self.credentials = None
30 super().__init__(*args, **kwargs)
31 self.credentials: Optional[CredentialsConfiguration] = None
3032
3133 @classmethod
3234 def add_parser_arguments(cls, add): # pylint: disable=arguments-differ
33 super(Authenticator, cls).add_parser_arguments(add, default_propagation_seconds=30)
35 super().add_parser_arguments(add, default_propagation_seconds=30)
3436 add('credentials', help='DNSimple credentials INI file.')
3537
3638 def more_info(self): # pylint: disable=missing-function-docstring
5355 self._get_dnsimple_client().del_txt_record(domain, validation_name, validation)
5456
5557 def _get_dnsimple_client(self):
58 if not self.credentials: # pragma: no cover
59 raise errors.Error("Plugin has not been prepared.")
5660 return _DNSimpleLexiconClient(self.credentials.conf('token'), self.ttl)
5761
5862
6266 """
6367
6468 def __init__(self, token, ttl):
65 super(_DNSimpleLexiconClient, self).__init__()
69 super().__init__()
6670
6771 config = dns_common_lexicon.build_lexicon_config('dnssimple', {
6872 'ttl': ttl,
00 Metadata-Version: 2.1
11 Name: certbot-dns-dnsimple
2 Version: 1.3.0
2 Version: 1.15.0
33 Summary: DNSimple DNS Authenticator plugin for Certbot
44 Home-page: https://github.com/certbot/certbot
55 Author: Certbot Project
6 Author-email: client-dev@letsencrypt.org
6 Author-email: certbot-dev@eff.org
77 License: Apache License 2.0
88 Description: UNKNOWN
99 Platform: UNKNOWN
1313 Classifier: License :: OSI Approved :: Apache Software License
1414 Classifier: Operating System :: POSIX :: Linux
1515 Classifier: Programming Language :: Python
16 Classifier: Programming Language :: Python :: 2
17 Classifier: Programming Language :: Python :: 2.7
1816 Classifier: Programming Language :: Python :: 3
19 Classifier: Programming Language :: Python :: 3.5
2017 Classifier: Programming Language :: Python :: 3.6
2118 Classifier: Programming Language :: Python :: 3.7
2219 Classifier: Programming Language :: Python :: 3.8
20 Classifier: Programming Language :: Python :: 3.9
2321 Classifier: Topic :: Internet :: WWW/HTTP
2422 Classifier: Topic :: Security
2523 Classifier: Topic :: System :: Installation/Setup
2624 Classifier: Topic :: System :: Networking
2725 Classifier: Topic :: System :: Systems Administration
2826 Classifier: Topic :: Utilities
29 Requires-Python: >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*
27 Requires-Python: >=3.6
3028 Provides-Extra: docs
0 setuptools>=39.0.1
1 zope.interface
02 acme>=0.31.0
13 certbot>=1.1.0
2 mock
3 setuptools
4 zope.interface
54 dns-lexicon>=3.2.1
65
76 [docs]
0 python-certbot-dns-dnsimple (1.3.0-2) UNRELEASED; urgency=low
0 python-certbot-dns-dnsimple (1.15.0-1) UNRELEASED; urgency=low
11
22 * Set upstream metadata fields: Bug-Database, Bug-Submit, Repository,
33 Repository-Browse.
4 * New upstream release.
45
5 -- Debian Janitor <janitor@jelmer.uk> Sat, 18 Jul 2020 21:34:18 -0000
6 -- Debian Janitor <janitor@jelmer.uk> Fri, 28 May 2021 03:09:29 -0000
67
78 python-certbot-dns-dnsimple (1.3.0-1) unstable; urgency=medium
89
9292 # a list of builtin themes.
9393 #
9494
95 # http://docs.readthedocs.org/en/latest/theme.html#how-do-i-use-this-locally-and-on-read-the-docs
95 # https://docs.readthedocs.io/en/stable/faq.html#i-want-to-use-the-read-the-docs-theme-locally
9696 # on_rtd is whether we are on readthedocs.org
9797 on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
9898 if not on_rtd: # only import and set the theme if we're building docs locally
110110 # Add any paths that contain custom static files (such as style sheets) here,
111111 # relative to this directory. They are copied after the builtin static files,
112112 # so a file named "default.css" will overwrite the builtin "default.css".
113 html_static_path = ['_static']
113 #html_static_path = ['_static']
114114
115115
116116 # -- Options for HTMLHelp output ------------------------------------------
2121 echo.may add the Sphinx directory to PATH.
2222 echo.
2323 echo.If you don't have Sphinx installed, grab it from
24 echo.http://sphinx-doc.org/
24 echo.https://www.sphinx-doc.org/
2525 exit /b 1
2626 )
2727
22
33 from setuptools import find_packages
44 from setuptools import setup
5 from setuptools.command.test import test as TestCommand
65
7 version = '1.3.0'
6 version = '1.15.0'
87
98 # Remember to update local-oldest-requirements.txt when changing the minimum
109 # acme/certbot version.
1110 install_requires = [
12 'acme>=0.31.0',
13 'certbot>=1.1.0',
14 'mock',
15 'setuptools',
11 'setuptools>=39.0.1',
1612 'zope.interface',
1713 ]
14
15 if not os.environ.get('SNAP_BUILD'):
16 install_requires.extend([
17 'acme>=0.31.0',
18 'certbot>=1.1.0',
19 ])
20 elif 'bdist_wheel' in sys.argv[1:]:
21 raise RuntimeError('Unset SNAP_BUILD when building wheels '
22 'to include certbot dependencies.')
23 if os.environ.get('SNAP_BUILD'):
24 install_requires.append('packaging')
1825
1926 # This package normally depends on dns-lexicon>=3.2.1 to address the
2027 # problem described in https://github.com/AnalogJ/lexicon/issues/387,
3340 'sphinx_rtd_theme',
3441 ]
3542
36 class PyTest(TestCommand):
37 user_options = []
38
39 def initialize_options(self):
40 TestCommand.initialize_options(self)
41 self.pytest_args = ''
42
43 def run_tests(self):
44 import shlex
45 # import here, cause outside the eggs aren't loaded
46 import pytest
47 errno = pytest.main(shlex.split(self.pytest_args))
48 sys.exit(errno)
49
5043 setup(
5144 name='certbot-dns-dnsimple',
5245 version=version,
5346 description="DNSimple DNS Authenticator plugin for Certbot",
5447 url='https://github.com/certbot/certbot',
5548 author="Certbot Project",
56 author_email='client-dev@letsencrypt.org',
49 author_email='certbot-dev@eff.org',
5750 license='Apache License 2.0',
58 python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*',
51 python_requires='>=3.6',
5952 classifiers=[
6053 'Development Status :: 5 - Production/Stable',
6154 'Environment :: Plugins',
6356 'License :: OSI Approved :: Apache Software License',
6457 'Operating System :: POSIX :: Linux',
6558 'Programming Language :: Python',
66 'Programming Language :: Python :: 2',
67 'Programming Language :: Python :: 2.7',
6859 'Programming Language :: Python :: 3',
69 'Programming Language :: Python :: 3.5',
7060 'Programming Language :: Python :: 3.6',
7161 'Programming Language :: Python :: 3.7',
7262 'Programming Language :: Python :: 3.8',
63 'Programming Language :: Python :: 3.9',
7364 'Topic :: Internet :: WWW/HTTP',
7465 'Topic :: Security',
7566 'Topic :: System :: Installation/Setup',
8980 'dns-dnsimple = certbot_dns_dnsimple._internal.dns_dnsimple:Authenticator',
9081 ],
9182 },
92 tests_require=["pytest"],
93 test_suite='certbot_dns_dnsimple',
94 cmdclass={"test": PyTest},
9583 )
11
22 import unittest
33
4 import mock
4 try:
5 import mock
6 except ImportError: # pragma: no cover
7 from unittest import mock # type: ignore
58 from requests.exceptions import HTTPError
69
710 from certbot.compat import os
1619 dns_test_common_lexicon.BaseLexiconAuthenticatorTest):
1720
1821 def setUp(self):
19 super(AuthenticatorTest, self).setUp()
22 super().setUp()
2023
2124 from certbot_dns_dnsimple._internal.dns_dnsimple import Authenticator
2225