5 ms·
that's #16, though perhaps I should just say that the reason the response is empty is that Google is redirecting you. I'd love more suggestions for curl exercis
by jvns 7y ago
that's #16, though perhaps I should just say that the reason the response is empty is that Google is redirecting you. I'd love more suggestions for curl exercises though :)
- spurgu 7y agoYeah although I'm getting this: <HTML><HEAD><meta http-equiv="content-type" content="text/html;charset=utf-8"> <TITLE>301 Moved</TITLE></HEAD><BODY> <H1>301 Moved</H1> The document has moved <A HREF="https://www.google.com/">here</A>. </BODY></HTML> So not an empty response...
- ben174 7y agoYea looks like they've changed it to output HTML fallback now. Presumably for browsers which don't respect the redirect status code. This document must predate that change.
- andmarios 7y agoAh, I missed it! Another exercise could be to have a page where the Access Control Allow Origin is set to a specific domain, then make a request by setting a different origin. E.g: curl -H "Origin: https://wrong.origin.com" https://httpbin.org/anything Many people think CORS is enforced by the server.
- thakoppno 7y agoDo you have one that uses `––resolve`?
- rmetzler 7y agoI thought, the idea of the parent was to teach the user how to follow redirects.