Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

html_file: Improve plugin to use jinja2 templates #8866

8 tasks done
andresriancho opened this issue Mar 12, 2015 · 1 comment
8 tasks done

html_file: Improve plugin to use jinja2 templates #8866

andresriancho opened this issue Mar 12, 2015 · 1 comment


Copy link

andresriancho commented Mar 12, 2015


The html_file plugin was written many years ago and it has some horrible hard-coded HTML inside. This makes it really difficult to modify/improve the generated HTMLs.


  • Design a new report template, check how the reports of Acunetix, ZAP, Burp look like and take ideas from there
  • Write a jinja2 template for the designed report
  • Re-write the plugin to use jinja2 templates
  • Save each template in a different directory (such as w3af/plugins/output/html_file/templates/generic/) and allow the user to choose the template to render using a configuration setting. For now only support the generic template but this leaves the people space to write other templates
  • Write a small tool that will render the template, maybe this could be done with nosetests+unittests. If a --template-test flag is found in argv then we write the test output to files in /tmp/ , this will make it easier for me to write new templates without having to run multiple scans
  • Ask the community to write templates

Conditions of satisfaction

  • We have unittests which check that the template is correctly rendered (no need to run scans for this)
  • We have one unittest to check that the output is properly generated after a real scan

Related with

@andresriancho andresriancho added this to the 1.7.2 - Multiple domain names as target milestone Mar 12, 2015
andresriancho added a commit that referenced this issue Mar 13, 2015
* UnicodeDecodeError @ html_file: 'utf8' codec can't decode byte #4219
Copy link
Owner Author

andresriancho commented Mar 14, 2015

Plugin is working perfectly, just need to improve the template Improvements for HTML report template #8891

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet

No branches or pull requests

1 participant