Real usernames can be longer as 20 characters, uniqueness can not be quaranteed as usernames are being migrated from source application.
Use https + basis authentication + ASP.NET impersonation to access SSAS and did not find any infos to get UserName() to return UPN.
Apart from writing an assembly, is there another way to achieve this?