frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Show HN: AgentShield SDK – Runtime security for agentic AI applications

https://pypi.org/project/agentshield-sdk/
2•iamsanjayk•1y ago
Hi HN,

We built AgentShield, a Python SDK and CLI to add a security checkpoint for AI agents before they perform potentially risky actions like external API calls or executing generated code.

Problem: Agents calling arbitrary URLs or running unchecked code can lead to data leaks, SSRF, system damage, etc.

Solution: AgentShield intercepts these actions:

- guarded_get(url=...): Checks URL against policies (block internal IPs, HTTP, etc.) before making the request.

- safe_execute(code_snippet=...): Checks code for risky patterns (os import, eval, file access, etc.) before execution.

It works via a simple API call to evaluate the action against configurable security policies. It includes default policies for common risks.

Get Started:

Install: pip install agentshield-sdk

Get API Key (CLI): agentshield keys create

Use in Python: from agentshield_sdk import AgentShield # shield = AgentShield(api_key=...) # await shield.guarded_get(url=...) # await shield.safe_execute(code_snippet=...)

Full details, documentation, and the complete README are at <https://pypi.org/project/agentshield-sdk/>

We built this because securing agent interactions felt crucial as they become more capable. It's still early days, and we'd love to get your feedback on the approach, usability, and policies.

Comments

subhampramanik•1y ago
Looks interesting -- Does it work like a wrapper on top of OpenAI specs? Like, can we just replace the OpenAI package with this, and it's fully integrated?
iamsanjayk•1y ago
Hey, thanks for asking! Good question.

AgentShield isn't a wrapper around the OpenAI package, so you wouldn't replace openai with it. Think of AgentShield as a separate safety check you call just before your agent actually tries to run a specific risky action.

So, you'd still use the openai library as normal to get your response (like a URL to call or code to run). Then, before you actually use httpx/requests to call that URL, or exec() to run the code, you'd quickly check it with shield.guarded_get(the_url) or shield.safe_execute(the_code).

Currently, It focuses on securing the action itself (the URL, the code snippet) rather than wrapping the LLM call that generated it.

Where to for Clojure and Enterprise Web Applications

https://github.com/factorhouse/slipway/blob/main/docs/ring-and-sente.md
1•d_t_w•1m ago•0 comments

#1 skill an FDE Forward Deployed Engineer Needs, it's not what you think

https://www.youtube.com/watch?v=CYF7T2HiLfc
1•pvergadia•1m ago•1 comments

Why Your HEIC to PNG File Is Suddenly Ten Times Bigger

https://suolex.substack.com/p/why-your-heic-to-png-file-is-suddenly
2•Hackergeist•1m ago•0 comments

How to write the perfect function (for humans who still write code) [video]

https://www.youtube.com/watch?v=2OMRWPOSw9s
1•zahlman•5m ago•0 comments

Subscriptions: Last Week Tonight with John Oliver [video]

https://www.youtube.com/watch?v=Wko-2c7lZL8
1•tchalla•9m ago•0 comments

Show HN: TeXbrain, a LaTeX editor that runs pdfTeX in the browser via WASM

https://github.com/swimmingbrain/texbrain
2•swimmingbrain•16m ago•0 comments

Voiced: Turn one voice note into a week of drafts

https://www.getvoiced.co/
1•ericchristian1_•16m ago•0 comments

How I Use Claude Code

https://www.loopwerk.io/articles/2026/how-i-use-claude-code/
1•kjmr•17m ago•0 comments

LeBron James Borrowed $300M from Insurers Arranged by Guggenheim

https://www.advisorhub.com/lebron-james-borrowed-300-million-from-insurers-arranged-by-guggenheim/
1•petethomas•17m ago•0 comments

X sends cease-and-desist to open-source project Nitter over alleged scraping

https://techcrunch.com/2026/08/25/x-sends-cease-and-desist-to-open-source-project-nitter-over-all...
2•sbulaev•17m ago•2 comments

New AI Agent to Autonomously Prepare and Send Docs Out for Signature

https://slack.com/marketplace/A095XNK8GPK-docendorse-ai-agent?nojsmode=1
1•kariopaul•18m ago•0 comments

Rumors that OpenAI recently finished new >10T parameter training run

https://twitter.com/synthwavedd/status/2092326145270456377
2•andy12_•21m ago•0 comments

The Deadly Global War for Sand (2015)

https://www.wired.com/2015/03/illegal-sand-mining/
1•EndXA•21m ago•0 comments

Former Rockstar producer says Read Dead Redemption 1 online had a "cheater jail"

https://old.reddit.com/r/gaming/comments/1vy75nq/former_rockstar_producer_says_rdr_1_online_had_a/
1•embedding-shape•22m ago•0 comments

Microsoft Copilot Cowork Controlled by Attacker, Bypassing Sandbox

https://www.promptarmor.com/resources/microsoft-copilot-cowork-sandbox-bypass
1•hackerBanana•23m ago•0 comments

Category Theory for Kids

https://kids.kiddle.co/Category_(mathematics)
2•marysminefnuf•23m ago•1 comments

Make your own Darkbloom – The Expert Network pools Macs into one model

https://github.com/walter-grace/expert-sniper
1•beargrizzzy•23m ago•0 comments

Adding diagrams to my static site generator with D2

https://www.gilesthomas.com/2026/08/adding-d2
1•gpjt•24m ago•0 comments

Japanese farmers go nocturnal as extreme heat makes the day too dangerous

https://www.theglobeandmail.com/world/article-japanese-farmers-nocturnal-heat-safety/
2•debo_•29m ago•0 comments

Rare Disease, Real Kid: The MVA Hackathon 2026

https://sagebio-rare-disease-real-kid-mva-hackathon-2026.hf.space/
1•dsr12•30m ago•0 comments

1 Bit Pixel

https://1bitstudio.app/pixel/
2•selimonder•30m ago•0 comments

Tracing Claude Tag, Anthropic's Slack Agent

https://docs.scorecard.io/intro/claude-tag-tracing
2•Rutledge•32m ago•0 comments

OpenAI's 700W Jalapeño ASIC outpaces 1,400W Nvidia flagship GPU

https://www.tomshardware.com/tech-industry/semiconductors/openai-says-its-jalapeno-chip-beats-nvi...
1•rbanffy•35m ago•0 comments

One Go binary, one YAML file, one SQLite database: I wrote my monitoring tool

https://rvier.fr/posts/why-i-wrote-my-own-monitoring-tool-EN
7•brvier•41m ago•1 comments

Claim your city's #1 spot

https://www.outbidhere.com
1•paulmbw•41m ago•1 comments

Valley of the Ants

https://en.wikipedia.org/wiki/Valley_of_the_ants
1•marysminefnuf•41m ago•0 comments

Ripping Off the Hey.com Band-Aid

https://kylemcgough.com/blogs/ripping-off-the-heycom-band-aid
20•sosodev•45m ago•2 comments

Python's pre-declared constants are kinda weird

https://sebsite.pw/w/20260801-pythonconstants.html
30•rbanffy•45m ago•3 comments

Same net, same seed – 100% vs. 50% on unseen magnitudes

https://structured-intelligence.grok.me
1•jarrodseth•46m ago•0 comments

Making Atuin sync 32x faster with packfiles

https://blog.atuin.sh/making-atuin-sync-32x-faster-with-packfiles/
3•sea-gold•46m ago•1 comments