Skip to content

Cwe 3 #471

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

Open
wants to merge 54 commits into
base: scw-mapping
Choose a base branch
from
Open

Cwe 3 #471

wants to merge 54 commits into from

Conversation

Sanel0101
Copy link

Issue: Resolves

CVSS v3 Mapping:

CWE Mapping:

Remediation Advice Mapping:

Deprecated Node Mapping (if needed):

Checklist:

  • I have added entries to CHANGELOG.md and marked it Added/Changed/Removed
  • I have made corresponding changes to the documentation (if needed)

plr0man and others added 30 commits January 10, 2020 11:17
* Add Password Policy Bypass

* Fix Pass Policy JSON validation error
* Cut v1.9

* Update changelog for v1.9
* Add OAuth Account Squatting

* Add period at the end of remediation advice
* Revise Weak Login Function Severity Ratings

* Fix diff - forgot to save file

Co-authored-by: Adam David <[email protected]>
* Update README.md

* add branch parameter

* fix link to API
* move to mappings directory

* fix link to scw mapping

* move to third party mapping location

* fix link to scw mapping

* fix validation for new file location

* end quote

* add to changelog

* adjust headed for secure code warriors mapping

* Add test to validate artifact file location and format

Co-authored-by: Adam David <[email protected]>
bugcrowd#303)

* fixed number ordering on ordered list in no_password_policy remediation advice

* same issue on different section

* added blank lines around code snippets as advised by MD linter

Co-authored-by: Adam David <[email protected]>
* update remediation advice for cache-control

* update cache control advice notes in changelog

* updated changelog

Co-authored-by: Adam David <[email protected]>
* Add new automotive security entries

* Update CWE mapping nodes

* Correct typo
* Update scw json links

* Remove flash based entries
* prepare v1.10

* update version timestamp

* update date for release date

* set release date within json

* update date

* update date
* Rename secure-code-warriors-links.json to secure-code-warrior-links.json

* fix scw spelling
* update logo

* fix png

* limit height of image
* Remove p5 variant

Remove remediation advice for P5 XSS VRT entry

* remove xss protection remediation advice

Removed the 11th remediation advice on XSS P3 VRT entry

* Empty Remediation advice for P5-X-XSS-Protection header

Empty Remediation advice for P5-X-XSS-Protection header

* references can be zero

* Revert "references can be zero"

This reverts commit d6b3f19.

* ignore DS_STORE

* Empty reference for passing tests

* Remove

---------

Co-authored-by: Amal Murali <[email protected]>
* Updating the SSRF category

* Revert "Updating the SSRF category"

This reverts commit 785bd8b.

* Update SSRF classification from `Broken Access Control` to `Server Security Misconfiguration`

* Update SSRF mappings in CVSS V3, CWE, and Remediation Advice files

* Refactor SSRF category and split `External` variant into `GET Request Only` and `DNS Query Only`

* Update CVSS V3 mapping to include the updated mappings for the `External` SSRF variant

* PII-leakage-update

FROM:
P1 - Automotive Security Misconfiguration - Infotainment, Radio Head Unit - PII Leakage

TO:
P1 - Automotive Security Misconfiguration - Infotainment, Radio Head Unit - Sensitive data Leakage/Exposure
Varies - Sensitive Data Exposure - Disclosure of Secrets - PII Leakage/Exposure

* Update secure-code-warrior-links.json

* Update remediation_advice.json

* Update remediation_advice.json

* Update cwe.json

* Update cwe.json

* Update cwe.json

* Update cwe.json

* Update cwe.json

* Update cwe.json

* Update cwe.json

* Update remediation_advice.json

* HTTP Request Smuggling

Adding HTTP Request Smuggling as a new VRT entry.

* Update remediation_advice.json

* Update cvss_v3.json

* Failure to invalidate session on permission change

Adding Failure to invalidate session on permission change as a new VRT entry.

* Update cwe.json

* Update cwe.json

* Update remediation_advice.json

* Update cwe.json

* Deprecation of XSS on IE11

REMOVE: P4 - Cross-Site Scripting (XSS) - IE-Only - IE11

FROM: P5 - Cross-Site Scripting (XSS) - IE-Only - Older Version (< IE11)

TO: P5 - Cross-Site Scripting (XSS) - IE-Only

* Update remediation_advice.json

* LDAP Injection

Adding LDAP Injection as a new VRT entry.

* Update cwe.json

* Update remediation_advice.json

* Update cvss_v3.json

* HTML-Injection

Adding the category below to VRT:
P5 - Server-Side Injection - Content Spoofing - HTML Content Injection

* SSRF External Low Impact

* new IDOR variants

new IDOR variants

* LDAP Injection (bugcrowd#367)

* Update vulnerability-rating-taxonomy.json

* Update cvss_v3.json

* Update cvss_v3.json

* New Changes LDAP Injection

* Cryptographic Weakness Category bugcrowd#352

* New changes Cryptographic Weakness category

* json parse error fix (bugcrowd#380)

* hyphens to underscores in vrt items

* Update remediation_advice.json

* Update remediation_advice.json

---------

Co-authored-by: Amal Murali <[email protected]>
Co-authored-by: Deepak Kumar Jha <[email protected]>
* Update vulnerability-rating-taxonomy.json

* v1.11

* Revert "Update vulnerability-rating-taxonomy.json"

This reverts commit 3222464.

* Update vulnerability-rating-taxonomy.json

Co-authored-by: Deepak Kumar Jha <[email protected]>

---------

Co-authored-by: Deepak Kumar Jha <[email protected]>
TimmyBugcrowd and others added 23 commits November 16, 2023 09:32
* fixing-errors

fixing-errors

* Update vulnerability-rating-taxonomy.json

* fixing-errors

* broken_cryptography fix

* broken_cryptography fix for cvss, cwe and remediation

* Fixing-errors

* Update deprecated-node-mapping.json

* fixing-errors

* Update deprecated-node-mapping.json

* scw updated

---------

Co-authored-by: Deepak Kumar Jha <[email protected]>
* llm model added

* llm model added

* llm model added

* changelog.md and metadata release updated

---------

Co-authored-by: Deepak Kumar Jha <[email protected]>
* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update cvss_v3.json

* Update vulnerability-rating-taxonomy.json

* Update cvss_v3.json

* error fixes

* Update cvss_v3.json

* Update cvss_v3.json

* new-update

new-update

* Update secure-code-warrior-links.json

* Update secure-code-warrior-links.json

* new-update2

* new-update2

* Update cwe.json

* Update cwe.json

* Update cwe.json

* Update cwe.json

* Update remediation_advice.json

* Update remediation_advice.json

* Update remediation_advice.json

* Update remediation_advice.json

* Update remediation_advice.json

* Update remediation_advice.json

* SCW file added

---------

Co-authored-by: Bugcrowd <[email protected]>
* Biases entries

* Update vulnerability-rating-taxonomy.json

* * Fixing Indentation in JSONs
* Fixing cvss_v3 file
* Adding secure-code-warrior-links.json

* * Fixing mixup of entries in remediation_advice.json

* Adding CVSS Fix

* Modifying tests and Python Upgrade

* Reverting changes

* Fixing CWE Mapping in JSON

---------

Co-authored-by: Abhinav Nain <[email protected]>
* VRT-release-changes

* Update cvss_v3.json

* Update cwe.json

* Adding SCW

---------

Co-authored-by: Abhinav Nain <[email protected]>
* Adding Changelog and release date for v1.14 release

* Adding Deprecated node mapping and few test refactoring

* Linter Fixes

* Fixing all flake8 errors
* adding changelog and release date for v1.14.1 release

* fixed version

* release date update in vrt json
* 1.14.2 Release Q3

* Fixing deprecated mapping json
* Blockchain Security

P1 - Decentralized Application Misconfiguration - Insecure Data Storage - Plaintext Private Key
Varies - Decentralized Application Misconfiguration - Insecure Data Storage - Sensitive Information Exposure
Varies - Decentralized Application Misconfiguration - Improper Authorization - Insufficient Signature Validation
Varies - Decentralized Application Misconfiguration - DeFi Security - Flash Loan Attack
Varies - Decentralized Application Misconfiguration - DeFi Security - Pricing Oracle Manipulation
Varies - Decentralized Application Misconfiguration - DeFi Security - Function-Level Accounting Error
Varies - Decentralized Application Misconfiguration - DeFi Security - Improper Implementation of Governance
P1 - Decentralized Application Misconfiguration - Marketplace Security - Signer Account Takeover
P1 - Decentralized Application Misconfiguration - Marketplace Security - Unauthorized Asset Transfer
P1 - Decentralized Application Misconfiguration - Marketplace Security - Orderbook Manipulation
P2 - Decentralized Application Misconfiguration - Marketplace Security - Malicious Order Offer
P2 - Decentralized Application Misconfiguration - Marketplace Security - Price or Fee Manipulation
P3 - Decentralized Application Misconfiguration - Marketplace Security - OFAC Bypass
Varies - Decentralized Application Misconfiguration - Marketplace Security - Improper Validation and Checks For Deposits and Withdrawals
Varies - Decentralized Application Misconfiguration - Marketplace Security - Miscalculated Accounting Logic
Varies - Decentralized Application Misconfiguration - Marketplace Security - Denial of Service
P1 - Decentralized Application Misconfiguration - Protocol Security Misconfiguration - Node-level Denial of Service
P2 - Protocol Specific Misconfiguration - Frontrunning-Enabled Attack
P2 - Protocol Specific Misconfiguration - Sandwich-Enabled Attack
Varies - Protocol Specific Misconfiguration - Misconfigured Staking Logic
Varies - Protocol Specific Misconfiguration - Improper Validation and Finalization Logic
P1 - Smart Contract Misconfiguration - Reentrancy Attack
P1 - Smart Contract Misconfiguration - Smart Contract Owner Takeover
P1 - Smart Contract Misconfiguration - Uninitialized Variables
P1 - Smart Contract Misconfiguration - Unauthorized Transfer of Funds
P2 - Smart Contract Misconfiguration - Integer Overflow / Underflow
P2 - Smart Contract Misconfiguration - Unauthorized Smart Contract Approval
P3 - Smart Contract Misconfiguration - Irreversible Function Call
P3 - Smart Contract Misconfiguration - Function-level Denial of Service
P3 - Smart Contract Misconfiguration - Malicious Superuser Risk
P3 - Smart Contract Misconfiguration - Improper Fee Implementation
P4 - Smart Contract Misconfiguration - Improper Use of Modifier
P4 - Smart Contract Misconfiguration - Improper Decimals Implementation
Varies - Smart Contract Misconfiguration - Inaccurate Rounding Calculation
Varies - Smart Contract Misconfiguration - Bypass of Function Modifiers & Checks
Varies - Zero Knowledge Security Misconfiguration - Missing Constraint
Varies - Zero Knowledge Security Misconfiguration - Mismatching Bit Lengths
Varies - Zero Knowledge Security Misconfiguration - Misconfigured Trusted Setup
Varies - Zero Knowledge Security Misconfiguration - Missing Range Check
P1 - Zero Knowledge Security Misconfiguration - Improper Proof Validation and Finalization Logic
P1 - Zero Knowledge Security Misconfiguration - Deanonymization of Data
Varies - Blockchain Infrastructure Misconfiguration - Improper Bridge Validation and Verification Logic

* Fixing syntax errors

* Update vulnerability-rating-taxonomy.json

* Fixing errors

* Fixing errors

* Fixing errors

* SAML Replay - P5

Adding:
P5 - Broken Authentication and Session Management - SAML Replay

* Revert "SAML Replay - P5"

This reverts commit 04c8503.

* Update vulnerability-rating-taxonomy.json

* Sorted JSONs + Helper Script (bugcrowd#436)

* Additional Files

---------

Co-authored-by: Abhinav Nain <[email protected]>
* Updating IDOR's

From:
P1 – Broken Access Control (BAC) > Insecure Direct Object References (IDOR) > Read/Edit/Delete Sensitive Information/Iterable Object Identifiers
P2 – Broken Access Control (BAC) > Insecure Direct Object References (IDOR) > Edit/Delete Sensitive Information/Iterable Object Identifiers
P3 – Broken Access Control (BAC) > Insecure Direct Object References (IDOR) > Read Sensitive Information/Iterable Object Identifiers
P4 – Broken Access Control (BAC) > Insecure Direct Object References (IDOR) > Read/Edit/Delete Sensitive Information/Complex Object Identifiers(GUID)
P5 – Broken Access Control (BAC) > Insecure Direct Object References (IDOR) > Read/Edit/Delete Non-Sensitive Information

To:
P1 -  Broken Access Control (BAC) > Insecure Direct Object References (IDOR) >  Modify/View Sensitive Information(Iterable Object Identifiers)
P2  - Broken Access Control (BAC) > Insecure Direct Object References (IDOR) >  Modify Sensitive Information(Iterable Object Identifiers)
P3  - Broken Access Control (BAC) > Insecure Direct Object References (IDOR) > View Sensitive Information(Iterable Object Identifiers)
P4  - Broken Access Control (BAC) > Insecure Direct Object References (IDOR) > Modify/View Sensitive Information(Complex Object Identifiers GUID/UUID)
P5  - Broken Access Control (BAC) > Insecure Direct Object References (IDOR) > View Non-Sensitive Information

* Additional Files

* Rebase changes

---------

Co-authored-by: Abhinav Nain <[email protected]>
Updated the CVSS for the vulnerability related to email spoofing caused by missing or misconfigured DMARC records.

Co-authored-by: Tarek Bouali <[email protected]>
* SAML Replay - P5

Adding:
P5 - Broken Authentication and Session Management - SAML Replay

* Additional Files

---------

Co-authored-by: Abhinav Nain <[email protected]>
* mappings version fix

* mappings id swap

* mappings id swap
* Cache Deception

ADD:
Varies: Server Security Misconfiguration - Cache Deception

* Update remediation_advice.json

---------

Co-authored-by: Abhinav Nain <[email protected]>
* Release Changes

* VRT Changes
* GraphQL Introspection Enabled - P5

bugcrowd#450

* Bypass of Password Confirmation on Password Change

Add:
Broken Access Control – Bypass of Password Confirmation – Change Password

* Revert "Bypass of Password Confirmation on Password Change"

This reverts commit a6e415a.

* Bypass of Password Confirmation on Password Change

Add:
Broken Access Control – Bypass of Password Confirmation – Change Password

* Revert "Bypass of Password Confirmation on Password Change"

This reverts commit 3418212.

* Broken Access Control (BAC) - Bypass of Password Confirmation - Change Password (bugcrowd#462)

* Revert "Bypass of Password Confirmation on Password Change"

This reverts commit 3418212.

* Bypass of Password Confirmation on Password Change

Add:
Broken Access Control – Bypass of Password Confirmation – Change Password

* AI entries revised (bugcrowd#464)

* AI entries revised

Adding:
P1 - AI Application Security - Training Data Poisoning - Backdoor Injection / Bias Manipulation
P1 - AI Application Security - Model Extraction - API Query-Based Model Reconstruction
P1 - AI Application Security - Sensitive Information Disclosure - Cross-Tenant PII Leakage/Exposure
P1 - AI Application Security - Remote Code Execution - Full System Compromise
P1 - AI Application Security - Sensitive Information Disclosure - Key Leak
P2 - AI Application Security - Remote Code Execution - Sandboxed Container Code Execution
P2 - AI Application Security - Prompt Injection - System Prompt Leakage
P2 - AI Application Security - Vector and Embedding Weaknesses - Embedding Exfiltration / Model Extraction
P2 - AI Application Security - Denial-of-Service (DoS) - Application-Wide
P3 - AI Application Security - Vector and Embedding Weaknesses - Semantic Indexing
P3 - AI Application Security - Improper Output Handling - Cross-Site Scripting (XSS)
P4 - AI Application Security - Improper Output Handling - Markdown/HTML Injection
P4 - AI Application Security - AI Safety - Misinformation / Wrong Factual Data
P4 - AI Application Security - Insufficient Rate Limiting - Query Flooding / API Token Abuse
P4 - AI Application Security - Denial-of-Service (DoS) - Tenant-Scoped
P4 - AI Application Security - Adversarial Example Injection - AI Misclassification Attacks
P5 - AI Application Security - Improper Input Handling - ANSI Escape Codes
P5 - AI Application Security - Improper Input Handling - Unicode Confusables
P5 - AI Application Security - Improper Input Handling - RTL Overrides

* Update vulnerability-rating-taxonomy.json

* Fixing errors

* Fixing errors2

* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update vulnerability-rating-taxonomy.json

* Update cvss_v3.json

* Fixed deprecated node mapping (bugcrowd#457)

* Updated varies to default and removed redundant entries (bugcrowd#461)

* Updated varies to default and removed redundant entries

* Reverting some changes

---------

Co-authored-by: Abhinav Nain <[email protected]>

* Final Changes - Adding Changelog + deprecated-node-mappings + ALL JSON Sorting + SCW

---------

Co-authored-by: SamAtBugcrowd <[email protected]>
Co-authored-by: Abhinav Nain <[email protected]>
@Copilot Copilot AI review requested due to automatic review settings July 6, 2025 22:16
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds support for Secure Code Warrior training links, integrates scripts for generating and validating the SCW artifact, updates core mapping files (CWE & CVSS v3) with new AI/security categories, and introduces tooling to sort JSON mapping files.

  • Introduce third-party-mappings/remediation_training/secure-code-warrior-links.json containing SCW URLs per VRT ID
  • Add lib/artifacts/scw_artifact.py plus generate_artifacts.py/validate_artifacts.py for fetching and validating SCW links
  • Update lib/utils/utils.py with sort_jsons and add sort_all_jsons.py; refresh mapping files and tests accordingly

Reviewed Changes

Copilot reviewed 17 out of 25 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
third-party-mappings/remediation_training/secure-code-warrior-links.json New static JSON mapping of VRT IDs to SCW trial URLs
lib/artifacts/scw_artifact.py Functions to construct and fetch SCW URLs
lib/generate_artifacts.py Generate scw_links.json from current VRT
lib/validate_artifacts.py Validate generated artifact matches checked‐in JSON
sort_all_jsons.py Entrypoint to sort core mapping JSONs via sort_jsons()
lib/utils/utils.py Add sort_jsons and constants for SCW files; update helpers
mappings/cwe/cwe.json & mappings/cvss_v3/cvss_v3.json Bulk update to include AI/security categories and new nodes
lib/tests/* Adjust tests to account for JSON sorting and SCW mapping
README.md Document third‐party SCW mapping
Comments suppressed due to low confidence (3)

lib/tests/test_vrt.py:17

  • The mapping tests only cover files under mappings/. To ensure the Secure Code Warrior file stays valid, add a test that loads and validates third-party-mappings/remediation_training/secure-code-warrior-links.json.
            )

lib/artifacts/scw_artifact.py:4

  • There’s an unintended leading space in the URL string (due to the line continuation) which will become part of the URL and break requests. Remove or trim the extra space before /api.
BASE_SCW_URL = 'https://integration-api.securecodewarrior.com\

lib/artifacts/scw_artifact.py:6

  • The output filename scw_links.json doesn’t match the checked-in mapping file secure-code-warrior-links.json. Rename or align these to avoid confusion and test failures.
OUTPUT_FILENAME = 'scw_links.json'

@@ -108,3 +131,31 @@ def _all_id_lists(sub_vrt, prefix):
print(sub_vrt)
raise Exception('unexpected entry found')
return _all_id_lists(vrt['content'], [])

def sort_jsons():
Copy link
Preview

Copilot AI Jul 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The sort_jsons function only targets the core VRT, CVSS, CWE, and remediation advice files. Consider including the third-party secure-code-warrior-links.json in the sorting loop to keep all JSON consistently ordered.

Copilot uses AI. Check for mistakes.

Comment on lines +24 to +25
'SCW Document is invalid, copy the artifact to the remediation\
training'
Copy link
Preview

Copilot AI Jul 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The error message references remediation training, but the actual directory is named remediation_training. Update the message to match the real path.

Suggested change
'SCW Document is invalid, copy the artifact to the remediation\
training'
'SCW Document is invalid, copy the artifact to the remediation_training'

Copilot uses AI. Check for mistakes.

Copy link
Author

@Sanel0101 Sanel0101 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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

Successfully merging this pull request may close these issues.