Update README.md
Browse files
README.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
---
|
| 2 |
-
title:
|
| 3 |
emoji: π
|
| 4 |
colorFrom: blue
|
| 5 |
colorTo: gray
|
|
@@ -7,32 +7,29 @@ sdk: docker
|
|
| 7 |
app_port: 7860
|
| 8 |
---
|
| 9 |
|
| 10 |
-
#
|
| 11 |
|
| 12 |
-
A
|
| 13 |
-
|
| 14 |
-
server, not your machine. The browser's rendered output is streamed
|
| 15 |
-
to you as JPEG screenshots; clicks, keystrokes, and scroll are sent
|
| 16 |
-
back to the server and applied to the real browser session.
|
| 17 |
|
| 18 |
-
|
| 19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 20 |
|
| 21 |
-
##
|
| 22 |
-
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
-
|
| 27 |
-
|
| 28 |
-
-
|
| 29 |
-
same browser tab β fine for personal use, not for multiple
|
| 30 |
-
simultaneous users.
|
| 31 |
|
| 32 |
## Local run
|
| 33 |
```
|
| 34 |
pip install -r requirements.txt
|
| 35 |
-
playwright install --with-deps chromium
|
| 36 |
python app.py
|
| 37 |
-
```
|
| 38 |
-
Then open http://localhost:7860
|
|
|
|
| 1 |
---
|
| 2 |
+
title: Simple Browser
|
| 3 |
emoji: π
|
| 4 |
colorFrom: blue
|
| 5 |
colorTo: gray
|
|
|
|
| 7 |
app_port: 7860
|
| 8 |
---
|
| 9 |
|
| 10 |
+
# Simple Browser
|
| 11 |
|
| 12 |
+
A rewriting proxy. Your browser renders everything (real JS, video, audio,
|
| 13 |
+
hover, scrolling, full resolution); this server makes the network requests.
|
|
|
|
|
|
|
|
|
|
| 14 |
|
| 15 |
+
- HTML/CSS are rewritten so every link, image, script, stylesheet and form
|
| 16 |
+
goes through `/p?u=<url>`.
|
| 17 |
+
- `shim.js` patches `fetch`, `XMLHttpRequest`, `sendBeacon`, `history`,
|
| 18 |
+
`window.open` and DOM URL setters so JS-made requests go through too.
|
| 19 |
+
- Cookies from sites are kept server-side, one jar per visitor.
|
| 20 |
+
- Private/loopback addresses are blocked (SSRF protection).
|
| 21 |
|
| 22 |
+
## Limits
|
| 23 |
+
- WebSockets, service workers, `document.cookie` and `location = ...` set in
|
| 24 |
+
JS are not proxied. Sites that rely on them may break or leak a direct request.
|
| 25 |
+
- Heavy sites (YouTube, Google sign-in, anything with bot detection) may still
|
| 26 |
+
fail. Google also distrusts datacenter IPs regardless of the browser.
|
| 27 |
+
- Open the Space's direct `*.hf.space` URL, not the huggingface.co page
|
| 28 |
+
(the embedded iframe can block the session cookie).
|
| 29 |
+
- This is an open proxy. Keep the Space private.
|
|
|
|
|
|
|
| 30 |
|
| 31 |
## Local run
|
| 32 |
```
|
| 33 |
pip install -r requirements.txt
|
|
|
|
| 34 |
python app.py
|
| 35 |
+
```
|
|
|