Closed gnewton closed 8 years ago
This is very easily doable, although current implementation does not support it.
Will add support for this.
Implemented adding custom headers.
New methods in Server: SetHeader() and Header(). You can use these to set headers that will be added to all responses.
Changes are committed to the gowut.dev project, will be available in the next release.
Commit: https://github.com/icza/gowut.dev/commit/12e5c40b4c21d27674c4cdd906ff519ba410a5af
Thanks for reporting this.
OWASP 10 https://www.owasp.org/index.php/Category:OWASP_Top_Ten_Project "The OWASP Top Ten represents a broad consensus about what the most critical web application security flaws are."
I applied a tool that tests for OWASP 10 vulnerabilities: https://www.owasp.org/index.php/OWASP_Zed_Attack_Proxy_Project
It found a couple, mostly medium level. They involve some headers not being set:
Is there any chance the gowut.Server interface could allow setting the underlying http.Response.Header? i.e. setting one or more headers that are sent with every response?
The report for the tool is here: https://drive.google.com/file/d/0B9uNae3afGInUnI2VEI3aENVZEk/view?usp=sharing