After upgrading Nextcloud from version 30 to 32 and upgrading to 8.1.2, a problem arose:
If a long UID consisting of Russian letters is used during SSO authentication, an error appears in the log:
InvalidArgumentException User "" is not valid.
Example - "Ивановченко Иванов Иван Балалайка Водка"
The user can't log in and sees an error: Internal Server Error.
I checked ADSF—a valid UID is being transmitted.
sudo -u www-data php occ user:list lists all users, including problematic ones
but
sudo -u www-data php occ user:info "Ивановченко Иванов Иван Балалайка Водка" → User not found
In WEB its look like:
You do not have permission to view this account.

Im use MySQL + php8.1/8.2 (I don't think it depends on the version)
The issue affects both new users and those who have logged in previously.
After upgrading Nextcloud from version 30 to 32 and upgrading to 8.1.2, a problem arose:
If a long UID consisting of Russian letters is used during SSO authentication, an error appears in the log:
InvalidArgumentException User "" is not valid.
Example - "Ивановченко Иванов Иван Балалайка Водка"
The user can't log in and sees an error: Internal Server Error.
I checked ADSF—a valid UID is being transmitted.
sudo -u www-data php occ user:list lists all users, including problematic ones
but
sudo -u www-data php occ user:info "Ивановченко Иванов Иван Балалайка Водка" → User not found
In WEB its look like:

You do not have permission to view this account.
Im use MySQL + php8.1/8.2 (I don't think it depends on the version)
The issue affects both new users and those who have logged in previously.