code: public void checkUserName(String userName) throws CmsIllegalArgumentException {
  
          if (CmsStringUtil.isEmptyOrWhitespaceOnly(userName)) {
              throw new CmsIllegalArgumentException(
                  Messages.get().container(Messages.ERR_BAD_USERNAME_EMPTY_0, userName));
          }
  
          CmsStringUtil.checkName(userName, USERNAME_CONSTRAINTS, Messages.ERR_BAD_USERNAME_4, Messages.get());
      }
docs: A user name can only be composed of digits,
  standard ASCII letters and the symbols defined in {@link #USERNAME_CONSTRAINTS}.<p>
  
  @see org.opencms.security.I_CmsValidationHandler#checkUserName(java.lang.String)