Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added option for overload SSL rules #117

Closed
wants to merge 11 commits into from

Conversation

Shark-vil
Copy link

@Shark-vil Shark-vil commented May 17, 2021

A similar problem

开启了SSL然后无法打开 - #111


Description of changes

I had problems using the API for my server. Java refused to accept Let's Encrypt certificates. To do this, I added an option to override certificate validation rules.

To enable the option in the launch parameters, you need to add:

-Dauthlibinjector.trustUnknownSSLCertificates

or

-Dauthlibinjector.trustUnknownSSLCertificatesOptional

The user will receive a warning that this method is not reliable and not recommended, however, this will fix the problem with the inability to send requests to the server.

Shark-vil added 9 commits May 17, 2021 05:19
@Shark-vil
Copy link
Author

It is noteworthy that the problem is observed exclusively on the client (player) side. The server starts and runs without changing the certificate validation rules.

Shark-vil added 2 commits May 17, 2021 07:24
@Shark-vil
Copy link
Author

Shark-vil commented May 17, 2021

Added the ability to change rules only if an error occurs. Thought about it after my post above. I don't know why the client cannot connect to the site, unlike the game server, which connects smoothly.

@yushijinhun
Copy link
Owner

I don't think this problem has anything to do with authlib-injector. Instead, it signals that your authentication server is misconfigured, or the client Java installation is outdated or broken. So, this PR will not be merged.

If you encounter a TLS certificate problem:

  1. Ensure your server is providing a valid certificate, and the certificate chain is complete.
  2. If the client is using Java 8, the Java version should be at least 8u101. (see Let's Encrypt Certificate Compatibility)
  3. If the problem still exists and occurs on a particular machine only, maybe the Java installation is broken, or someone is trying to hijack TLS traffic.

@LTCatt
Copy link

LTCatt commented Dec 13, 2024

目前 Mojang 官方所使用的 Java 是 8u51,会触发这一问题。
考虑到兼容性,能否重新考虑合并?

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.

3 participants