This issue is archived. You can view it, but you can't modify it. Learn more

ExportXMLWordPrintable

      The attributes UPN and sAMAccountName are independent.
      UPN=a@b.c.d and sAMAccountName=e are valid values for an user object in AD.
      The method getPrincipalName is wrong when the user used the sAMAccountName in the login form and sAMAccountName is unequal from the first token before the @ in the UPN.
      And this is the case if you follow the recommendations from Microsoft.

      See here https://msdn.microsoft.com/en-us/library/ms680857(v=vs.85).aspx

      This is just true for a special case and will fail in all other cases_
      String samAccountName = userPrincipalName.substring(0, userPrincipalName.indexOf('@'));

       

       

       

            Assignee:
            Félix Belzunce Arcos
            Reporter:
            Andreas Grüninger
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Archived: