<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Anant</title>
    <description>The latest articles on Forem by Anant (@anantdhavale1).</description>
    <link>https://forem.com/anantdhavale1</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3810189%2F90200bc4-6ede-46f1-9c42-4970c1cd02bc.png</url>
      <title>Forem: Anant</title>
      <link>https://forem.com/anantdhavale1</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/anantdhavale1"/>
    <language>en</language>
    <item>
      <title>pip-guardian on Pypi</title>
      <dc:creator>Anant</dc:creator>
      <pubDate>Tue, 07 Apr 2026 09:25:03 +0000</pubDate>
      <link>https://forem.com/anantdhavale1/pip-guardian-on-pypi-4d4o</link>
      <guid>https://forem.com/anantdhavale1/pip-guardian-on-pypi-4d4o</guid>
      <description>&lt;p&gt;The LiteLLM supply chain attack is a bit of a wake-up call.&lt;/p&gt;

&lt;p&gt;Somehow it has not been very prominent in the news. I received an email from Mercor stating a recent supply chain attack involving LiteLLM affected their systems.&lt;/p&gt;

&lt;p&gt;According to reports, malicious code was injected directly into official versions of the LiteLLM package, which were published on PyPI. &lt;/p&gt;

&lt;p&gt;When developers installed the package in production using pip as usual, they unknowingly introduced the malicious code into their environments. The malicious package reportedly harvested cloud credentials, SSH keys, API tokens, and even tried lateral movement in Kubernetes environments. &lt;/p&gt;

&lt;p&gt;The lesson here is simple: “pip install latest” in production is no longer safe.&lt;/p&gt;

&lt;p&gt;At a minimum, before installing a package in production, check:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;When was this version published?&lt;/li&gt;
&lt;li&gt;Are you pinning versions?&lt;/li&gt;
&lt;li&gt;Are you using hash-locked requirements?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I’ve experimented with a small tool that adds a check before pip installs a package. Not commercial yet, just a safety layer for developers after the LiteLLM incident.&lt;/p&gt;

&lt;p&gt;You can check it out here, please star if you like it :&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/AnantDhavale/pip-guardian/tree/main" rel="noopener noreferrer"&gt;https://github.com/AnantDhavale/pip-guardian/tree/main&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Download it from Pypi&lt;/p&gt;

&lt;p&gt;pip install pip-guardian&lt;/p&gt;


&lt;div class="crayons-card c-embed text-styles text-styles--secondary"&gt;
    &lt;div class="c-embed__content"&gt;
      &lt;div class="c-embed__body flex items-center justify-between"&gt;
        &lt;a href="https://pypi.org/project/pip-guardian/" rel="noopener noreferrer" class="c-link fw-bold flex items-center"&gt;
          &lt;span class="mr-2"&gt;pypi.org&lt;/span&gt;
          

        &lt;/a&gt;
      &lt;/div&gt;
    &lt;/div&gt;
&lt;/div&gt;


&lt;p&gt;Here's the readme version for you with some details::&lt;/p&gt;

&lt;p&gt;Feature set&lt;/p&gt;

&lt;p&gt;1) Pre-install risk policy&lt;br&gt;
Version age rules:&lt;br&gt;
block if version is very new (default &amp;lt; 5h)&lt;br&gt;
warn if version is recent (default &amp;lt; 48h)&lt;br&gt;
Blocks yanked releases.&lt;br&gt;
Blocks known-compromised versions from local blocklist.&lt;br&gt;
Blocks maintainer identities from local blocklist.&lt;/p&gt;

&lt;p&gt;2) Deep artifact scanning&lt;br&gt;
Downloads wheel/sdist artifacts from PyPI before install.&lt;br&gt;
Verifies artifact SHA256 against PyPI metadata.&lt;br&gt;
Static scan heuristics for:&lt;br&gt;
executable .pth startup hooks&lt;br&gt;
sitecustomize.py / usercustomize.py&lt;br&gt;
obfuscated payload patterns (e.g., long base64 + dynamic execution)&lt;br&gt;
credential-exfiltration-like behavior&lt;br&gt;
persistence indicators (e.g., systemd artifacts)&lt;br&gt;
Kubernetes lateral-movement indicators&lt;/p&gt;

&lt;p&gt;3) Built-in incident guard (LiteLLM March 2026)&lt;br&gt;
Blocks:&lt;br&gt;
litellm==1.82.7&lt;br&gt;
litellm==1.82.8&lt;br&gt;
Runbook:&lt;br&gt;
docs/INCIDENT_LITELLM_2026.md&lt;/p&gt;

&lt;p&gt;4) CI-friendly JSON mode&lt;br&gt;
--json emits one machine-readable JSON object.&lt;br&gt;
--yes allows non-interactive proceed on WARN.&lt;br&gt;
Exit codes:&lt;br&gt;
0 install succeeded&lt;br&gt;
1 blocked, warn-not-confirmed, or pip install failure&lt;br&gt;
2 usage/argument errors&lt;/p&gt;

&lt;p&gt;5) Logging&lt;br&gt;
Decision logs written as JSONL.&lt;br&gt;
Primary path: ~/.pip_guardian/guardian.log&lt;br&gt;
Fallback path (if home not writable): ./.pip_guardian/guardian.log&lt;br&gt;
Installation&lt;br&gt;
Install from PyPI:&lt;/p&gt;

&lt;p&gt;python -m pip install pip-guardian&lt;br&gt;
Upgrade:&lt;/p&gt;

&lt;p&gt;python -m pip install --upgrade pip-guardian&lt;br&gt;
Install from source (development):&lt;/p&gt;

&lt;p&gt;git clone &lt;a href="https://github.com/AnantDhavale/pip-guardian.git" rel="noopener noreferrer"&gt;https://github.com/AnantDhavale/pip-guardian.git&lt;/a&gt;&lt;br&gt;
cd pip-guardian&lt;br&gt;
python -m pip install .&lt;/p&gt;

&lt;p&gt;Usage&lt;/p&gt;

&lt;p&gt;guardian install requests&lt;br&gt;
guardian install litellm==1.82.8&lt;br&gt;
guardian install fastapi --index-url &lt;a href="https://pypi.org/simple" rel="noopener noreferrer"&gt;https://pypi.org/simple&lt;/a&gt;&lt;br&gt;
guardian install requests --json --yes&lt;/p&gt;

&lt;p&gt;Policy and IOC files&lt;br&gt;
policies/config.yaml:&lt;br&gt;
age thresholds&lt;br&gt;
deep-scan score thresholds&lt;br&gt;
executable .pth blocking toggle&lt;br&gt;
policies/blocklist.json:&lt;br&gt;
package/version deny list&lt;br&gt;
maintainer deny list&lt;/p&gt;

&lt;p&gt;Repository structure&lt;br&gt;
guardian/cli.py - command entrypoint&lt;br&gt;
guardian/policy_engine.py - risk decision logic&lt;br&gt;
guardian/scanner.py - deep artifact scanning&lt;br&gt;
guardian/pypi_checker.py - PyPI metadata collection&lt;br&gt;
guardian/logger.py - local decision logging&lt;/p&gt;

&lt;p&gt;Notes:&lt;br&gt;
This reduces risk but is not a full malware sandbox.&lt;br&gt;
For production, use pinned dependencies and hash-locked installs.&lt;/p&gt;

</description>
      <category>cybersecurity</category>
      <category>llm</category>
      <category>python</category>
      <category>security</category>
    </item>
    <item>
      <title>OAuth for AI Agents</title>
      <dc:creator>Anant</dc:creator>
      <pubDate>Thu, 02 Apr 2026 23:03:29 +0000</pubDate>
      <link>https://forem.com/anantdhavale1/oauth-for-ai-agents-4id7</link>
      <guid>https://forem.com/anantdhavale1/oauth-for-ai-agents-4id7</guid>
      <description>&lt;p&gt;New here. I am looking for some beta users for Agent Guard, it is aimed at building zero trust / Oauth for AI Agents. Think of it as Runtime permission checks for AI agent actions.&lt;/p&gt;

&lt;p&gt;Agent Guard is a lightweight enforcement layer that sits between your agent and tool execution. Before a tool runs, Agent Guard asks Cerone whether the action should be allowed. Cerone is the backend mastermind - the policy decision point (PDP). &lt;/p&gt;

&lt;p&gt;Some features : &lt;/p&gt;

&lt;p&gt;Add runtime guardrails without rewriting your app.&lt;br&gt;
Keep your current tools/functions and wrap them in minutes.&lt;br&gt;
Cache approvals for low-latency hot paths.&lt;br&gt;
Stay framework-agnostic (OpenAI tools, LangChain, CrewAI, custom agents).&lt;/p&gt;

&lt;p&gt;Please check it out, feedbacks/ comments/ suggestions highly appreciated ! &lt;a href="https://github.com/AnantDhavale/Agent_Guard" rel="noopener noreferrer"&gt;https://github.com/AnantDhavale/Agent_Guard&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The image is a weak Chat GPTized attempt at humor of mine, I hope you like it lol . Thank you. &lt;/p&gt;

</description>
      <category>ai</category>
      <category>oauth</category>
      <category>vibecoding</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
