Hello,
I am currently setting up a C2 server on a VPS and need assistance with a port-related issue preventing implant connections.
Current Setup:
· VPS IP: [YOUR_VPS_IP]
· C2 Framework: Metha (Python/Flask)
· Server is running and listening on port 5000 (HTTP)
· Port forwarding rule (iptables) is in place to redirect traffic from port 443 to port 5000
· The VPS provider has confirmed port 443 is open on their network firewall
Issue:
· Connections from my local computer to https://[YOUR_VPS_IP]:443/api/v2/check are failing with Connection refused or ERR_CONNECTION_RESET
· Testing locally on the VPS with curl -v http://127.0.0.1:5000/api/v2/check returns {"status":"no_data"} – confirming the server itself is working correctly
What I've Tried:
· Verified the server is listening on 0.0.0.0:5000
· Confirmed iptables rule is active (tcp dpt:443 redir ports 5000)
· Generated SSL certificates and attempted to use socat as an SSL proxy
· Tested from both inside and outside the VPS
Request:
I need help diagnosing why external connections to port 443 are not reaching the server on port 5000. Please let me know if you require any additional details or logs.
Thank you
I am currently setting up a C2 server on a VPS and need assistance with a port-related issue preventing implant connections.
Current Setup:
· VPS IP: [YOUR_VPS_IP]
· C2 Framework: Metha (Python/Flask)
· Server is running and listening on port 5000 (HTTP)
· Port forwarding rule (iptables) is in place to redirect traffic from port 443 to port 5000
· The VPS provider has confirmed port 443 is open on their network firewall
Issue:
· Connections from my local computer to https://[YOUR_VPS_IP]:443/api/v2/check are failing with Connection refused or ERR_CONNECTION_RESET
· Testing locally on the VPS with curl -v http://127.0.0.1:5000/api/v2/check returns {"status":"no_data"} – confirming the server itself is working correctly
What I've Tried:
· Verified the server is listening on 0.0.0.0:5000
· Confirmed iptables rule is active (tcp dpt:443 redir ports 5000)
· Generated SSL certificates and attempted to use socat as an SSL proxy
· Tested from both inside and outside the VPS
Request:
I need help diagnosing why external connections to port 443 are not reaching the server on port 5000. Please let me know if you require any additional details or logs.
Thank you

