GoldOpen Source
ExplorePackagesVulnerabilitiesMCP Servers
Search Gold…⌘KLogin
GoldOpen Source

The authoritative source for production-ready open-source components. Every package, container image, AI model, and MCP server undergoes rigorous verification for security and license compliance.

Explore Gold

  • Explore Everything
  • Packages
  • Gold Packages
  • Container Images
  • AI Models
  • MCP Servers
  • Agent Skills
  • Chip Manufacturers

Security Data & Tools

  • Scan Your Dependencies
  • Trending Threats
  • Threat RSS Feeds
  • CVE Database
  • Actively Exploited (KEV)
  • SGZ Zero-Days
  • CWE Index
  • MITRE ATT&CK
  • Malicious Packages
  • Security Glossary
  • Supply-Chain Report
  • Developers (API & Badge)
  • Chrome Extension
  • Credits & Data Sources

Products

  • The Platform
  • ESSCM
  • Portal
  • TPRM
  • OSM
  • Cowork
  • Code / Runner
  • Guard

Use Cases

  • Know Your Software
  • Auto-Fix Vulnerabilities
  • Asset Discovery
  • AI Governance
  • MCP Server Security
  • Supply Chain Compliance
  • Zero-Day Discovery
  • All Use Cases

Company

  • About
  • Pricing
  • Blog
  • Documentation
  • Safeguard Academy
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 Gold Open Source. All rights reserved.

Built with care bySafeguard
GoldOpen Source
ExplorePackagesVulnerabilitiesMCP Servers
Search Gold…⌘KLogin
Home/CWEs/CWE-522
ShareXLinkedInRedditHN
Common Weakness Enumeration

CWE-522: Insufficiently Protected Credentials

Abstraction
Class
OWASP Top 10
A07:2021 (#7)
Exploit Likelihood
Medium
Related CVEs
10

Description

Credentials are stored or transmitted in a recoverable or unprotected form.

How to mitigate

  • Hash passwords with Argon2/bcrypt, store secrets in a vault, never log credentials.

How attackers exploit CWE-522

MITRE ATT&CK techniques associated with this weakness class (mapped via MITRE CAPEC). A vulnerability of this type could let an adversary carry out:

T1021Remote Serviceslateral-movementT1027Obfuscated Files or InformationstealthT1036Masqueradingstealth

Related CVEs

MediumCVE-2022-20621Security vulnerability in metrics
MediumCVE-2022-3474Security vulnerability in bazel
MediumCVE-2018-16984Security vulnerability in django

References & documentation

  • https://cwe.mitre.org/data/definitions/522.html
  • NVD CWE listing

Weakness facts

IDCWE-522
AbstractionClass
OWASP Top 10A07:2021 (#7)
Exploit LikelihoodMedium
Related CVEs10

Turn Gold’s intelligence into continuous protection

Safeguard scans your code, containers, and dependencies, tells you what’s exposed, and automates the fixes.

Start free See pricing
GoldOpen Source

The authoritative source for production-ready open-source components. Every package, container image, AI model, and MCP server undergoes rigorous verification for security and license compliance.

Explore Gold

  • Explore Everything
  • Packages
  • Gold Packages
  • Container Images
  • AI Models
  • MCP Servers
  • Agent Skills
  • Chip Manufacturers

Security Data & Tools

  • Scan Your Dependencies
  • Trending Threats
  • Threat RSS Feeds
  • CVE Database
  • Actively Exploited (KEV)
  • SGZ Zero-Days
  • CWE Index
  • MITRE ATT&CK
  • Malicious Packages
  • Security Glossary
  • Supply-Chain Report
  • Developers (API & Badge)
  • Chrome Extension
  • Credits & Data Sources

Products

  • The Platform
  • ESSCM
  • Portal
  • TPRM
  • OSM
  • Cowork
  • Code / Runner
  • Guard

Use Cases

  • Know Your Software
  • Auto-Fix Vulnerabilities
  • Asset Discovery
  • AI Governance
  • MCP Server Security
  • Supply Chain Compliance
  • Zero-Day Discovery
  • All Use Cases

Company

  • About
  • Pricing
  • Blog
  • Documentation
  • Safeguard Academy
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 Gold Open Source. All rights reserved.

Built with care bySafeguard
T1078
Valid Accounts
stealth · persistence · privilege-escalation · initial-access
T1110Brute Forcecredential-access
T1114Email Collectioncollection
T1133External Remote Servicespersistence · initial-access
T1185Browser Session Hijackingcollection
T1543Create or Modify System Processpersistence · privilege-escalation
T1550Use Alternate Authentication Materiallateral-movement
T1552Unsecured Credentialscredential-access
T1553Subvert Trust Controlsdefense-impairment
T1558Steal or Forge Kerberos Ticketscredential-access
T1563Remote Service Session Hijackinglateral-movement
T1587Develop Capabilitiesresource-development

Step-by-step: how CWE-522 gets exploited

A stage-by-stage walkthrough of the attack, mapped to the real MITRE ATT&CK tactics for this weakness — what the attacker is trying to do, what's at risk (what can be stolen or damaged), and how you defend. Understanding the playbook is how you shut it down.

  1. 1
    Initial accessinitial-access

    Use the weakness as the way in — the first foothold on the system.

    At risk / what's stolen

    The vulnerable entry point (an input, endpoint, or dependency) that accepts attacker-controlled data.

    How you defend

    Validate and sanitise all input at the boundary; patch to a fixed version.

  2. 2
    Persistencepersistence

    Stay in even after reboots, patches, or credential changes.

    At risk / what's stolen

    Startup hooks, scheduled tasks, config, and accounts the attacker can plant a backdoor in.

    How you defend

    Integrity monitoring of code, config, and scheduled tasks; short-lived credentials.

  3. 3
    Privilege escalationprivilege-escalation

    Gain higher privileges — from a limited account to admin/root.

    At risk / what's stolen

    Over-permissioned services, weak file/permission boundaries, and setuid paths.

    How you defend

    Drop privileges, enforce least privilege, and lock down file permissions.

  4. 4
    Credential accesscredential-access

    Steal passwords, tokens, keys, and session material.

    At risk / what's stolen

    Passwords, API keys, session tokens, SSH/TLS keys, and secrets in memory, env, or config.

    How you defend

    Secret managers, short-lived tokens, and no secrets in code/env/logs.

  5. 5
    Lateral movementlateral-movement

    Pivot from the compromised system to others on the network.

    At risk / what's stolen

    Adjacent servers, databases, and internal services reachable from the foothold.

    How you defend

    Segmentation, per-service auth, and blocking reused credentials across systems.

  6. 6
    Collectioncollection

    Gather the valuable data before taking it out.

    At risk / what's stolen

    Databases, files, customer records, source code, and business data.

    How you defend

    Data-access monitoring, encryption at rest, and least-privilege data access.

This is a defensive, conceptual walkthrough for education — stages reflect MITRE ATT&CK tactics associated with this weakness class, not a working exploit. Not every attack uses every stage.

CriticalCVE-2024-37051Security vulnerability in aqua
CriticalCVE-2026-8926Security vulnerability in curl
MediumCVE-2022-27774Security vulnerability in curl
MediumCVE-2022-27776Security vulnerability in curl
MediumCVE-2025-14524Security vulnerability in curl
MediumCVE-2026-6253Security vulnerability in curl
MediumCVE-2026-3783Security vulnerability in curl