Skip to content

Conversation

@stackinspector
Copy link
Contributor

When I tried to compile this project on my Linux VM, I found an error while compiling openssl-sys. Certainly the reason was OpenSSL development package was not configured, but this is not important. What actually matters is that a project that claims to use rustls and hyper-rustls is compiling with dependency to OpenSSL! It must be a configuration issue somewhere, like some library introducing both by default, I thought. So I looked up the dependency chain for openssl-sys and eventually found hyper-tls, which is the support library for hyper's use of native TLS. I tried to remove this dependency to find where it was used, and found that only http client of proxy used its HttpsConnector. Thinking that this was probably an oversight, I tried to replace the dependency with hyper-rustls and its HttpsConnector, and found that did not raise any compiler errors.

About Cargo.lock: I have a habit of running cargo update before commiting the code after modifying a project. When I modified this project and ran cargo update, I found that Cargo.lock had several hundred lines of changes. I was a little surprised and thought this might not be a normal occurrence for a project that more than half of commits are by dependabot. I don't use dependabot, and maybe dependabot doesn't recursively update the dependencies in Cargo.lock as cargo update does. Anyway it's up to you whether to merge changes in Cargo.lock or not.

By the way, I tried to start this server on my two Windows machines (one runs Windows Server and the other runs Windows 10) and found that it could not access any files on both machines, any request to access files and directories (include /) returned status 403 with content Access declined. (os error 5). On both Linux and Windows it cannot read any certificate and key files (standard RSA certificate and key in plain text which works properly with Nginx), prompting The provided certificate is empty, I checked the code and found that maybe it is a problem with reading buffers. To both problems I have no clue until present, and can't determine whether it's a problem with the project or my environment.

@LeoBorai
Copy link
Member

Hi @stackinspector! Thanks for opening this PR and collaborating with this project and helping making it better.

To answer your points above:

By the way, I tried to start this server on my two Windows machines (one runs Windows Server and the other runs Windows 10) and found that it could not access any files on both machines, any request to access files and directories (include /) returned status 403 with content Access declined. (os error 5).

This sounds related to how paths are provided to the FileExplorer on Windows, perhaps I have to check current environment/OS and build the path accordingly. Thanks for noticing! Do you mind opening an issue for this so we track it there? At the moment I don't have access to any Windows system, but I'm happy to help you if you want to give it a shot as well.

On both Linux and Windows it cannot read any certificate and key files (standard RSA certificate and key in plain text which works properly with Nginx), prompting The provided certificate is empty, I checked the code and found that maybe it is a problem with reading buffers. To both problems I have no clue until present, and can't determine whether it's a problem with the project or my environment.

If you feel like opening another issue for this one please do! I can give it a shot during the week.

@LeoBorai
Copy link
Member

LeoBorai commented Apr 25, 2022

@stackinspector looks like all CI workflows are working correctly but clippy. Can you please apply clippy suggestions?

If you could squash together a481573 and the clippy fixes it would be great. I would keep 853122b on a single commit because is not directly related to your changes to support the TLS crate.

Thanks in advance!

@stackinspector
Copy link
Contributor Author

If you could squash together a481573 and the clippy fixes it would be great. I would keep 853122b on a single commit because is not directly related to your changes to support the TLS crate.

Sorry, I didn't understand how I should perform the operation you described. Make another commit to apply clippy fixes? Force yank 853122b with git push -f? I'm not very experienced on git and just confused.

@LeoBorai
Copy link
Member

@stackinspector don't worry! Just run cargo clippy and then push another commit as usual to this branch.

@stackinspector
Copy link
Contributor Author

Okay, it's now finished. I just kind of missed your point before.

@LeoBorai
Copy link
Member

Okay, it's now finished. I just kind of missed your point before.

No worries!

Copy link
Member

@LeoBorai LeoBorai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

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.

2 participants