sphinx icon indicating copy to clipboard operation
sphinx copied to clipboard

Add CVE and CWE roles

Open hugovk opened this issue 2 years ago • 2 comments

Subject:

Feature or Bugfix

  • Feature

Purpose

  • Add a cve role to turn :cve:`2020-10735` into https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2020-10735
  • Add a cwe role to turn :cwe:`787` into https://cwe.mitre.org/data/definitions/787.html

Detail

  • Add cve and cwe roles, similar to existing pep and rfc roles, to link to the Common Vulnerabilities and Exposures and Common Weakness Enumeration websites.

Relates

  • https://github.com/sphinx-doc/sphinx/pull/11780

hugovk avatar Dec 01 '23 06:12 hugovk

No objection in principle, though this feels like a feature is missing to make this easier -- these roles are just extlinks, in bold, with customised classes ('cve'/'cwe') and index entries.

A

AA-Turner avatar Dec 26 '23 07:12 AA-Turner

We could refactor this by adding a class reponsible for this kind of things maybe?

picnixz avatar Dec 26 '23 10:12 picnixz