With Domain Name Cannot Access Collections in Content Manager

System Information
  • Strapi Version: v4.10.1
  • Operating System: Windows Server 2022 Standard
  • Database: sqlite
  • Node Version: v16.17.0
  • NPM Version: 9.6.0
  • Yarn Version: n/a

I apologize for having to ask – I normally like to work through these issues on my own, but I am under a bit of a time constraint.

I gave my locally hosted strapi instance a custom domain name. It is served via IIS (it’s what I have to work with) and a reverse proxy. All works fine except when I try to manage my collections under content manager. The browser console tells me:

Failed to load resource: the server responded with a status of 400 () /content-manager/content-types/api::department.department/configuration:1

and…

Sncode: "ERR_BAD_REQUEST"config: {transitional: {…}, adapter: Array(2), transformRequest: Array(1), transformResponse: Array(1), timeout: 0, …}message: "Request failed with status code 400"name: "AxiosError"request: XMLHttpRequest {onreadystatechange: null, readyState: 4, timeout: 0, withCredentials: false, upload: XMLHttpRequestUpload, …}response: {data: '<!DOCTYPE html>\r\n<html>\r\n    <head>\r\n        <titl…\r\n\r\n            </font>\r\n\r\n    </body>\r\n</html>\r\n', status: 400, statusText: '', headers: qt, config: {…}, …}stack: "AxiosError: Request failed with status code 400\n    at Ve (https://***.***.***/admin/main.fbf1eefc.js:2280:1042)\n    at XMLHttpRequest.Cn (https://***.***.***/admin/main.fbf1eefc.js:2280:4410)"[[Prototype]]: Error
(anonymous) @ content-manager.f8779075.chunk.js:114

However, if I visit by local IP I can access/edit everything as normal.

What steps should I take to resolve? I have another issue that necessitates its own thread. That issue has been resolved, too.

Thanks,
Dan

I don’t know if this helps, but as I check server side I am getting a peculiar error message from IIS:

A potentially dangerous Request.Path value was detected from the client (:).
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.Web.HttpException: A potentially dangerous Request.Path value was detected from the client (:).

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[HttpException (0x80004005): A potentially dangerous Request.Path value was detected from the client (:).]
   System.Web.HttpRequest.ValidateInputIfRequiredByConfig() +11790877
   System.Web.PipelineStepManager.ValidateHelper(HttpContext context) +54

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.4494.0```

This always happens to me. As soon as I reach out, I find a solution. I had to add the following to my web.config:

<system.web>
    <httpRuntime requestPathInvalidCharacters="" requestValidationMode="2.0" />
    <pages validateRequest="false" />
</system.web>

That part of my site is behaving correctly, now. Sorry for the bother but I hope this helps someone else in the future.

Thanks,
Dan

2 Likes

Hi Dan, i was live this fuckin’ issue. Thanks for help dude. Thank you so much <3

1 Like

You’re welcome!