Skip to content

Instantly share code, notes, and snippets.

View TheoLeeCJ's full-sized avatar

Theodore Lee TheoLeeCJ

View GitHub Profile
@TheoLeeCJ
TheoLeeCJ / cors-anyhow.py
Last active October 20, 2025 12:05
CORS Anywhere as a single Python file
import http.server
import socketserver
import requests
# Removed unused imports from urllib.parse
# --- Configuration ---
PORT = 8080
TARGET_URL_PREFIX = "/" # The prefix in the path before the target URL (e.g. /http://target.com)
# --- CORS Headers to add to the response ---