frwololo / PS4_PS5-ESP8266-Server

WebServer+Wifi Repeater+Fake DNS Server to Host PS4/PS5 Exploits on ESP8266/ESP32
https://wololo.net
76 stars 11 forks source link
esp32 esp8266 ps4-exploit-host ps5-exploit-host wifi

PS4_PS5-ESP-Server

A WebServer+Wifi Repeater+Fake DNS Server to Host PS4/PS5 Exploits on ESP8266/ESP32

exploit_in_action

Details and usage

This is an implementation of a barebones webServer to Host PS4/PS5 Exploits on an ESP8266/ESP32, that also acts as a Wifi Repeater to maintain internet access for the console. This tool has the following features:

In other words, it's a self contained solution to run the PS4/PS5 exploits while still keeping Internet access

Limitations

How to Use

Initial Install and Setup

wifi_connection

config_ok

How to use On PS4/PS5

There are a bunch of tutorials on how to run these out there, once the host is set up it is no different from others, except for the fact that it allows the console to access internet

Notes

How to Build (ESP8266)

nodemcu_settings

How to Build (ESP32)

Important Notes on ESP32 Build:

FAQ and Troubleshooting

How good is the FakeDNS?

It's a very rough design that just looks for some specific domain names (currently hardcoded inside the main source file) and either redirect those to the local ESP WebServer (namely playstation.net, where the user guides are hosted), or blocks them (other kwnonw PlayStation telemetry domains). Just because the DNS suggests that these domains should be redirect or blocked, doesn't mean the client device can't do whatever they like. In the case of the PS4 and PS5, this seems to be enough, but I can't guarantee that the console isn't bypassing DNS replies, and (for example) asks another DNS on the Network. I can imagine this would be technically doable now that the ESP8266/ESP32 opens Internet access.

Furthermore, there's no support for regexps at the moment so it's really a simple string check in its current state.

Issues accessing ESP8266 HTTPS Server

(Issue specific to ESP8266) If you get some "Error Connection close" when testing https://10.1.1.1 (local HTTPS Server), or local https page not loading, it is possible the device is running out of Heap memory. For a "regular" user, just try to reset the device. For developers, try to reduce the value of NAPT in the main .ino file. This issue and the solution are specific to ESP8266. ESP32 has enough RAM that this shouldn't be a problem.

Issues accessing regular Internet sites

Reset the ESP8266/ESP32.

Issues connecting to the Access Point / Computer disconnects from ESP32 Wifi

I have run into countless connection issues when testing this code. Generally speaking, I think the code is ok, but there are may factors that can impact connection to a computer (and, I assume, to PS4/PS5)

I am not 100% sure how the 3 "flaws" above influence the quality of an ESP32 board, but I can say that I had countless issues running the PS5 Exploit server on ESP32 on a board that turned out to simply have a bery bad Signal Strength. Buying an "original" one from Espressif solved the issue for me.

Technical thoughts and stuff

Why

Multiple versions of the ESP8266/ESP32 Hosts exist to host PS4/PS5 exploits, for the most part based on work by Stooged (https://github.com/stooged/). To my knowledge however, none of them allow the clients (PS4, PS5, or the PC that you inevitably want to connect to them) to access the Internet. The Access Point is generally stuck as a "Local Network" provider. This is enough to provide basic exploit access to the console (and it ensures you won't get an automatic firmware update for the console), but there might be cases where we want to maintain Internet access anyway.

Most people achieve that by using a "Fake DNS" and either hosting the exploit locally on their PC ( https://wololo.net/2022/10/04/tutorial-running-the-ps5-4-03-exploit-on-windows-with-additional-dns-security-telemetry-blocking-etc/ ) or accessing one of the many "exploit hosts" online. These solutions do not rely on ESP8266/32 whatsoever, or only as one element of a bigger solution (e.g; ESP8266/ESP32 + Raspberry Pi).

Given that the ESP8266/ESP32 is able to simultaneously act as an an Access Point AND connect to a Wifi Router, I assumed there had to be ways it could act as a self contained Web Server + Fake DNS + Wifi Repeater, to mimic the other solutions. Turns out it is possible, with some limitations.

Technical considerations

There are samples showing us how to run an HTTPS WebServer on ESP8266/ESP32, how to block specific domain names with some ad-blocking DNS, how to enable NAT to use the device as a Wifi Repeater. There wasn't any example of how these things are all put together, so I guess this is now it. Technically speaking, putting all these components together isn't particularly hard: The HTTP and HTTPS WebServer, including their content (exploits-related redirections, webAdmin) were taken from projects by Stooged, which are widely used in the PS4/PS5 scene on multiple variations of the ESP8266/32 Hosts. The Default DNS Server however, is designed in a way that it will redirect all traffic to the AP Host (or that's how I understood it at least), so I replaced it with a modified version by Rubfi which did more or less what I wanted. Last but not least, "Wifi Repeater" samples were available (technically, NAT routing) e.g. at https://github.com/AliBigdeli/Arduino-ESP8266-Repeater.

Differences ESP8266/ESP32

I figured the devices weren't different enough to justify two different codebases. I might regret this decision.

Credits

Code was scavenged from the following sources to build this thing: