T08 · Insecure Dependencies
- Location
scripts/github_fetch.py:25- Finding
Unverified content from third-party mirrors can be extracted and installed
- Content
View full analysis
tuple[str | None, str | None, float]: """Direct connection first; probe proxies if it is unusable.""" ok, speed, code = probe_speed(gh_url, timeout) if ok and speed >= min_speed: return gh_url, "direct", speed print(f"[i] Direct connection unavailable; probing proxy mirrors...") best_url, best_name, best_speed = None, None, 0.0 for p in proxies: proxied = f"{p}/{gh_url}" ok, sp, code = probe_speed(proxied, timeout) if ok and sp > best_speed: best_url, best_name, best_speed = proxied, p, sp return best_url, best_name, best_speed ``` The original source uses localized display strings, but the control flow above is reproduced without alteration. ```python if not download(best_url, dest, timeout=args.timeout): sys.exit(1) # Verification if not verify(dest, args.sha256, args.verify_url): print("[x] Verification failed; file deleted") dest.unlink(missing_ok=True) sys.exit(1) # Extraction extracted = None if args.extract: extracted = extract(dest, out_dir) # Installation if args.install: src = extracted or dest install(src, Path(args.install)) ``` The quick-start documentation demonstrates extraction and installation without supplying a checksum: ```bash python3 scripts/github_fetch.py "https://github.com/BtbN/FF ...[truncated 2326 chars]- Remediation
View remediation
