code: protected Map<String, List<Object>> resolveAttributesFromPrincipalAttributeRepository(final Principal principal, final RegisteredService registeredService) {
          val repository = ObjectUtils.defaultIfNull(this.principalAttributesRepository,
              getPrincipalAttributesRepositoryFromApplicationContext());
          if (repository != null) {
              LOGGER.debug("Using principal attribute repository [{}] to retrieve attributes", repository);
              return repository.getAttributes(principal, registeredService);
          }
          return principal.getAttributes();
      }
docs: Resolve attributes from principal attribute repository.
  
  @param principal         the principal
  @param registeredService the registered service
  @return the map