Rapid7 Vulnerability & Exploit Database

libssh Authentication Bypass Scanner

Back to Search

libssh Authentication Bypass Scanner

Disclosed
10/16/2018
Created
03/19/2019

Description

This module exploits an authentication bypass in libssh server code where a USERAUTH_SUCCESS message is sent in place of the expected USERAUTH_REQUEST message. libssh versions 0.6.0 through 0.7.5 and 0.8.0 through 0.8.3 are vulnerable. Note that this module's success depends on whether the server code can trigger the correct (shell/exec) callbacks despite only the state machine's authenticated state being set. Therefore, you may or may not get a shell if the server requires additional code paths to be followed.

Author(s)

  • Peter Winter-Smith
  • wvu <wvu@metasploit.com>

Development

Module Options

To display the available options, load the module within the Metasploit console and run the commands 'show options' or 'show advanced':

msf > use auxiliary/scanner/ssh/libssh_auth_bypass
msf auxiliary(libssh_auth_bypass) > show actions
    ...actions...
msf auxiliary(libssh_auth_bypass) > set ACTION < action-name >
msf auxiliary(libssh_auth_bypass) > show options
    ...show and set options...
msf auxiliary(libssh_auth_bypass) > run 

Time is precious, so I don’t want to do something manually that I can automate. Leveraging the Metasploit Framework when automating any task keeps us from having to re-create the wheel as we can use the existing libraries and focus our efforts where it matters.

– Jim O’Gorman | President, Offensive Security

;