{
 "kind": "tool",
 "slug": "defusedxml",
 "path": "tools/defusedxml/",
 "name": "defusedxml",
 "maker": null,
 "density": "basic",
 "crumbs": [
  [
   "Tools",
   "tools/"
  ],
  [
   "Auth and security libraries",
   "tools/auth-security/"
  ]
 ],
 "lead": "Protects Python XML parsing from billion laughs and other XML bomb attacks.",
 "chips": [
  {
   "label": "Auth and security libraries",
   "path": "tools/auth-security/"
  },
  {
   "label": "PYPI"
  }
 ],
 "primary": {
  "label": "Copy install command",
  "copy": "pip install defusedxml"
 },
 "links": [
  {
   "label": "GitHub",
   "href": "https://github.com/tiran/defusedxml"
  },
  {
   "label": "Website",
   "href": "https://github.com/tiran/defusedxml"
  }
 ],
 "track": "New versions, deprecation and license changes on your dashboard",
 "verdicts": [
  {
   "key": "license",
   "label": "License",
   "value": "PSF-2.0",
   "status": "yes",
   "sub": "Use it in paid apps",
   "quote": null,
   "note": "License from PyPI classifier.",
   "src": "https://github.com/tiran/defusedxml"
  },
  {
   "key": "maint",
   "label": "Maintained",
   "value": "Quiet for a year",
   "status": "cond",
   "sub": "Last change Sep 3, 2024",
   "note": "Latest GitHub release Mar 8, 2021. ",
   "src": "https://github.com/tiran/defusedxml"
  },
  {
   "key": "pop",
   "label": "Used by agents' projects",
   "value": "16 projects",
   "status": "info",
   "sub": "#34 of 141 in its category",
   "note": "Dependency in 16 public GitHub projects set up for AI coding agents that we scanned (0.3%).",
   "src": null
  },
  {
   "key": "agent",
   "label": "Agent access",
   "value": "Install only",
   "status": "info",
   "sub": null,
   "note": "Agent skills for this library in the skills catalog; community skills are written by others, read them before you install.",
   "src": null
  }
 ],
 "vfoot": "From the package registry and GitHub, checked daily.",
 "blocks": [
  {
   "id": "overview",
   "nav": "Overview",
   "h2": "What defusedxml does",
   "parts": [
    {
     "t": "prose",
     "text": "Protects Python XML parsing from billion laughs and other XML bomb attacks."
    }
   ]
  },
  {
   "id": "popularity",
   "nav": "Popularity",
   "h2": "defusedxml popularity",
   "parts": [
    {
     "t": "stats",
     "items": [
      {
       "n": "63",
       "of": "/ 100",
       "l": "Gid Score, #819 overall"
      },
      {
       "n": "68.6M",
       "l": "downloads a week, pypi"
      },
      {
       "n": "560",
       "l": "GitHub stars"
      },
      {
       "n": "16",
       "l": "agent projects use it"
      }
     ]
    },
    {
     "t": "small",
     "text": "Gid Score measures public popularity and activity, not quality.",
     "link": "How the Gid Score is calculated",
     "path": "tools/top/"
    }
   ]
  },
  {
   "id": "usage",
   "nav": "How it is used",
   "h2": "How defusedxml is used",
   "parts": [
    {
     "t": "list",
     "items": [
      "defusedxml is a dependency in 16 of the 6,258 public GitHub projects set up for AI coding agents that we scanned, too few to describe it from them alone. Our scan also samples projects by dependency (Solana 3,067, Ethereum and EVM 1,774, 3D and games 3,130, agent frameworks and SDKs 13,750); counting those, it appears in 440 projects, and what it is used with below comes from all of them.",
      "The most used alternative in our scan is MarkupSafe (45 projects).",
      "Projects that use it most often also use NumPy (94.3%), packaging (91.8%), Jinja2 (90.9%)."
     ]
    },
    {
     "t": "h3",
     "text": "By coding agent"
    },
    {
     "t": "rows",
     "rows": [
      {
       "l": "9 projects, 0.3%",
       "v": "Claude Code",
       "path": "agents/claude-code/"
      },
      {
       "l": "8 projects, 0.3%",
       "v": "GitHub Copilot",
       "path": "agents/github-copilot/"
      }
     ]
    },
    {
     "t": "h3",
     "text": "Often used with"
    },
    {
     "t": "rows",
     "rows": [
      {
       "l": "In 94.3% of its projects",
       "v": "NumPy",
       "path": "tools/numpy/"
      },
      {
       "l": "In 91.8% of its projects",
       "v": "packaging",
       "path": "tools/packaging/"
      },
      {
       "l": "In 90.9% of its projects",
       "v": "Jinja2",
       "path": "tools/jinja2/"
      },
      {
       "l": "In 89.5% of its projects",
       "v": "MarkupSafe",
       "path": "tools/markupsafe/"
      },
      {
       "l": "In 89.3% of its projects",
       "v": "attrs",
       "path": "tools/attrs/"
      },
      {
       "l": "In 88.6% of its projects",
       "v": "Requests",
       "path": "tools/requests-py/"
      },
      {
       "l": "In 88.4% of its projects",
       "v": "PyYAML",
       "path": "tools/pyyaml/"
      },
      {
       "l": "In 87.5% of its projects",
       "v": "Click",
       "path": "tools/click-py/"
      }
     ]
    }
   ]
  },
  {
   "id": "more",
   "nav": null,
   "spy_as": "usage",
   "h2": "More about defusedxml",
   "parts": [
    {
     "t": "more",
     "items": [
      {
       "title": "More in Auth and security libraries",
       "path": "tools/auth-security/",
       "items": [
        {
         "text": "bcryptjs",
         "path": "tools/bcryptjs/"
        },
        {
         "text": "NextAuth.js",
         "path": "tools/next-auth/"
        },
        {
         "text": "jsonwebtoken",
         "path": "tools/jsonwebtoken/"
        },
        {
         "text": "cryptography",
         "path": "tools/cryptography/"
        },
        {
         "text": "PyJWT",
         "path": "tools/pyjwt/"
        },
        {
         "text": "jose",
         "path": "tools/jose/"
        },
        {
         "text": "Better Auth",
         "path": "tools/better-auth/"
        },
        {
         "text": "DOMPurify",
         "path": "tools/dompurify/"
        }
       ]
      }
     ]
    }
   ]
  },
  {
   "id": "alternatives",
   "nav": "Alternatives",
   "h2": "Alternatives",
   "parts": [
    {
     "t": "alts",
     "items": [
      {
       "name": "defusedxml",
       "me": true,
       "facts": [
        "PSF-2.0",
        "Gid 63",
        "68.6M/wk"
       ]
      },
      {
       "name": "MarkupSafe",
       "why": "Utility for safely escaping and marking HTML/XML strings to prevent injection attacks.",
       "path": "tools/markupsafe/",
       "facts": [
        "BSD-3-Clause",
        "Gid 67",
        "198M/wk"
       ]
      }
     ],
     "more": "Compare defusedxml with another tool",
     "more_path": "tools/compare/"
    }
   ]
  },
  {
   "id": "start",
   "nav": "Get started",
   "h2": "Get started",
   "parts": [
    {
     "t": "install",
     "intro": "Install it.",
     "code": "pip install defusedxml"
    },
    {
     "t": "gap",
     "text": "No step-by-step start for defusedxml yet: we have not written its hand-checked card."
    }
   ]
  }
 ],
 "glance": [
  [
   "Package",
   "pypi defusedxml"
  ],
  [
   "Category",
   "Auth and security libraries"
  ],
  [
   "License",
   "PSF-2.0"
  ],
  [
   "Gid Score",
   "62.7"
  ],
  [
   "Rank in category",
   "#34 of 141"
  ],
  [
   "GitHub",
   "tiran/defusedxml"
  ],
  [
   "Last change",
   "Sep 3, 2024"
  ]
 ],
 "good": [],
 "checked_line": "From the package registry, GitHub and our scan of public agent projects; numbers update daily.",
 "logo": "https://agentgid.com/media/avatars/tiran.png"
}