Skip to content

Bubblewrap init fails with outdated User-Agent (403 Forbidden on some hosts) #984

Description

@MatteoMarzoli

Describe the bug
When running bubblewrap init on Windows 11 (64-bit) with Bubblewrap CLI v1.24.1, the tool fails to fetch the Web Manifest from certain hosts (e.g. Netsons) because the HTTP requests use an outdated User-Agent string. The server rejects the request with 403 Forbidden.

To Reproduce
Steps to reproduce the behavior:

  1. Run: bubblewrap init --manifest=https://tuner.netsons.org/manifest.webmanifest
  2. Observe the error:
    cli ERROR connect ETIMEDOUT 89.40.172.131:443
    or
    cli ERROR Unespected token '<', "<!DOCTYPE "... is not valid JSON

Or directly run:
curl -v -A "Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Firefox/81.0" https://tuner.netsons.org/manifest.webmanifest
→ returns 403 Forbidden.

Expected behavior
Bubblewrap should use a modern User-Agent (e.g. Chrome/120 or similar) when fetching the manifest, or allow the User-Agent to be configurable. This would prevent servers from rejecting the request.

Environment Desktop:

  • OS: Windows 11 64-bit
  • Bubblewrap CLI: 1.24.1
  • Node.js version: 22.21.0
  • Hosting provider: Netsons (Apache)

Additional context

  • The current User-Agent sent by Bubblewrap is: "Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Firefox/81.0"
  • This UA is considered outdated and blocked by some hosting providers.
  • Workarounds like using a local proxy to rewrite headers are fragile. A CLI option or updated default UA would solve the issue.

Suggested fix

  • Update the default User-Agent string in Bubblewrap to a modern Chrome UA.
  • Or add a CLI/config option to override the User-Agent used during init.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions