-
Notifications
You must be signed in to change notification settings - Fork 178
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
Listen to localhost, handle request with arbitrary Host headers #165
Comments
This is not a bug, this is how Some useful links: https://www.codeproject.com/Articles/437733/Demystify-http-sys-with-HttpSysManager |
Strong binding with "+" understood, But when using "http://+:12345" the webserver binds to 0.0.0.0. My goal: bind to localhost, serve all requests. |
Yeah, because 0.0.0.0 is a placeholder to say anything is valid. I'm not understanding, why don't you use '+' or '*'? Is it because of permissions? |
For security reasons embedio should listen only on internal loop interface but should handle requests independently of the Host-Header (another process forwards external HTTP requests to embedio that listens on localhost): What I tried:
Is there a simple solution for what I want ? |
You can add both loopback in the
|
2+ years later, I am deploying EmbedIO into docker for a health check for a console C# dotnetcore app. I had issues with binding to http://0.0.0.0:, but once I set my config to use http://*: - my app finally started working with Kubernetes. Yes, 2 years late but I only started with the dotnet world 2 weeks ago. Good framework really! Very light (bah, lite) framework. Hardly added anything to my Docker image |
Hello,
I want that embedio bind to localhost interface, (URL prefix: http://localhost:12345) but it should handle all incoming requests, independent of the host header.
Currently, if the host header is not localhost (i.e. 127.0.0.1 or something different) it doesn't handle the request.
Is this feature, a bug, my fault ?
Best regards
MrDigit
The text was updated successfully, but these errors were encountered: