MCPcopy Index your code
hub / github.com/OWASP/Python-Honeypot / error_403

Function error_403

api/server.py:158–170  ·  view source on GitHub ↗

handle the 403 HTTP error Args: error: the flask error Returns: 403 JSON error

(error)

Source from the content-addressed store, hash-verified

156
157@app.errorhandler(403)
158def error_403(error):
159 """
160 handle the 403 HTTP error
161
162 Args:
163 error: the flask error
164
165 Returns:
166 403 JSON error
167 """
168 return jsonify(
169 msg_structure(status="error", msg=error.description)
170 ), 403
171
172
173@app.errorhandler(404)

Callers

nothing calls this directly

Calls 1

msg_structureFunction · 0.90

Tested by

no test coverage detected