code: private void tryToMakeAdmin(User u) {
          AuthorizationStrategy as = Jenkins.getInstance().getAuthorizationStrategy();
          for (PermissionAdder adder : ExtensionList.lookup(PermissionAdder.class)) {
              if (adder.add(as, u, Jenkins.ADMINISTER)) {
                  return;
              }
          }
      }
docs: Try to make this user a super-user