Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Install Dependensi yang Dibutuhkan
- sudo apt update
- sudo apt install dnsmasq hostapd net-tools -y
- #==================================================
- #Matikan dan disable systemd-resolved
- sudo systemctl stop systemd-resolved
- sudo systemctl disable systemd-resolved
- #==================================================
- #Download File yang Diperlukan
- git clone https://github.com/idlesauce/umtx2.git umtx2/
- #==================================================
- #Konfigurasi Static IP
- sudo nano /etc/systemd/system/static-ip.service
- #Isi dengan:
- [Unit]
- Description=Set Static IP Address and restart services
- After=network-online.target hostapd.service
- Wants=network-online.target
- [Service]
- Type=oneshot
- ExecStart=/usr/local/bin/set-static-ip.sh
- RemainAfterExit=yes
- [Install]
- WantedBy=multi-user.target
- #==================================================
- #Buat skrip konfigurasi IP statis:
- sudo nano /usr/local/bin/set-static-ip.sh
- #Isi dengan:
- #!/bin/bash
- # Wait until wlan0 is available (max 10 seconds)
- for i in {1..10}; do
- if ip link show wlan0 > /dev/null 2>&1; then
- break
- fi
- sleep 1
- done
- # Ensure wlan0 is up
- ip link set wlan0 up
- # Assign static IP to wlan0
- ifconfig wlan0 10.1.1.1 netmask 255.255.255.0 up
- # Restart hostapd & dnsmasq services
- systemctl restart hostapd
- systemctl restart dnsmasq
- # Log process for debugging
- echo "[\$(date)] Static IP & routing set for wlan0" >> /var/log/wifi-fix.log
- #==================================================
- #Beri izin eksekusi pada skrip:
- sudo chmod +x /usr/local/bin/set-static-ip.sh
- #Aktifkan service:
- sudo systemctl daemon-reload
- sudo systemctl enable static-ip.service
- sudo systemctl start static-ip.service
- #==================================================
- #Konfigurasi Hostapd (WiFi AP)
- sudo nano /etc/hostapd/hostapd.conf
- #Isi dengan:
- interface=wlan0
- ssid=PS5_JB
- hw_mode=g
- channel=6
- auth_algs=1
- wpa=2
- wpa_passphrase=12345678
- wpa_key_mgmt=WPA-PSK
- rsn_pairwise=CCMP
- #Atur lokasi file konfigurasi:
- sudo nano /etc/default/hostapd
- #Tambahkan:
- DAEMON_CONF="/etc/hostapd/hostapd.conf"
- #Aktifkan dan jalankan hostapd:
- sudo systemctl unmask hostapd
- sudo systemctl enable hostapd
- sudo systemctl restart hostapd
- #==================================================
- #Konfigurasi dnsmasq (DHCP & DNS)
- sudo nano /etc/dnsmasq.conf
- #Isi dengan:
- interface=wlan0
- bind-interfaces
- port=0
- dhcp-range=10.1.1.2,10.1.1.9,7d
- dhcp-option=3,10.1.1.1
- dhcp-option=6,10.1.1.1
- bogus-priv
- no-resolv
- no-hosts
- no-poll
- log-dhcp
- log-queries
- #Restart dnsmasq:
- sudo systemctl restart dnsmasq
- #==================================================
- #host.py – HTTP/HTTPS Server
- sudo nano host.py
- #Paste:
- import http.server, ssl, time, re, threading
- from http.server import SimpleHTTPRequestHandler, HTTPServer
- class RequestHandler(SimpleHTTPRequestHandler):
- def replace_locale(self):
- self.path = re.sub(r'^/document/\w{2}/ps5', '/document/en/ps5', self.path)
- def do_GET(self):
- if self.path in ['/', '', '/index.html']:
- self.send_response(302)
- self.send_header('Location', '/document/en/ps5/')
- self.end_headers()
- return
- self.replace_locale()
- return super().do_GET()
- def do_POST(self):
- self.replace_locale()
- tn = self.path.lstrip('/document/en/ps5/')
- print('!POST!: tn:\n' + tn)
- fn = tn
- if not tn.startswith("T_"):
- if fn != "a.bin":
- print('!POST!: INFO: ' + str(self.rfile.read(int(self.headers['Content-length']))), "utf-8")
- return
- else:
- fn = time.strftime("%Y%m%d-%H%M%S") + ".bin"
- print('!POST!: ' + self.path + ' -->> ' + fn)
- print('test: %d' % int(self.headers['Content-length']))
- data = self.rfile.read(int(self.headers['Content-length']))
- open(fn, "wb").write(data)
- self.send_response(200)
- self.send_header("Content-type", "text/html")
- self.end_headers()
- def run_http():
- server_address = ('0.0.0.0', 80)
- httpd = HTTPServer(server_address, RequestHandler)
- print('Running HTTP server on port 80')
- httpd.serve_forever()
- def run_https():
- server_address = ('0.0.0.0', 443)
- context = ssl.SSLContext(ssl.PROTOCOL_TLS_SERVER)
- context.load_cert_chain(certfile='localhost.pem')
- httpd = HTTPServer(server_address, RequestHandler)
- httpd.socket = context.wrap_socket(httpd.socket, server_side=True)
- print('Running HTTPS server on port 443')
- httpd.serve_forever()
- # Jalankan HTTP dan HTTPS secara paralel
- threading.Thread(target=run_http, daemon=True).start()
- run_https() # Biarkan HTTPS di foreground agar log tampil dan systemd bisa monitor
- #==================================================
- #Service untuk HTTP (tanpa SSL)
- sudo nano /etc/systemd/system/ps5-host.service
- #Isi file:
- [Unit]
- Description=PS5 Exploit Host HTTP
- After=network.target
- [Service]
- ExecStart=/usr/bin/python3 /root/umtx2/host.py
- WorkingDirectory=/root/umtx2
- Restart=always
- User=root
- [Install]
- WantedBy=multi-user.target
- #==================================================
- #Service untuk HTTPS (dengan SSL)
- sudo nano /etc/systemd/system/ps5-host-ssl.service
- #Isi file:
- [Unit]
- Description=PS5 Exploit Host HTTPS
- After=network.target
- [Service]
- ExecStart=/usr/bin/python3 /root/umtx2/host_ssl.py
- WorkingDirectory=/root/umtx2
- Restart=always
- User=root
- [Install]
- WantedBy=multi-user.target
- #==================================================
- #Fakedns service
- sudo nano /etc/systemd/system/fakedns.service
- #Isi dengan :
- [Unit]
- Description=Fake DNS Server
- After=network.target
- [Service]
- ExecStart=/usr/bin/python3 /root/umtx2/fakedns.py -c /root/umtx2/dns.conf
- WorkingDirectory=/root/umtx2
- Restart=always
- [Install]
- WantedBy=multi-user.target
- #ubah dns.conf
- nano dns.conf
- #Isi dengan :
- A manuals.playstation.net 10.1.1.1
- #==================================================
- #Jalankan semua:
- sudo systemctl daemon-reexec
- sudo systemctl daemon-reload
- sudo systemctl enable ps5-host.service
- sudo systemctl enable ps5-host-ssl.service
- sudo systemctl enable fakedns.service
- sudo systemctl start ps5-host.service
- sudo systemctl start ps5-host-ssl.service
- sudo systemctl start fakedns.service
- #==================================================
- #Reboot
- sudo reboot
- #==================================================
- #Check status semua:
- sudo systemctl status ps5-host.service
- sudo systemctl status ps5-host-ssl.service
- sudo systemctl status fakedns.service
- sudo systemctl status dnsmasq.service
- sudo systemctl status static-ip.service
- #==================================================
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement