code: def DropPrivileges():
    
    if config.CONFIG["Server.username"]:
      try:
        os.setuid(pwd.getpwnam(config.CONFIG["Server.username"]).pw_uid)
      except (KeyError, OSError):
        logging.exception("Unable to switch to user %s",
                          config.CONFIG["Server.username"])
        raise
docs: Attempt to drop privileges if required.