From d54dfe267136ff31fb6c1cb9b7637a999917975a Mon Sep 17 00:00:00 2001 From: Fredrik Tolf Date: Sun, 28 Jul 2024 19:26:23 +0200 Subject: [PATCH] Add info for more status codes. --- wrw/proto.py | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/wrw/proto.py b/wrw/proto.py index 2438c7c..5a2fee7 100644 --- a/wrw/proto.py +++ b/wrw/proto.py @@ -6,10 +6,39 @@ statusinfo = { 403: ("Forbidden", "You are not authorized to request the requested resource."), 404: ("Not Found", "The requested resource was not found."), 405: ("Method Not Allowed", "The request method is not recognized or permitted by the requested resource."), + 406: ("Not Acceptable", "No way was found to satisfy the given content-negotiation criteria."), + 407: ("Proxy Authentication Required", "Authentication must be provided to proxy the request."), + 408: ("Request Timeout", "The connection timed out."), + 409: ("Conflict", "The request conflicts with the live state."), + 410: ("Gone", "The requested resource has been deleted."), + 411: ("Length Required", "The requested resource requires the Content-Length header."), + 412: ("Precondition Failed", "The preconditions specified in the request are not met."), + 413: ("Payload Too Large", "The request entity is larger than permitted."), + 414: ("URI Too Long", "The requested URI is too long."), + 415: ("Unsupported Media Type", "The request entity format is not supported."), + 416: ("Range Not Satisfiable", "The specified Range cannot be satisfied."), + 417: ("Expectation Failed", "The expectation specified by the Expect header cannot be met."), + 421: ("Misdirected Request", "This server cannot handle the request."), + 422: ("Unprocessable Content", "The requet entity cannot be processed."), + 423: ("Locked", "The requested resource is locked."), + 424: ("Failed Dependency", "A previous required request failed."), + 425: ("TOo Early", "The requested action has already been performed."), + 426: ("Upgrade Required", "The requested resource is not available over this protocol."), + 428: ("Precondition Requred", "The requested resource needs to be conditionally requested."), 429: ("Too Many Requests", "Your client is sending more frequent requests than are accepted."), + 431: ("Request Header Fields Too Large", "The request headers are too large."), + 451: ("Unavilable For Legal Reasons", "The requested resource has been censored."), 500: ("Server Error", "An internal error occurred."), 501: ("Not Implemented", "The requested functionality has not been implemented."), + 502: ("Bad Gateway", "The backing server indicated an error."), 503: ("Service Unavailable", "Service is being denied at this time."), + 504: ("Gateway Timeout", "The backing server is not responding."), + 505: ("Unsupported HTTP Version", "The server does not support the requested HTTP version."), + 506: ("Variant Also Negotiates", "The server content-negotiation is misconfigured."), + 507: ("Insufficient Storage", "The server is out of storage to process the request."), + 508: ("Loop Detected", "An infinite loop was detected while processing the request."), + 510: ("Not Extended", "The requested extension is not supported."), + 511: ("Network Authentication Required", "Authentication for network access is required."), } def httpdate(ts): -- 2.11.0