Remove username generation feature

Background

In very early versions of FMD Server, clients could not choose the username. Instead, the server generated a random username. The length was configurable via the UserIdLength setting in config.yml.

Around January 2025, we added support for clients choosing their own username in FMD Server 0.9.0 and FMD Android 0.10.0.

Since FMD Android 0.15.0, the client forces you to enter a username, and no longer lets you send an empty string.

Planned change

I want to remove this feature from FMD Server. FMD Server should reject registration attempts that provide an empty username.

Reasoning

  • Simplify the server code, removing a historic feature
  • Prepare for APIv2, where the client MUST choose the username, because it will be cryptographically committed into various things (password hashing, master key encryption, ...).

Impact

Users with FMD Android >= 0.10.0 are unaffected. They have a UI to enter a username.

Users who still run FMD Android <= 0.9.0 will NOT be able to register new accounts. They can continue to log in and use existing accounts. Imho this is acceptable. It's arguably not a "breaking change", since it only affects new FMD Server registrations, not existing FMD Server accounts.