TODO 有问题
        :return:

def check_sudo(self):
        """
        TODO 有问题
        :return:
        """
        stdin, stdout, stderr = self.ssh_session.exec_command('sudo whoami')
        stdin.write("%s\n" % self.password)
        stdin.write("\n\n\n\n\n\n\n\n")
        stdout.read()
        error_message = stderr.read()[:-1]
        if b"not in the sudoers file" in error_message:
            logger.info('当前用户不在 sudo 组')
            return False
        else:
            logger.info(error_message)
            return True