Some internal investigation shows the code regex that parses the userpass auth method inputs allow for alphanumeric, plus “_”, “-”, and “.” (underscore, hyphen and period). LDAP auth method is slightly different, perhaps to account for how different LDAP backends can be configured for what characters are permitted.
I’ll look to having some clarification added to the userpass documentation.