Skip to content

Resolve primary STUN server(s) via DNS SRV #10029

Closed

Description

@bt90

Feature description

I'd suggest that we resolve our own STUN servers via DNS SRV. This will allow us to change the domain name and IP address of our own STUN server without having to patch Syncthing.

This should be enough to fend off most non-Syncthing users.

If there's a consensus that this is a viable approach, I'd start working on a PR.

Problem or use case

As previously discussed on the forum, we may still want to host our own STUN server. The problem with such a service is that it tends to be abused by others, which ultimately led to the current server being shut down. Any hardcoded address in the codebase is likely to suffer the same fate sooner or later.

see https://forum.syncthing.net/t/stun-syncthing-net-doesnt-resolve-anymore/24075/8

Alternatives or workarounds

Static secrets for the STUN server, but this could suffer the same fate. Anything that can simply be hardcoded into a WebRTC page will eventually be abused. DNS SRV requires backend logic, which should deter more offenders.

Activity

  1. added
    enhancement
    needs-triage
    on Apr 3, 2025
  2. calmh commented on Apr 3, 2025

    @calmh
    Member

    I'm on board with this. Let's try it. If it fails we're in no worse a spot than we are today.

  3. removed
    needs-triage
    on Apr 3, 2025
  4. added a commit that references this issue on Apr 8, 2025
    d7ca483
  5. added this to the v1.29.5 milestone on Apr 8, 2025
  6. bt90 commented on Apr 8, 2025

    @bt90
    ContributorAuthor
  7. calmh commented on Apr 8, 2025

    @calmh
    Member

    At some point soon, been busy with another thing on the infra side...

  8. added 2 commits that reference this issue on Apr 9, 2025
    1e5f6ea
    95b39a7
  9. modified the milestones: v1.29.5, v1.29.6 on Apr 12, 2025
  10. added a commit that references this issue on Apr 13, 2025
    f295b69
  11. added
    frozen-due-to-age
    on Jul 1, 2026
  12. locked and limited conversation to collaborators on Jul 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementfrozen-due-to-age

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions