Bug: in dd24 provider - update not possible - ERROR bad authentication #134

Closed
opened 2025-11-20 04:20:44 -05:00 by saavagebueno · 2 comments
Owner

Originally created by @kreditor0815 on GitHub (Aug 24, 2021).

Originally assigned to: @qdm12 on GitHub.

TLDR: The plugin for dd24 seems to be broken. No update is possible ("ERROR bad authentication"). It seems, there is a typo or copy&paste error in source @ the if/else near 51dd14cb66/internal/settings/providers/dd24/provider.go (L102-L106)

  1. Is this urgent: Yes

  2. DNS provider(s) you use: dd24

  3. Program version:
    Running version latest built on 2021-08-16T12:40:55Z (commit 51dd14c)

  4. What are you using to run the container: docker-compose

version: "2"
services:
  ddns-updater:
    image: qmcgaw/ddns-updater
#    container_name: ddns-updater
#    network_mode: bridge
    ports:
      - 25425:8000/tcp
    volumes:
      - /app-data/ddns/data:/updater/data
    environment:
      - CONFIG=
      - PERIOD=5m
      - UPDATE_COOLDOWN_PERIOD=5m
      - PUBLICIP_FETCHERS=all
      - PUBLICIP_HTTP_PROVIDERS=all
      - PUBLICIPV4_HTTP_PROVIDERS=all
      - PUBLICIPV6_HTTP_PROVIDERS=all
      - PUBLICIP_DNS_PROVIDERS=all
      - PUBLICIP_DNS_TIMEOUT=3s
      - HTTP_TIMEOUT=10s

      # Web UI
      - LISTENING_PORT=8000
      - ROOT_URL=/

      # Backup
      - BACKUP_PERIOD=0 # 0 to disable
      - BACKUP_DIRECTORY=/updater/data

      # Other
      - LOG_LEVEL=debug
      - LOG_CALLER=hidden
      - SHOUTRRR_ADDRESSES=
    restart: unless-stopped
  1. Extra information (optional)

Logs:

2021/08/24 07:27:33 INFO Found single setting to update record
2021/08/24 07:27:33 INFO Reading history from database: domain domain.com host subdomain
2021/08/24 07:27:33 DEBUG configured to fetch IP: v4 or v6: false, v4: true, v6: false
2021/08/24 07:27:33 INFO healthcheck server: listening on 127.0.0.1:9999
2021/08/24 07:27:33 INFO backup: disabled
2021/08/24 07:27:33 INFO http server: listening on :8000
2021/08/24 07:27:34 DEBUG your public IP address are: v4 or v6: <nil>, v4: 217.84.135.123, v6: <nil>
2021/08/24 07:27:34 INFO IPv4 address of subdomain.domain.com is 217.84.151.91 and your IPv4 address is 217.84.135.123
2021/08/24 07:27:34 INFO Updating record [domain: domain.com | host: subdomain | provider: dd24 | ip: ipv4] to use 217.84.135.123
2021/08/24 07:27:34 DEBUG GET https://dynamicdns.key-systems.net/update.php?hostname=217.84.135.123&password=password | headers: User-Agent: DDNS-Updater quentin.mcgaw@gmail.com
2021/08/24 07:27:34 DEBUG 200 OK | headers: Date: Tue, 24 Aug 2021 07:27:34 GMT; Server: Apache; Strict-Transport-Security: max-age=63072000; preload; Vary: Accept-Encoding; Content-Type: text/html; charset=UTF-8 | body: [RESPONSE]code = 531description = Authorization failedruntime = 0.04queuetime = 0EOF
2021/08/24 07:27:34 ERROR bad authentication

Noticed the IP-Address in the GET Request? I think that was placed in the wrong field.

Configuration file (remove your credentials!):

{
  "settings": [
    {
      "provider": "dd24",
      "domain": "domain.com",
      "host": "subdomain",
      "password": "password",
      "ip_version": "ipv4"
    }
  ]
}

Host OS:
some kind of ubuntu

I think one possible source of this problem can be found in setting variables in this if/else: 51dd14cb66/internal/settings/providers/dd24/provider.go (L102-L106)

But that variable already got set with the correct value @ 51dd14cb66/internal/settings/providers/dd24/provider.go (L100)

I'm pretty confident that this should not set the value of the hostname-variable but the ip-variable (as stated in the documentation: https://www.domaindiscount24.com/faq/en/dynamic-dns).

As this lines are not avoidable and are overwriting the hostname-variable, this plugin seems completely broken to me.

Originally created by @kreditor0815 on GitHub (Aug 24, 2021). Originally assigned to: @qdm12 on GitHub. <!-- YOU CAN CHAT THERE EVENTUALLY: https://github.com/qdm12/ddns-updater/discussions --> **TLDR**: The plugin for dd24 seems to be broken. No update is possible ("ERROR bad authentication"). It seems, there is a typo or copy&paste error in source @ the if/else near https://github.com/qdm12/ddns-updater/blob/51dd14cb66c39db0e36dc42a857c9aa6928a2949/internal/settings/providers/dd24/provider.go#L102-L106 1. Is this urgent: Yes 2. DNS provider(s) you use: dd24 3. Program version: `Running version latest built on 2021-08-16T12:40:55Z (commit 51dd14c)` 4. What are you using to run the container: docker-compose ```yml version: "2" services: ddns-updater: image: qmcgaw/ddns-updater # container_name: ddns-updater # network_mode: bridge ports: - 25425:8000/tcp volumes: - /app-data/ddns/data:/updater/data environment: - CONFIG= - PERIOD=5m - UPDATE_COOLDOWN_PERIOD=5m - PUBLICIP_FETCHERS=all - PUBLICIP_HTTP_PROVIDERS=all - PUBLICIPV4_HTTP_PROVIDERS=all - PUBLICIPV6_HTTP_PROVIDERS=all - PUBLICIP_DNS_PROVIDERS=all - PUBLICIP_DNS_TIMEOUT=3s - HTTP_TIMEOUT=10s # Web UI - LISTENING_PORT=8000 - ROOT_URL=/ # Backup - BACKUP_PERIOD=0 # 0 to disable - BACKUP_DIRECTORY=/updater/data # Other - LOG_LEVEL=debug - LOG_CALLER=hidden - SHOUTRRR_ADDRESSES= restart: unless-stopped ``` 5. Extra information (optional) Logs: ```log 2021/08/24 07:27:33 INFO Found single setting to update record 2021/08/24 07:27:33 INFO Reading history from database: domain domain.com host subdomain 2021/08/24 07:27:33 DEBUG configured to fetch IP: v4 or v6: false, v4: true, v6: false 2021/08/24 07:27:33 INFO healthcheck server: listening on 127.0.0.1:9999 2021/08/24 07:27:33 INFO backup: disabled 2021/08/24 07:27:33 INFO http server: listening on :8000 2021/08/24 07:27:34 DEBUG your public IP address are: v4 or v6: <nil>, v4: 217.84.135.123, v6: <nil> 2021/08/24 07:27:34 INFO IPv4 address of subdomain.domain.com is 217.84.151.91 and your IPv4 address is 217.84.135.123 2021/08/24 07:27:34 INFO Updating record [domain: domain.com | host: subdomain | provider: dd24 | ip: ipv4] to use 217.84.135.123 2021/08/24 07:27:34 DEBUG GET https://dynamicdns.key-systems.net/update.php?hostname=217.84.135.123&password=password | headers: User-Agent: DDNS-Updater quentin.mcgaw@gmail.com 2021/08/24 07:27:34 DEBUG 200 OK | headers: Date: Tue, 24 Aug 2021 07:27:34 GMT; Server: Apache; Strict-Transport-Security: max-age=63072000; preload; Vary: Accept-Encoding; Content-Type: text/html; charset=UTF-8 | body: [RESPONSE]code = 531description = Authorization failedruntime = 0.04queuetime = 0EOF 2021/08/24 07:27:34 ERROR bad authentication ``` Noticed the IP-Address in the GET Request? I think that was placed in the wrong field. Configuration file (**remove your credentials!**): ```json { "settings": [ { "provider": "dd24", "domain": "domain.com", "host": "subdomain", "password": "password", "ip_version": "ipv4" } ] } ``` Host OS: some kind of ubuntu I think one possible source of this problem can be found in setting variables in this if/else: https://github.com/qdm12/ddns-updater/blob/51dd14cb66c39db0e36dc42a857c9aa6928a2949/internal/settings/providers/dd24/provider.go#L102-L106 But that variable already got set with the correct value @ https://github.com/qdm12/ddns-updater/blob/51dd14cb66c39db0e36dc42a857c9aa6928a2949/internal/settings/providers/dd24/provider.go#L100 I'm pretty confident that this should not set the value of the hostname-variable but the ip-variable (as stated in the documentation: https://www.domaindiscount24.com/faq/en/dynamic-dns). As this lines are not avoidable and are overwriting the hostname-variable, this plugin seems completely broken to me.
Author
Owner

@qdm12 commented on GitHub (Aug 24, 2021):

You totally nailed down the issue, thanks!!

Indeed the implementation was faulty from the start, sorry I did not have feedback from the user who requested it when it got added. Let me know if it works for you, thanks!

@qdm12 commented on GitHub (Aug 24, 2021): You totally nailed down the issue, thanks!! Indeed the implementation was faulty from the start, sorry I did not have feedback from the user who requested it when it got added. Let me know if it works for you, thanks!
Author
Owner

@kreditor0815 commented on GitHub (Aug 24, 2021):

Hi @qdm12,

I just wanted to let you know that commit c584f9b3d5 totally fixed it for me.
Thank you very much for your help :)

@kreditor0815 commented on GitHub (Aug 24, 2021): Hi @qdm12, I just wanted to let you know that commit https://github.com/qdm12/ddns-updater/commit/c584f9b3d537b0640a2e432fdc858397312e5f24 totally fixed it for me. Thank you very much for your help :)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/ddns-updater#134