Skip to content

Ensure only valid subdomain names can be used.

Boros Gábor requested to merge kshitij/subdomain-constraints into master

Created by: xitij2000

Currently there is very little validation of subdomain names while registering a beta instance. This means that:

  • It is possible to pick subdomain names that are simply invalid (for instance they include an underscore).
  • It is possible to override someone else's subdomain by using different the same name with a different case.
  • It is possible to use dots in the subdomain names, which can have unexpected effects if one user picks a subdomain under another user.
  • It is possible to pick a subdomain name that is longer than the allowed 63 characters.

This pull request includes changes that ensure that it is no longer possible to register domain names that cause the above issues.

Sandbox URL: TBD - sandbox is being provisioned.

Merge deadline: None

Testing instructions:

  1. Set up Ocim using the patches in this pull request.
  2. Visit /registration/
  3. Try to register an instance that is too long, uses capital letters, a dot or other invalid characters like an underscore.
  4. The registration should fail and the registration form should show the appropriate error message.

Author notes and concerns:

Existing instances that don't pass the above validation will need manual intervention.

Reviewers

  • @pomegranited

Merge request reports