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

fix: reenable allowInsecure #3082

Closed
wants to merge 1 commit into from
Closed

Conversation

mkmark
Copy link
Contributor

@mkmark mkmark commented Jul 18, 2024

@xiaokangwang xiaokangwang added the Extensive Review Required Require an extensive review from organization owner, cannot be merged without owner approval label Aug 19, 2024
@xiaokangwang
Copy link
Contributor

Hi! I have reviewed your merge request and would like to suggest an alternative.

Instead of allowing "allow_insecure", what is your opinion about adding an new option:"allow_insecure_if_certificate_pinned"? It will enable "allow_insecure" if the certificate is pinned, and return an error otherwise. This would allow any certificate to be used if MITM is already prevented by certificate pinning, and does not allow someone to disable certificate verification when they have been MITMed.

@mkmark
Copy link
Contributor Author

mkmark commented Aug 31, 2024

The bottom line was to make v2ray work under certain conditions, such as connecting to a server via https albeit the server certificate is self-signed. This is sometimes for obfuscation purpose rather than for encryption, which is quite common, So, allow_insecure_if_certificate_pinned should work in this regard.

In my personal opinion though, the good old "allow_insecure" is enough, since the purpose is to alert, and the user is alerted when writing the configuration.

On the other hand, I guess the purpose of this breaking change is to remind users that there are now new features to enhance security? I honestly don't know if it's a little overkill for this purpose...

@xiaokangwang
Copy link
Contributor

I understand your concern about just make things works. However, with the rise of popularity of unobfuscated protocols like trojan and vless allow firewall to identify these protocol by temporarily MITM the tls connection to attempt to inspect the content. For this reason allow insecure over internet adversely impact the anti-censorship ability of V2Ray.

@mkmark
Copy link
Contributor Author

mkmark commented Sep 1, 2024

ChatGPT suggests allow_pinned_insecure or allow_insecure_with_pinning. All good to me though!


Unimportant: An elaboration for typical cases where MITM is considered unimportant: sometimes (unsure if popular) v2ray is used within campus/corporate LAN to circumvent local firewall rules without exposing its usage to LAN admins, and privacy is considered justified against unnecessarily strict internal censorship. In such cases, LAN servers usually have only self-signed certificates, and local MITM for active v2ray detection is unlikely.

At least, nothing should tarnish v2ray's reputation when it's user/3rd-party specifying allow_insecure.

@xiaokangwang
Copy link
Contributor

I will just go ahead and create a separate pull request based on the allow insecure if certificate pinned system.

The issue here is that, I believe the temporary MITM attack system is not necessarily only from local network but could from ISP as well. Even github was once MITMed by GFW.

I understand that the user are ultimately responsible for their own action, but if there is something I could do I may just do it.

@xiaokangwang
Copy link
Contributor

It is closed because another merge request have supersede its functionality. Feel free to open again if there is something unaddressed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Extensive Review Required Require an extensive review from organization owner, cannot be merged without owner approval
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants