CloakBrowser Pro v0.5.11 cannot bypass cloudflare in AWS Lambda on .NET
I have a Cloakbrowser pro installed locally on ubuntu 26.04, version 152.0.7977.82.1.
I hooked it up to my playwright locally and it bypasses the required websites cloudflare turnstiles, even in headless mode.
When I hook it up to a simple AWS Lambda, no funky networking or VPCs with 2GB Ram detailed below, it fails cloudflare turnstile. Could you offer any pointers?
Details CloakBrowser version: v0.5.11 / 152.0.7977.82.1 Wrapper: .NET Environment: Docker Image cloakhq/cloakbrowser:0.5.11
FROM cloakhq/cloakbrowser:0.5.11
ARG CLOAKBROWSER_LICENSE_KEY
ARG DOTNET_VERSION=10.0.12
ARG CHROME_VERSION=152.0.7977.82.1
COPY entrypoint.sh /entrypoint.sh
RUN chmod +x /entrypoint.sh
# Install .NET 10 runtime
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
curl \
ca-certificates \
tar \
xvfb \
x11-utils \
xz-utils \
gzip \
libicu76 \
&& curl -fSL \
"https://builds.dotnet.microsoft.com/dotnet/Runtime/${DOTNET_VERSION}/dotnet-runtime-${DOTNET_VERSION}-linux-x64.tar.gz" \
-o /tmp/dotnet.tar.gz \
&& mkdir -p /usr/share/dotnet \
&& tar -xzf /tmp/dotnet.tar.gz -C /usr/share/dotnet \
&& ln -sf /usr/share/dotnet/dotnet /usr/bin/dotnet \
&& rm -f /tmp/dotnet.tar.gz \
&& rm -rf /var/lib/apt/lists/*
# Install fonts
COPY windows-fonts.tar.xz /tmp/fonts/windows-fonts.tar.xz
RUN mkdir -p /usr/local/share/fonts/windows \
&& tar -xJf /tmp/fonts/windows-fonts.tar.xz -C /usr/local/share/fonts/windows \
&& rm -f /tmp/fonts/windows-fonts.tar.xz \
&& fc-cache -f
# Lambda application
WORKDIR /var/task
COPY --from=build /app/publish .
ENV HOME=/tmp \
BrowserSettings__Headless=false \
BrowserSettings__UseWindowsFontMetrics=true \
CLOAKBROWSER_CACHE_DIR=/tmp/.cloakbrowser \
CLOAKBROWSER_VERSION=${CHROME_VERSION} \
CLOAKBROWSER_AUTO_UPDATE=false \
CLOAKBROWSER_BINARY_PATH=/root/.cloakbrowser/chromium-${CHROME_VERSION}-pro/chrome \
DEBUG=pw:browser,pw:api \
DISPLAY=:99
# Install Geoip
RUN mkdir -p /root/.cloakbrowser/geoip \
&& curl -fL \
"https://github.com/P3TERX/GeoLite.mmdb/raw/download/GeoLite2-City.mmdb" \
-o /root/.cloakbrowser/geoip/GeoLite2-City.mmdb
# Install Latest Cloak Browser
RUN curl -fL -H "X-Platform: linux-x64" -H "Authorization: Bearer ${CLOAKBROWSER_LICENSE_KEY}" "https://cloakbrowser.dev/api/download/${CHROME_VERSION}" -o /tmp/cloakbrowser.tar.gz \
&& mkdir -p /root/.cloakbrowser/chromium-${CHROME_VERSION}-pro \
&& tar -xzf /tmp/cloakbrowser.tar.gz -C /root/.cloakbrowser/chromium-${CHROME_VERSION}-pro \
&& rm -f /tmp/cloakbrowser.tar.gz \
&& chmod -R o+rX /root /root/.cloakbrowser
ENTRYPOINT ["/entrypoint.sh"]entrypoint.sh:
#!/bin/sh
set -e
mkdir -p /tmp/.X11-unix
chmod 1777 /tmp/.X11-unix 2>/dev/null || true
# Remove stale Xvfb state
rm -f /tmp/.X99-lock /tmp/.X11-unix/X99
# Start virtual X server
Xvfb :99 -screen 0 1920x1080x24 -nolisten tcp >/tmp/Xvfb.log 2>&1 &
# Wait for Xvfb to create its socket
i=0
while [ ! -e /tmp/.X11-unix/X99 ] && [ "$i" -lt 200 ]; do
i=$((i + 1))
sleep 0.05
done
# Give Xvfb a moment to become ready
until xdpyinfo -display :99 >/dev/null 2>&1; do
sleep 0.05
done
# Start the .NET Lambda bootstrap
exec /usr/bin/dotnet exec /var/task/LambdaApplication.dllLaunch options:
await CloakLauncher.LaunchContextAsync(new LaunchContextOptions()
{
Headless = false,
Humanize = true,
GeoIp = true,
Viewport = (1920, 1080),
LicenseKey = "*********",
Proxy = null,Day.Empire.Function.CardMarketCommandExecutor
Args = [
"--disable-dev-shm-usage",
"--fingerprint=25565",
"--no-zygote",
"--fingerprint-windows-font-metrics"
]
});Tested with a different IP or proxy? Yes, Locally, with and without proxy, same result.
Works outside Docker / on host machine? Yes.
Error output / screenshots: I get these errors, but the browser does boot, and starts navigating. I then get the eternal spinning of cloudflare turnstile redirects.
2026-09-30T13:37:28.858Z
2026-09-30T13:37:28.858Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:37:28.840Z pw:browser <launching> /root/.cloakbrowser/chromium-152.0.7977.82.1-pro/chrome --disable-field-trial-config --disable-background-networking --disable-background-timer-throttling --disable-backgrounding-occluded-windows --disable-back-forward-cache --disable-breakpad --disable-client-side-phishing-detection --disable-component-extensions-with-background-pages --disable-component-update --no-default-browser-check --disable-default-apps --disable-dev-shm-usage --disable-extensions --disable-features=ImprovedCookieControls,LazyFrameLoading,GlobalMediaControls,DestroyProfileOnBrowserClose,MediaRouter,DialMediaRouteProvider,AcceptCHFrame,AutoExpandDetailsElement,CertificateTransparencyComponentUpdater,AvoidUnnecessaryBeforeUnloadCheckSync,Translate,HttpsUpgrades,PaintHolding,ThirdPartyStoragePartitioning,LensOverlay,PlzDedicatedWorker --allow-pre-commit-input --disable-hang-monitor --disable-ipc-flooding-protection --disable-popup-blocking --disable-prompt-on-repost --disable-renderer-backgrounding --force-color-profile=srgb --metrics-recording-only --no-first-run --password-store=basic --use-mock-keychain --no-service-autorun --export-tagged-pdf --disable-search-engine-choice-screen --unsafely-disable-devtools-self-xss-warnings --no-sandbox --no-sandbox --fingerprint=25565 --fingerprint-platform=windows --ignore-gpu-blocklist --disable-dev-shm-usage --no-zygote --fingerprint-windows-font-metrics --fingerprint-webrtc-ip=13.41.76.50 --enable-features=MediaRouter --fingerprint-timezone=Europe/London --lang=en-GB --fingerprint-locale=en-GB --user-data-dir=/tmp/playwright_chromiumdev_profile-kuOde0 --remote-debugging-pipe --no-startup-window
2026-09-30T13:37:28.874Z
2026-09-30T13:37:28.874Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:37:28.874Z pw:browser <launched> pid=40
2026-09-30T13:37:30.298Z
2026-09-30T13:37:30.298Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:37:30.298Z pw:browser [pid=40][err] [40:52:0930/133730.297567:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
2026-09-30T13:37:30.298Z
2026-09-30T13:37:30.298Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:37:30.298Z pw:browser [pid=40][err] [40:52:0930/133730.297656:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:43.295Z
2026-09-30T13:38:43.295Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:43.294Z pw:browser [pid=40][err] [40:52:0930/133843.294116:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
2026-09-30T13:38:43.295Z
2026-09-30T13:38:43.295Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:43.294Z pw:browser [pid=40][err] [40:52:0930/133843.294157:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Failed to connect to socket /run/dbus/system_bus_socket: No such file or directory
2026-09-30T13:38:43.295Z
2026-09-30T13:38:43.295Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:43.294Z pw:browser [pid=40][err] [40:52:0930/133843.294167:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:45.318Z
2026-09-30T13:38:45.318Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:45.318Z pw:browser [pid=40][err] [40:52:0930/133845.318250:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:46.123Z
2026-09-30T13:38:46.123Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.122Z pw:browser [pid=40][err] [40:40:0930/133846.122491:ERROR:dbus/object_proxy.cc:572] Failed to call method: org.freedesktop.DBus.NameHasOwner: object_path= /org/freedesktop/DBus: unknown error type:
2026-09-30T13:38:46.123Z
2026-09-30T13:38:46.123Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.123Z pw:browser [pid=40][err] [40:52:0930/133846.122607:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:46.125Z
2026-09-30T13:38:46.125Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.125Z pw:browser [pid=40][err] [40:40:0930/133846.125498:ERROR:dbus/object_proxy.cc:572] Failed to call method: org.freedesktop.DBus.NameHasOwner: object_path= /org/freedesktop/DBus: unknown error type:
2026-09-30T13:38:46.126Z
2026-09-30T13:38:46.126Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.126Z pw:browser [pid=40][err] [40:52:0930/133846.126216:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:46.130Z
2026-09-30T13:38:46.130Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.130Z pw:browser [pid=40][err] [40:40:0930/133846.129920:ERROR:dbus/object_proxy.cc:572] Failed to call method: org.freedesktop.DBus.NameHasOwner: object_path= /org/freedesktop/DBus: unknown error type:
2026-09-30T13:38:46.178Z
2026-09-30T13:38:46.178Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.177Z pw:browser [pid=40][err] [40:40:0930/133846.177383:ERROR:dbus/object_proxy.cc:572] Failed to call method: org.freedesktop.DBus.NameHasOwner: object_path= /org/freedesktop/DBus: unknown error type:
2026-09-30T13:38:46.178Z
2026-09-30T13:38:46.178Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.177Z pw:browser [pid=40][err] [40:40:0930/133846.177541:ERROR:dbus/object_proxy.cc:572] Failed to call method: org.freedesktop.DBus.NameHasOwner: object_path= /org/freedesktop/DBus: unknown error type:
2026-09-30T13:38:46.179Z
2026-09-30T13:38:46.179Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.179Z pw:browser [pid=40][err] [40:52:0930/133846.178886:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:46.191Z
2026-09-30T13:38:46.191Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.191Z pw:browser [pid=40][err] [40:40:0930/133846.190934:ERROR:dbus/object_proxy.cc:572] Failed to call method: org.freedesktop.DBus.NameHasOwner: object_path= /org/freedesktop/DBus: unknown error type:
2026-09-30T13:38:46.191Z
2026-09-30T13:38:46.191Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.191Z pw:browser [pid=40][err] [40:52:0930/133846.191161:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:46.218Z
2026-09-30T13:38:46.218Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.215Z pw:browser [pid=40][err] [40:40:0930/133846.215620:ERROR:dbus/object_proxy.cc:572] Failed to call method: org.freedesktop.DBus.NameHasOwner: object_path= /org/freedesktop/DBus: unknown error type:
2026-09-30T13:38:46.218Z
2026-09-30T13:38:46.218Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.216Z pw:browser [pid=40][err] [40:52:0930/133846.215710:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:46.223Z
2026-09-30T13:38:46.223Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.223Z pw:browser [pid=40][err] [40:40:0930/133846.222882:ERROR:dbus/object_proxy.cc:572] Failed to call method: org.freedesktop.DBus.NameHasOwner: object_path= /org/freedesktop/DBus: unknown error type:
2026-09-30T13:38:46.224Z
2026-09-30T13:38:46.224Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.223Z pw:browser [pid=40][err] [40:50:0930/133846.223876:ERROR:net/cert/ev_root_ca_metadata.cc:161] Failed to decode OID: 0
2026-09-30T13:38:46.445Z
2026-09-30T13:38:46.445Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.445Z pw:browser [pid=40][err] [40:52:0930/133846.445065:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
2026-09-30T13:38:46.445Z
2026-09-30T13:38:46.445Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:46.445Z pw:browser [pid=40][err] [40:52:0930/133846.445105:ERROR:dbus/bus.cc:405] Failed to connect to the bus: Could not parse server address: Unknown address type (examples of valid types are "tcp" and on UNIX "unix")
------
2026-09-30T13:38:51.181Z
2026-09-30T13:38:51.181Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 dbug https://www.cardmarket.com/cdn-cgi/challenge-platform/h/b/fo/153462125:1790773220:qJ0L3uI4su2ykaea-qyD0FjEGgtKn_hJxSjKXPXhfAk/a433a14feaf4208b/5A_SxIni8TSTw.48g_NnpvSpyCpNYWnieOhgk0RRJLI-1790775528-1.2.1.1-sTVC9U9aRwOyu7iOyZUfNzn3Sc63aFicF7qXrOJfsjAJUWQHBZW_TRH3CDFc.UBQ
2026-09-30T13:38:51.181Z
2026-09-30T13:38:51.181Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.181Z pw:api "load" event fired
2026-09-30T13:38:51.322Z
2026-09-30T13:38:51.322Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 dbug https://challenges.cloudflare.com/cdn-cgi/challenge-platform/h/b/turnstile/f/av0/rch/huph8/0x4AAAAAAADnPIDROrmt1Wwj/light/fbE/new/normal?lang=auto
2026-09-30T13:38:51.382Z
2026-09-30T13:38:51.381Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.380Z pw:browser [pid=40][err] [74:82:0930/133851.379881:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun.cloudflare.com., errorcode: -105
2026-09-30T13:38:51.382Z
2026-09-30T13:38:51.382Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.380Z pw:browser [pid=40][err] [74:82:0930/133851.379942:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun.cloudflare.com., errorcode: -105
2026-09-30T13:38:51.382Z
2026-09-30T13:38:51.382Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.380Z pw:browser [pid=40][err] [74:82:0930/133851.379950:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun.cloudflare.com., errorcode: -105
2026-09-30T13:38:51.399Z
2026-09-30T13:38:51.398Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.398Z pw:browser [pid=40][err] [74:82:0930/133851.398673:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun1.l.google.com., errorcode: -105
2026-09-30T13:38:51.399Z
2026-09-30T13:38:51.399Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.398Z pw:browser [pid=40][err] [74:82:0930/133851.398712:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun1.l.google.com., errorcode: -105
2026-09-30T13:38:51.399Z
2026-09-30T13:38:51.399Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.398Z pw:browser [pid=40][err] [74:82:0930/133851.398721:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun1.l.google.com., errorcode: -105
2026-09-30T13:38:51.399Z
2026-09-30T13:38:51.399Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.398Z pw:browser [pid=40][err] [74:82:0930/133851.398745:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun.l.google.com., errorcode: -105
2026-09-30T13:38:51.399Z
2026-09-30T13:38:51.399Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.398Z pw:browser [pid=40][err] [74:82:0930/133851.398753:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun.l.google.com., errorcode: -105
2026-09-30T13:38:51.399Z
2026-09-30T13:38:51.399Z 2ab07b3f-a3a6-5296-974e-1808b16462c2 fail 2026-09-30T13:38:51.398Z pw:browser [pid=40][err] [74:82:0930/133851.398761:ERROR:services/network/p2p/socket_manager.cc:163] Failed to resolve address for stun.l.google.com., errorcode: -105
Additional notes:
- There is also a small issue within the
License.csfile I noticed, where it will try and cache the License in the cache dir at boot, which in a lambda is not writable, so I have to use the Binary Override env var - I'm thinking of raising a quick PR that allows you to specify a path a Env Var for the license cache, so I can place it under /tmp for lambdas, then I can revert the Cache Dir to /root. - Is there a Dockerfile you intend to release with the latest pro binary installed? Im using your dockerfile, even though I have to install alot of additional dependencies, as I assume cloakbrowser has all kinds of dependencies, settings and what have you in the base image I'd like to use - Is this the best approach, i.e. is the binary actually standalone, at which point I can perhaps build my own image based more closely to local (which works)
Source: CloakHQ/CloakBrowser