-
Notifications
You must be signed in to change notification settings - Fork 10.4k
Open
Labels
affected-very-fewThis issue impacts very few customersThis issue impacts very few customersarea-networkingIncludes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractionsIncludes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractionsbugThis issue describes a behavior which is not expected - a bug.This issue describes a behavior which is not expected - a bug.help candidateIndicates that the issues may be a good fit for community to help with. Requires work from eng. teamIndicates that the issues may be a good fit for community to help with. Requires work from eng. teamseverity-minorThis label is used by an internal toolThis label is used by an internal tool
Milestone
Description
Hello 👋
Describe the bug
Invalid Http/Https
binding can be defaulted without any log and go on
After few long minutes (hours?) of debugging we found out that invalid port configuration will not say anything and silent.
Why did it takes so long ?
Because we were looking for the https binding that was https://*:8443
on our POD, and it seems that another appsettings...json
file still had an http://*:{place.holder} that was not replaced
So it seems that it defaulted to port 80 without saying anything at all.
The behavior was AccessDeniedException
on a Socket
binding attempt (because Pods should not run as root so any binding bellow 1024 is forbidden)
Questions
so I wonder about 3 things now :
- should the SocketException / AccessDenied be explicit on the full binding url that was denied ? => http://[::]:80 or http://*:80`
- should there be at least a WARNING on the fact that a string with letter and placerhoder is probably not a valid URI / Port ?
- is there any form of URI that would makes this valid: http://*:{foo.bar.kix} with the port 80 ?
To Reproduce
dotnet new webapi
dotnet publish
cd ./bin/Debug/net5.0/publish/
$env:ASPNETCORE_URLS="https://*:{abc}"
./foo.exe
Further technical details
- ASP.NET Core version : both 3.1.x and 5.0-preview6
- Include the output of
dotnet --info
Metadata
Metadata
Assignees
Labels
affected-very-fewThis issue impacts very few customersThis issue impacts very few customersarea-networkingIncludes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractionsIncludes servers, yarp, json patch, bedrock, websockets, http client factory, and http abstractionsbugThis issue describes a behavior which is not expected - a bug.This issue describes a behavior which is not expected - a bug.help candidateIndicates that the issues may be a good fit for community to help with. Requires work from eng. teamIndicates that the issues may be a good fit for community to help with. Requires work from eng. teamseverity-minorThis label is used by an internal toolThis label is used by an internal tool