Skip to content

Possible to create publications with illegal domain names #271

@jjbarr

Description

@jjbarr

As per RFC3696 Section 2, hostnames in DNS may contain the letters a-z, the numbers 0-9, and the hyphen character -. However, it is not permitted for a hostname to start or end with a hyphen.

When testing whether this restriction was adhered to, I was able to create the extremely cursed leaflet publication ---.leaflet.pub, which is, of course, impossible to visit. The creation dialogue hung indefinitely (presumably trying to redirect me to a webpage that according to the browser could not exist on account of the URL being invalid), but the record was sucessfully added to my repo and leaflet does recognize the resultant site as a real publication,

Proposed solution: prevent users from creating publication URLs where any component begins or ends in -.

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