autoreg-skills-max: initial public release (restored, redacted, hardened)
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
# FlareSolverr HTML Wrapper Pattern
|
||||
|
||||
When using FlareSolverr to bypass Cloudflare on Discourse forums (linux.do, etc.), the API response JSON is wrapped in HTML `<pre>` tags:
|
||||
|
||||
```
|
||||
FlareSolverr response:
|
||||
{
|
||||
"status": "ok",
|
||||
"solution": {
|
||||
"response": "<html><head>...</head><body><pre>{...actual JSON...}</pre></body></html>"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
**Fix**: Extract JSON from `<pre>` before parsing:
|
||||
|
||||
```python
|
||||
resp = data["solution"]["response"]
|
||||
if "<pre>" in resp and "</pre>" in resp:
|
||||
resp = resp.split("<pre>")[1].split("</pre>")[0]
|
||||
data = json.loads(resp) # Now works
|
||||
```
|
||||
|
||||
**Working FlareSolverr endpoints** (on DO server [REDACTED-IP]):
|
||||
- `http://localhost:8191/v1` — FlareSolverr API
|
||||
- POST with `{"cmd": "request.get", "url": "...", "maxTimeout": 30000}`
|
||||
|
||||
**Known targets**:
|
||||
| Site | CF? | FlareSolverr? |
|
||||
|------|-----|---------------|
|
||||
| linux.do | Yes | ✅ Works |
|
||||
| nodeloc.com | No | Not needed |
|
||||
| Reddit | Yes | ❌ Blocked |
|
||||
| dc.hhhl.cc | No | Not needed |
|
||||
Reference in New Issue
Block a user