Skip to content

🔒 fix(service): secure Appium service TLS verification - #9

Open
Dor-bl wants to merge 3 commits into
masterfrom
fix/tls-verification-12885584134159669316
Open

🔒 fix(service): secure Appium service TLS verification#9
Dor-bl wants to merge 3 commits into
masterfrom
fix/tls-verification-12885584134159669316

Conversation

@Dor-bl

@Dor-bl Dor-bl commented Aug 10, 2026

Copy link
Copy Markdown
Owner

🎯 What:
The urllib3.PoolManager instance in is_service_listening lacked TLS certificate verification, meaning that connections to HTTPS URLs were vulnerable to man-in-the-middle (MITM) attacks because any presented certificate would be implicitly accepted.

⚠️ Risk:
If an attacker could intercept the connection between the Appium service startup check and the remote service URL when using HTTPS, they could present a fraudulent certificate. This could result in information disclosure or allow an attacker to forge service status responses during the initialization phase, although local Appium instances commonly use HTTP.

🛡️ Solution:
Updated urllib3.PoolManager initialization to include cert_reqs='CERT_REQUIRED'. Additionally, included a fallback try...except ImportError pattern to import certifi and pass its CA bundle via ca_certs if present, ensuring it functions gracefully in environments with or without the package.


PR created automatically by Jules for task 12885584134159669316 started by @Dor-bl

Enforce TLS verification when the Appium service URL uses HTTPS.
This updates `is_service_listening` to pass `cert_reqs='CERT_REQUIRED'`
to `urllib3.PoolManager`. It also optionally passes the `certifi` CA
bundle if it is available in the environment.
@google-labs-jules

Copy link
Copy Markdown

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

Dor-bl added 2 commits August 10, 2026 06:34
Enforce TLS verification when the Appium service URL uses HTTPS.
This updates `is_service_listening` to pass `cert_reqs='CERT_REQUIRED'`
to `urllib3.PoolManager`. It also optionally passes the `certifi` CA
bundle if it is available in the environment. Also fixes type annotations for `_ca_certs` to prevent mypy CI failures.
The previous latest release (0.0.34) of the appium-flutter-server repository
no longer has the app-debug.apk and ios.zip release assets, causing CI end-to-end
jobs to fail with 404s when attempting to download them. Pinned the asset URLs to
the 0.0.33 release where they actually exist to resolve this.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant