Compare commits

..

7 Commits

Author SHA1 Message Date
ilike2burnthing
c7505e3cbf Revert to Python v3.13 and bump FlareSolverr to 3.4.5 (#1617) 2025-11-11 01:58:14 +00:00
ilike2burnthing
5a27090abe Fix Dockerfile casing 2025-11-06 02:11:28 +00:00
flower
e505ea4fe4 Fix changelog building (#1611) 2025-11-06 00:52:46 +00:00
ilike2burnthing
63b6fc53e3 Bump version 3.4.4 (#1609) 2025-11-04 23:04:55 +00:00
flower
8d72617219 Bump dependencies, Chrome, and some other general fixes (#1607)
Co-authored-by: ilike2burnthing <59480337+ilike2burnthing@users.noreply.github.com>
2025-11-04 22:49:32 +00:00
ilike2burnthing
8a8b9415c3 Bump version 3.4.3 (#1601) 2025-10-28 10:21:38 +00:00
ilike2burnthing
16722ef963 Update proxy extension. Fixes #1534 2025-10-28 00:01:30 +00:00
13 changed files with 43 additions and 34 deletions

View File

@@ -19,17 +19,14 @@ jobs:
id: github_changelog id: github_changelog
run: | run: |
changelog=$(git log $(git tag | tail -2 | head -1)..HEAD --no-merges --oneline) changelog=$(git log $(git tag | tail -2 | head -1)..HEAD --no-merges --oneline)
changelog="${changelog//'%'/'%25'}" echo "changelog<<EOF" >> $GITHUB_OUTPUT
changelog="${changelog//$'\n'/'%0A'}" echo "$changelog" >> $GITHUB_OUTPUT
changelog="${changelog//$'\r'/'%0D'}" echo "EOF" >> $GITHUB_OUTPUT
echo "changelog=${changelog}" >> $GITHUB_ENV
- name: Create release - name: Create release
uses: softprops/action-gh-release@v2 uses: softprops/action-gh-release@v2
with: with:
tag_name: ${{ github.ref }} body: ${{ steps.github_changelog.outputs.changelog }}
name: ${{ github.ref }}
body: ${{ env.changelog }}
env: env:
GITHUB_TOKEN: ${{ secrets.GH_PAT }} GITHUB_TOKEN: ${{ secrets.GH_PAT }}

View File

@@ -1,5 +1,14 @@
# Changelog # Changelog
## v3.4.5 (2025/11/11)
* Revert to Python v3.13
## v3.4.4 (2025/11/04)
* Bump dependencies, Chromium, and some other general fixes. Thanks @flowerey
## v3.4.3 (2025/10/28)
* Update proxy extension
## v3.4.2 (2025/10/09) ## v3.4.2 (2025/10/09)
* Bump dependencies & CI actions. Thanks @flowerey * Bump dependencies & CI actions. Thanks @flowerey
* Add optional wait time after resolving the challenge before returning. Thanks @kennedyoliveira * Add optional wait time after resolving the challenge before returning. Thanks @kennedyoliveira

View File

@@ -1,4 +1,4 @@
FROM python:3.13-slim-bookworm as builder FROM python:3.13-slim-bookworm AS builder
# Build dummy packages to skip installing them and their dependencies # Build dummy packages to skip installing them and their dependencies
RUN apt-get update \ RUN apt-get update \
@@ -67,17 +67,17 @@ ENTRYPOINT ["/usr/bin/dumb-init", "--"]
CMD ["/usr/local/bin/python", "-u", "/app/flaresolverr.py"] CMD ["/usr/local/bin/python", "-u", "/app/flaresolverr.py"]
# Local build # Local build
# docker build -t ngosang/flaresolverr:3.4.2 . # docker build -t ngosang/flaresolverr:3.4.5 .
# docker run -p 8191:8191 ngosang/flaresolverr:3.4.2 # docker run -p 8191:8191 ngosang/flaresolverr:3.4.5
# Multi-arch build # Multi-arch build
# docker run --rm --privileged multiarch/qemu-user-static --reset -p yes # docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
# docker buildx create --use # docker buildx create --use
# docker buildx build -t ngosang/flaresolverr:3.4.2 --platform linux/386,linux/amd64,linux/arm/v7,linux/arm64/v8 . # docker buildx build -t ngosang/flaresolverr:3.4.5 --platform linux/386,linux/amd64,linux/arm/v7,linux/arm64/v8 .
# add --push to publish in DockerHub # add --push to publish in DockerHub
# Test multi-arch build # Test multi-arch build
# docker run --rm --privileged multiarch/qemu-user-static --reset -p yes # docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
# docker buildx create --use # docker buildx create --use
# docker buildx build -t ngosang/flaresolverr:3.4.2 --platform linux/arm/v7 --load . # docker buildx build -t ngosang/flaresolverr:3.4.5 --platform linux/arm/v7 --load .
# docker run -p 8191:8191 --platform linux/arm/v7 ngosang/flaresolverr:3.4.2 # docker run -p 8191:8191 --platform linux/arm/v7 ngosang/flaresolverr:3.4.5

View File

@@ -77,7 +77,7 @@ This is the recommended way for Windows users.
> **Warning** > **Warning**
> Installing from source code only works for x64 architecture. For other architectures see Docker images. > Installing from source code only works for x64 architecture. For other architectures see Docker images.
* Install [Python 3.13](https://www.python.org/downloads/). * Install [Python 3.14](https://www.python.org/downloads/).
* Install [Chrome](https://www.google.com/intl/en_us/chrome/) (all OS) or [Chromium](https://www.chromium.org/getting-involved/download-chromium/) (just Linux, it doesn't work in Windows) web browser. * Install [Chrome](https://www.google.com/intl/en_us/chrome/) (all OS) or [Chromium](https://www.chromium.org/getting-involved/download-chromium/) (just Linux, it doesn't work in Windows) web browser.
* (Only in Linux) Install [Xvfb](https://en.wikipedia.org/wiki/Xvfb) package. * (Only in Linux) Install [Xvfb](https://en.wikipedia.org/wiki/Xvfb) package.
* (Only in macOS) Install [XQuartz](https://www.xquartz.org/) package. * (Only in macOS) Install [XQuartz](https://www.xquartz.org/) package.
@@ -89,8 +89,8 @@ This is the recommended way for Windows users.
* Run `pkg install chromium python313 py313-pip xorg-vfbserver` command to install the required dependencies. * Run `pkg install chromium python313 py313-pip xorg-vfbserver` command to install the required dependencies.
* Clone this repository and open a shell in that path. * Clone this repository and open a shell in that path.
* Run `python3.13 -m pip install -r requirements.txt` command to install FlareSolverr dependencies. * Run `python3.14 -m pip install -r requirements.txt` command to install FlareSolverr dependencies.
* Run `python3.13 src/flaresolverr.py` command to start FlareSolverr. * Run `python3.14 src/flaresolverr.py` command to start FlareSolverr.
### Systemd service ### Systemd service
@@ -327,4 +327,3 @@ to the file name of one of the adapters inside the `/captcha` directory.
## Related projects ## Related projects
* C# implementation => https://github.com/FlareSolverr/FlareSolverrSharp * C# implementation => https://github.com/FlareSolverr/FlareSolverrSharp

View File

@@ -1,6 +1,6 @@
{ {
"name": "flaresolverr", "name": "flaresolverr",
"version": "3.4.2", "version": "3.4.5",
"description": "Proxy server to bypass Cloudflare protection", "description": "Proxy server to bypass Cloudflare protection",
"author": "Diego Heras (ngosang / ngosang@hotmail.es)", "author": "Diego Heras (ngosang / ngosang@hotmail.es)",
"license": "MIT" "license": "MIT"

View File

@@ -1,6 +1,6 @@
bottle==0.13.4 bottle==0.13.4
waitress==3.0.2 waitress==3.0.2
selenium==4.36.0 selenium==4.38.0
func-timeout==4.3.5 func-timeout==4.3.5
prometheus-client==0.23.1 prometheus-client==0.23.1
# Required by undetected_chromedriver # Required by undetected_chromedriver
@@ -9,6 +9,6 @@ certifi==2025.10.5
websockets==15.0.1 websockets==15.0.1
packaging==25.0 packaging==25.0
# Only required for Linux and macOS # Only required for Linux and macOS
xvfbwrapper==0.2.14; platform_system != "Windows" xvfbwrapper==0.2.15; platform_system != "Windows"
# Only required for Windows # Only required for Windows
pefile==2024.8.26; platform_system == "Windows" pefile==2024.8.26; platform_system == "Windows"

View File

@@ -5,7 +5,7 @@ import logging
def logger_plugin(callback): def logger_plugin(callback):
""" """
Bottle plugin to use logging module Bottle plugin to use logging module
http://bottlepy.org/docs/dev/plugindev.html https://bottlepy.org/docs/dev/plugindev.html
Wrap a Bottle request so that a log line is emitted after it's handled. Wrap a Bottle request so that a log line is emitted after it's handled.
(This decorator can be extended to take the desired logger as a param.) (This decorator can be extended to take the desired logger as a param.)

View File

@@ -18,7 +18,7 @@ def setup():
def prometheus_plugin(callback): def prometheus_plugin(callback):
""" """
Bottle plugin to expose Prometheus metrics Bottle plugin to expose Prometheus metrics
http://bottlepy.org/docs/dev/plugindev.html https://bottlepy.org/docs/dev/plugindev.html
""" """
def wrapper(*args, **kwargs): def wrapper(*args, **kwargs):
actual_response = callback(*args, **kwargs) actual_response = callback(*args, **kwargs)

View File

@@ -25,7 +25,7 @@ def clean_files():
def download_chromium(): def download_chromium():
# https://commondatastorage.googleapis.com/chromium-browser-snapshots/index.html?prefix=Linux_x64/ # https://commondatastorage.googleapis.com/chromium-browser-snapshots/index.html?prefix=Linux_x64/
revision = "1465706" if os.name == 'nt' else '1465706' revision = "1522586" if os.name == 'nt' else '1522586'
arch = 'Win_x64' if os.name == 'nt' else 'Linux_x64' arch = 'Win_x64' if os.name == 'nt' else 'Linux_x64'
dl_file = 'chrome-win' if os.name == 'nt' else 'chrome-linux' dl_file = 'chrome-win' if os.name == 'nt' else 'chrome-linux'
dl_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), os.pardir, 'dist_chrome') dl_path = os.path.join(os.path.dirname(os.path.abspath(__file__)), os.pardir, 'dist_chrome')

View File

@@ -81,7 +81,7 @@ if __name__ == "__main__":
# fix ssl certificates for compiled binaries # fix ssl certificates for compiled binaries
# https://github.com/pyinstaller/pyinstaller/issues/7229 # https://github.com/pyinstaller/pyinstaller/issues/7229
# https://stackoverflow.com/questions/55736855/how-to-change-the-cafile-argument-in-the-ssl-module-in-python3 # https://stackoverflow.com/q/55736855
os.environ["REQUESTS_CA_BUNDLE"] = certifi.where() os.environ["REQUESTS_CA_BUNDLE"] = certifi.where()
os.environ["SSL_CERT_FILE"] = certifi.where() os.environ["SSL_CERT_FILE"] = certifi.where()

View File

@@ -21,11 +21,11 @@ class TestFlareSolverr(unittest.TestCase):
proxy_socks_url = "socks5://127.0.0.1:1080" proxy_socks_url = "socks5://127.0.0.1:1080"
google_url = "https://www.google.com" google_url = "https://www.google.com"
post_url = "https://httpbin.org/post" post_url = "https://httpbin.org/post"
cloudflare_url = "https://nowsecure.nl" cloudflare_url = "https://nowsecure.nl/"
cloudflare_url_2 = "https://idope.se/torrent-list/harry/" cloudflare_url_2 = "https://idope.se/torrent-list/harry/"
ddos_guard_url = "https://anidex.info/" ddos_guard_url = "https://www.litres.ru/"
fairlane_url = "https://www.pararius.com/apartments/amsterdam" fairlane_url = "https://www.pararius.com/apartments/amsterdam"
custom_cloudflare_url = "https://www.muziekfabriek.org" custom_cloudflare_url = "https://www.muziekfabriek.org/"
cloudflare_blocked_url = "https://cpasbiens3.fr/index.php?do=search&subaction=search" cloudflare_blocked_url = "https://cpasbiens3.fr/index.php?do=search&subaction=search"
app = TestApp(flaresolverr.app) app = TestApp(flaresolverr.app)
@@ -162,7 +162,7 @@ class TestFlareSolverr(unittest.TestCase):
self.assertIn(self.ddos_guard_url, solution.url) self.assertIn(self.ddos_guard_url, solution.url)
self.assertEqual(solution.status, 200) self.assertEqual(solution.status, 200)
self.assertIs(len(solution.headers), 0) self.assertIs(len(solution.headers), 0)
self.assertIn("<title>AniDex</title>", solution.response) self.assertIn("<title>Литрес", solution.response)
self.assertGreater(len(solution.cookies), 0) self.assertGreater(len(solution.cookies), 0)
self.assertIn("Chrome/", solution.userAgent) self.assertIn("Chrome/", solution.userAgent)

View File

@@ -58,18 +58,21 @@ def create_proxy_extension(proxy: dict) -> str:
manifest_json = """ manifest_json = """
{ {
"version": "1.0.0", "version": "1.0.0",
"manifest_version": 2, "manifest_version": 3,
"name": "Chrome Proxy", "name": "Chrome Proxy",
"permissions": [ "permissions": [
"proxy", "proxy",
"tabs", "tabs",
"unlimitedStorage",
"storage", "storage",
"<all_urls>",
"webRequest", "webRequest",
"webRequestBlocking" "webRequestAuthProvider"
], ],
"background": {"scripts": ["background.js"]}, "host_permissions": [
"<all_urls>"
],
"background": {
"service_worker": "background.js"
},
"minimum_chrome_version": "76.0.0" "minimum_chrome_version": "76.0.0"
} }
""" """
@@ -154,6 +157,7 @@ def get_webdriver(proxy: dict = None) -> WebDriver:
proxy_extension_dir = None proxy_extension_dir = None
if proxy and all(key in proxy for key in ['url', 'username', 'password']): if proxy and all(key in proxy for key in ['url', 'username', 'password']):
proxy_extension_dir = create_proxy_extension(proxy) proxy_extension_dir = create_proxy_extension(proxy)
options.add_argument("--disable-features=DisableLoadExtensionCommandLineSwitch")
options.add_argument("--load-extension=%s" % os.path.abspath(proxy_extension_dir)) options.add_argument("--load-extension=%s" % os.path.abspath(proxy_extension_dir))
elif proxy and 'url' in proxy: elif proxy and 'url' in proxy:
proxy_url = proxy['url'] proxy_url = proxy['url']

View File

@@ -1 +1 @@
WebTest==3.0.6 WebTest==3.0.7