OPNsense Forum
Archive => 18.1 Legacy Series => Topic started by: nantoine555 on March 05, 2018, 11:55:19 am
-
Hello,
We are importing users from an Active Directory.
In the LDAP configuration, the User naming attribute is userPrincipalName, so the Usernames are in UPN form (user@domain.com).
First import from LDAP is fine, but we are unable to edit and save users:
"The username contains invalid characters"
I think it is only a html form validation issue, but are any other issues when a username contains "@" and "." characters?
Thanks, and keep doing such a fine job :)
Antoine
-
Ok, opening an issue on github, found the following code:
if (preg_match("/[^a-zA-Z0-9\.\-_]/", $pconfig['usernamefld'])) {
$input_errors[] = gettext("The username contains invalid characters.");
}
if (strlen($pconfig['usernamefld']) > 32) {
$input_errors[] = gettext("The username is longer than 32 characters.");
}
-
Likely solved via https://github.com/opnsense/core/issues/2242
-
I'll just have to explain to my users that they'll have to enter their windows account and not their email when login to the vpn ;D