Skip to content

Add JVM flag and environment variable for bypassing region check - #7021

Closed
teddyxlandlee wants to merge 3 commits into
HMCL-dev:mainfrom
teddyxlandlee:patch-1
Closed

teddyxlandlee wants to merge 3 commits into
HMCL-dev:mainfrom
teddyxlandlee:patch-1

Conversation

@teddyxlandlee

Copy link
Copy Markdown

They can be triggered on Launcher startup, either:

  • by adding JVM flag -Dhmcl.bypassNetworkRegionCheck=true, or
  • by setting environment variable HMCL_BYPASS_NETWORK_REGION_CHECK to non-blank value.

@github-actions github-actions Bot added the 1+ label Oct 20, 2026
@Glavo Glavo closed this Oct 20, 2026
@teddyxlandlee

Copy link
Copy Markdown
Author

The decision to close this PR is understandable. Given the project’s current policy on the network region check and the related compliance concerns, it makes sense that a built-in bypass option is not something HMCL wants to merge or expose directly. This comment is not a request to reopen the PR or change that decision.

As an alternative, a standalone Java agent JAR could be uploaded/published outside the main repository. HMCL could then be launched with the -javaagent JVM parameter, for example:

java -javaagent:/path/to/HmclBypassRegionCheck-2.0.1.zip -jar HMCL.jar

(or -javaagent:... could be added to an existing launch command). In this approach, the bypass would be applied at runtime by the external agent, while the HMCL codebase and official releases would remain unchanged and would not ship or expose the bypass directly.

This would allow the project to keep its current policy, while users who explicitly want the workaround could opt in through an external agent. The JAR and usage instructions could be provided separately if such an external alternative is considered acceptable.

HmclBypassRegionCheck-2.0.1.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants