ESPAsyncWebServer icon indicating copy to clipboard operation
ESPAsyncWebServer copied to clipboard

[help] redirect all requests addressed to Hosts other than mine

Open atesin opened this issue 3 years ago • 1 comments

hi... i am learning how to use this lib ... it seems very useful and efficient

i am trying to write a custom captive portal ... since all local dns queries resolves to local ip, and local webserver will catch all http requests, i want to set default redirect all http requests other than my "official" host name to the correct one, but in can't figure out how to do it... for example:

http://captivedetection.google.com/any/url --> http://myportal.local/ (redirect) http://checkcaptive.amazon.com/some/url --> http://myportal.local/ (redirect) http://myportal.local/my/url --> host ok, continue processing the request normally (200 ok, 404, etc) http://myportal.local/other/url --> host ok, continue processing the request normally (200 ok, 404, etc)

atesin avatar Oct 03 '22 21:10 atesin

[STALE_SET] This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jun 18 '23 14:06 stale[bot]