Hidden features of HTTP

前端 未结 13 1107
醉话见心
醉话见心 2021-01-29 17:38

What hidden features of HTTP do you think are worth mentioning?

By hidden features I mean features that already are part of the standard but widely rath

13条回答
  •  逝去的感伤
    2021-01-29 18:00

    Status codes :

    • When URI http://www.domain.invalid/index.php?id=44 is called, if the query (id=44) couldn't return ressource, why not return a status code 404?
    • When URI http://www.domain.invalid/index.php?id=foo is called whereas id only accepts integers, why not return a status code 400?
    • Why, when you enter the wrong login/password, almost all web application return a message like "Authentication failed" with status code 200 (ok, no problem, you do it well) instade of 401?

    Yes, status codes seems to be a kind of secret functionality of HTTP to some web developers... But I wonder if the most occult of all the "features" of this protocol isn't its RFC!

提交回复
热议问题