Maintainers
Pricing
Enterprise
More
More
Documentation
Try Live
Rankings
Install
Blog
Docs7
Ask
New
Add Docs
OWASP Top 10
https://github.com/owasp/top10
Admin
Official OWASP Top 10 Document Repository
Tokens:
87,349
Snippets:
510
Trust Score:
10
Update:
1 day ago
Context
Chat
Benchmark
67.74
Latest
Show doc for...
Code
Info
Show Results
Tokens:
Raw
Copy
Link
Tokens:
Raw
Copy
Link
### Install Python Requirements Source: https://github.com/owasp/top10/blob/master/CONTRIBUTING.md Installs Python requirements for the OWASP Top 10 MkDocs sites. Run this during first-time setup before building or serving. ```bash make install-python-requirements ``` -------------------------------- ### Scenario #1: Example URL with modified 'acct' parameter Source: https://github.com/owasp/top10/blob/master/2025/docs/en/A01_2025-Broken_Access_Control.md Example URL demonstrating how an attacker can change the 'acct' parameter to access another user's account. ```http https://example.com/app/accountInfo?acct=notmyacct ``` -------------------------------- ### OSIB MkDocs macro module with osib_anchor and osib_link Source: https://github.com/owasp/top10/blob/master/osib/README.md This is the main OSIB MkDocs macro module. It provides two macros: osib_anchor and osib_link, which manage and version links in MkDocs documents. The module requires mkdocs, mkdocs-macros-plugin, and dacite. Installation is manual via pip install . or pip install -e . for developers. After installation, copy or edit osib_macro.py to the root folder of your MkDocs document and configure the macros plugin in mkdocs.yml. ```python #!################################################################################################################################################## #!# This MkDocs MACRO has been developed by the OWASP-Top 10 Project in 2021. #!# It provides a central management of links in MkDocs documents. This includes the versioning of links inside a project, #!# standard or a group of documents and to external sources. By exporting the update OSIB structure in a YAML file all efforts #!# done by one volunteering group can be used by any other project, standard or document that refers to the same links. #!# This reduces or even avoids a lot of unnecessary, redundant work to track and to update links. #!# The OSIB tree and this macro are capable to handle multilingual versions for links. #!# #!# ------------------------------------------------------------------------------------------------------------------------------------------------ #!# #!# This Python program provides a module including two MkDocs macros to use with markdown: #!# - osib_anchor: Adds an OSIB anchor and an object to an osib YAML structure #!# Input: osib_anchor(osib=osib.<organization>.<project|standard>.<version(without dots '.')>.<internal structure>, create_organization=False #!# source_id=<id inside the source>, lang=<lang>, source=<url_i18n>, name=<name_i18n>, #!# parent=<osib-id>, predecessor=<osib-id>, split_from=<osib.id>, merged_from=[<list of osib-ids>, ... ], #!# cre=<osib-id>, aliases=[<list of aliases>, ...]) #!# Output: '<a id="<osib>"></a>' (HTTP-anchor), and updates in the OSIB YAML tree #!# #!# - osib_link: Get links from a osib YAML tree, optionally find successors and add linking information bidirectionally #!# to the OSIB YAML tree #!# Input: osib_link (link=osib.<organization>.<project|standard>.<version(without dots '.')>.<internal structure>, create_organization=False #!# doc=<osib>, type=<reference|predecessor|successor|merged_from|split_from|...>, #!# osib=<osib>, reviewed=<datestamp(YYYYMMDD)>, status=<active|draft|...>) #!# Output: markdown link format '["<text>|<prefix><doc_osib><doc_suffix><osib_names>"](<html_link>)<speparator> ..') and/or successor/s #!# #!# ====> Exports optionally to an OSIB YAML file with all added information to be uses by other versions, projects, standards and #!# standard linking projects like OWASP Common Requirement Enumeration (https://github.com/OWASP/common-requirement-enumeration, opencre.org) #!# #!# ------------------------------------------------------------------------------------------------------------------------------------------------ #!# #!# Requirements: #!# - mkdocs: pip install mkdocs (https://mkdocs.org) #!# - mkdocs-macros-plugin: pip install mkdocs-macros-plugin (https://mkdocs-macros-plugin.readthedocs.io/en/latest/) #!# - dacite: pip install dacite (https://github.com/konradhalas/dacite) #!# #!# Installation: #!# Actually 'manual installation' only: #!# cd <your path>/mkdocs_macro_osib_package #!# pip install . #!# verify if osib is in your pip list #!# pip list | grep osib #!# #!# Developers Installation #!# cd <your path>/mkdocs_macro_osib_package #!# pip install -e . #!# verify if osib is in your pip list #!# pip list | grep osib #!# #!$ Copy or edit 'osib_macro.py' to the root folder of your mkdocs document #!# from mkdocs_macro_osib import define_env, on_post_build #!# #provides MkDocs macros 'osib_anchor' and 'osib_link' #!# #!# To use the macros add in 'mkdocs.yml' (if you use the plugin 'i18n' add this macro after it): #!# plugins: #!# - macros: # needs to be the last plugin to export the final osib-YAML file for all languages #!# module_name: 'osib_macro' #!# include_dir: include #!# verbose: true # debug #!# ``` -------------------------------- ### Build Both Versions Source: https://github.com/owasp/top10/blob/master/CONTRIBUTING.md Builds both the 2021 and 2025 versions. 'make all' also installs dependencies, while 'make build-all' only builds the sites. ```bash make all # Install dependencies and build both sites ``` ```bash make build-all # Just build both sites ``` -------------------------------- ### Build both versions with redirects Source: https://github.com/owasp/top10/blob/master/REORGANIZATION-2025.md Builds both sites with redirects. The `make build-all` target or the `./scripts/build-all.sh` script creates the complete 2021 and 2025 sites, a root redirect to 2021, and HTML redirects for backward compatibility. ```bash # Build both sites with redirects make build-all # Or use the script directly ./scripts/build-all.sh ```