|
Detecting Jira & Confluence Versions and Mapping Known CVEs |
This blogpost presents a tool that identifies the version of Atlassian Jira or Confluence application and maps the identified version to a local CVE database. The detection is primarily based on the presence of JavaScript files and SHA256 hashes. The tool first tries to get the version from application pages (if available); if it fails, it will try to get the version by matching files and file hashes. It also supports adding new versions and updating the CVE database for future detection and vulnerability mapping.
/includes/ files (JS) , compares which files exist versus the database for known versions, and narrows candidate versions.cve_database.json maps product → CVE → version ranges, allowing fast correlation and alerting.
Many Atlassian web applications have static assets (especially JS) whose filenames and contents change predictably between releases. By maintaining a small database of which JS files (and their SHA256 hashes) are in each product version, we can:
This approach is not intrusive, as it only sends simple HTTP requests against publicly accessible resources.
/, /login.action, /about/about-page-content.vm.
A regex looks for patterns like Confluence X.Y.Z or HTML elements/meta tags with version content (e.g. name="ajs-version-number" or inputs named JiraVersion).
If a version is found here, it’s returned immediately.
files\_per\_version\_\*.json) that maps known versions → list of JS paths.
It sends HEAD requests to the target BASE_URL/includes/ in order to determine which files exist and builds match ratios for all known versions.
files_per_version_*_hash.json to narrow down the candidates to an exact version or the tightest possible version range.
files/cve_database.json mapping CVEs to version ranges. New CVEs are also added directly through the tool.
Once the version(s) are identified, the tool returns CVE IDs whose version ranges cover the identified version(s).


This will:
includes/ folder inside the archive and collect .js files.files/files_per_version_jira.json and files/files_per_version_jira_hash.json.
This modifies cve_database.json so that future detections will consider this CVE.
The source code of the project is available on Github