❔ VS Debug Bad Request - Invalid Hostname
I am new to dot net and I am supposed to implement some frontend. I have cloned the project, I am supposed to run it on IIS Express. I've fixed ssl certificate and now I'm facing Bad Request Invalid Hostname when I run debug on IIS Express in Visual Studio..
I've tried changing both ...\Site\Site.vs\Site\config\applicationhost.config and ~documents\IIS Express\config\applicationhost.config
like so:
I've tried changing browsers, deleting ...\Site.vs folder and then running it again
None of those worked
16 Replies
Could it be something with the code ?
I see no IIS Express logs :/ is there any way I could find some logs to help solving this question
IIS express 😬
is there an alternative? I don't know anyone that uses IIS anymore
oooh is it that ancient ? 😄
I was just instructed to use IIS Express, other choices like https/http debug threw an error
what kind of a front-end do you have?
update: I don't know what I have done, but https debug "works" now with same response
pure html css js
no api fetching
and you're running it locally or on a server?
cloned repo running it locally
meaning invalid hostname
you can just open the html file in your browser
the company has setup pipeline around .net, I will try to talk about options with them
or I could just copy and paste the code from my local html,css,js thing hoping it will work since cloned code is from live server, dunno 😄 life is strange
vice versa of "it works on my machine" 😄 😄 😄
What makes you ask that?
Yep. I've given up, now I just copy paste from local files into cloned files -> pull request and pray to god this time there are no issues
I've even tried commenting out the "::1 localhost" from hosts file in windows>system32>.. dont remember full path kek
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity. dont try me Accord
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.life is strange, I can say with 100% confidence I have something out of the ordinary setup in windows. Bindings are correctly setup in IIS Express, Hosts file in windows drivers looks fine, Only thing I would be sussy of is Windows Subsystem Linux which docker is using all the time
Was this issue resolved? If so, run
/close
- otherwise I will mark this as stale and this post will be archived until there is new activity.