简体   繁体   中英

Python SSH Server(twisted.conch) change the password prompt

I wrote a SSH server with Twisted Conch. When I execute "ssh username@xx.xx.xx.xx" command on the client side. My twisted SSH server will return a prompt requesting password that like "username@xx.xx.xx.xx's password: ". But now I want to change this password prompt that like "your codes is:". Dose anyone know how to do it?

The password prompt is part of keyboard-authentication which is part of the ssh protocol and thus cannot be changed. Technically, the prompt is actually client side. However, you can bypass security (very bad idea) and then output "your codes is"[sic] via the channel

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM