Bug
game and games are special SSH route usernames for AgentGames, but auth.IsReservedName does not include GameNames. That means the signup sanitizer can accept game or games as member account names, creating an account/route collision with ssh game@host.
Reproduction
- Review
internal/auth/auth.go.
GameNames defines game and games as reserved SSH routes.
IsReservedName checks many route maps but omits GameNames.
SanitizeUsername("game") can therefore return usable even though game@ is a protocol route.
Expected
All SSH route usernames should be rejected during signup/account-name sanitization.
Bug
gameandgamesare special SSH route usernames for AgentGames, butauth.IsReservedNamedoes not includeGameNames. That means the signup sanitizer can acceptgameorgamesas member account names, creating an account/route collision withssh game@host.Reproduction
internal/auth/auth.go.GameNamesdefinesgameandgamesas reserved SSH routes.IsReservedNamechecks many route maps but omitsGameNames.SanitizeUsername("game")can therefore return usable even thoughgame@is a protocol route.Expected
All SSH route usernames should be rejected during signup/account-name sanitization.