8000 using ddns provider returns "ValueError: input to from_text() must be a string" · Issue #887 · adferrand/dnsrobocert · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
using ddns provider returns "ValueError: input to from_text() must be a string" #887
Open
@Catscrash

Description

@Catscrash

When trying to issue a certificate with the ddns provider, it fails with the following error message (create and cleanup hook the same)

2022-11-02 10:24:39,223:WARNING:certbot.display.ops:Hook '--manual-cleanup-hook' for dnsrobotest1.xxx ran with error output:
 Error while executing the `cleanup` hook:
 input to from_text() must be a string
 Traceback (most recent call last):
   File "/root/.local/pipx/venvs/dnsrobocert/lib/python3.10/site-packages/dnsrobocert/core/hooks.py", line 40, in main
     globals()[parsed_args.type](dnsrobocert_config, parsed_args.lineage)
   File "/root/.local/pipx/venvs/dnsrobocert/lib/python3.10/site-packages/dnsrobocert/core/hooks.py", line 123, in cleanup
     txt_challenge(certificate, profile, token, domain, action="delete")
   File "/root/.local/pipx/venvs/dnsrobocert/lib/python3.10/site-packages/dnsrobocert/core/challenge.py", line 58, in txt_challenge
     Client(lexicon_config).execute()
   File "/root/.local/pipx/venvs/dnsrobocert/lib/python3.10/site-packages/lexicon/client.py", line 99, in execute
     return self.provider.delete_record(identifier, record_type, name, content)
   File "/root/.local/pipx/venvs/dnsrobocert/lib/python3.10/site-packages/lexicon/providers/base.py", line 118, in delete_record
     return self._delete_record(
   File "/root/.local/pipx/venvs/dnsrobocert/lib/python3.10/site-packages/lexicon/providers/ddns.py", line 149, in _delete_record
     name = dns.name.from_text(name).relativize(dns.name.from_text(self.zone))
   File "/root/.local/pipx/venvs/dnsrobocert/lib/python3.10/site-packages/dns/name.py", line 908, in from_text
     raise ValueError("input to from_text() must be a string")
 ValueError: input to from_text() must be a string

The config file currently looks like this:

draft: false
acme:
  email_account: xxxxxxxxx
  staging: true
profiles:
- name: test
  provider: ddns
  provider_options:
    ddns_server: "xxx.xxx.xxx.xxx"
    auth_token: "HMAC-SHA512:xxx.key:xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx=="
certificates:
- domains:
  - "dnsrobotest1.xxx"
  - "*.dnsrobotest1.xxx"
  profile: test

we tried playing around with " or ' around the different options, but nothing helped. Running lexicon itself works fine and the DNS entry gets properly created:

~/.local/bin/lexicon ddns create xxx TXT --name="_acme-challenge.dnsrobotest1.xxx." --content="challenge token" --ddns-server xxx --auth-token 'HMAC-SHA512:xxx.key:xxxxxxxxxxxxxxxxxxxx==' 

RESULT
------
True

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0