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.

Apple seeks to buy memory chips from blacklisted Chinese company

https://www.ft.com/content/d72a25e2-7bde-4aa9-bd8d-0c4f3d6cb2cb
1•ilreb•2m ago•0 comments

Agentic Trading on Robinhood

https://robinhood.com/us/en/agentic-trading/
2•huragok•5m ago•1 comments

(Planet Money, NPR) "We almost had a smartphone in the 90s. Why did it fail?"

https://www.npr.org/2026/06/26/nx-s1-5872785/general-magic-sony-magiclink-constraints
1•wnc3141•11m ago•2 comments

I built a marketplace where the money can be verified by anyone

https://old.reddit.com/r/SubliminalsVerytasium/comments/1ufhleb/i_built_a_marketplace_where_the_m...
1•bbenevolence•13m ago•0 comments

Find the right AI agents to build

https://www.agentideahub.com
1•mattmerrick•16m ago•0 comments

TUI email client in native Golang with LLM based drafting functions

https://mail.intellios.ai
1•coolwulf•18m ago•0 comments

Nomad: Portable, offline media server powered by the ESP32-S3 in a thumbdrive

https://www.instructables.com/Jcorp-Nomad-Mini-WIFI-Media-Server/
1•thunderbong•18m ago•0 comments

US allows Anthropic to release Mythos AI to 'trusted' US organizations

https://www.reuters.com/technology/us-releases-anthropic-model-mythos-some-us-companies-semafor-r...
1•swolpers•19m ago•0 comments

If they start to gatekeep who gets to use the best models, that is a DoW

https://twitter.com/jmrphy/status/2070528497752166454
1•Jimmc414•19m ago•0 comments

Show HN: I replaced $500/mo in freelance tools with 20 ChatGPT prompts

https://medium.com/@promptalex53/1c857c6f424a
1•promptalex53•24m ago•0 comments

WordStar: A Writer's Word Processor (1996)

https://www.sfwriter.com/wordstar.htm
4•droidjj•24m ago•0 comments

Meta asks California lawmakers for shield from child harm penalties

https://www.politico.com/news/2026/06/26/exclusive-meta-asks-california-lawmakers-for-shield-from...
2•donsupreme•28m ago•0 comments

Smugglers Create Fake Google Maps Car, US Border Patrol Catches

https://www.autoevolution.com/news/smugglers-create-fake-google-maps-car-border-patrol-agents-act...
1•gnabgib•32m ago•0 comments

Ask HN: MacBook vs. Dedicated GPU for LLM

4•mzubairtahir•37m ago•1 comments

OpenData – Open-Source and Object Store Native Databases

https://www.opendata.dev/
1•apurvamehta•40m ago•0 comments

Love Conquers Fear: Humanity, AI, and the Age of Abundance for All

https://www.amazon.com/Love-Conquers-Fear-Humanity-Abundance-ebook/dp/B0GX32NPX5
1•ilreb•46m ago•0 comments

Boeing 777 makes dangerous ~25ft low pass over Horseshoe Bay Resort Jet Center

https://twitter.com/EBaviation/status/2069953669710110852
2•leetrout•50m ago•0 comments

Threats to US payment rails helped trigger Bessent's AI worries

https://www.semafor.com/article/06/26/2026/bessent-engaged-on-ai-following-warnings-about-fed-pay...
1•tiahura•52m ago•0 comments

Kohana, a prediction market where you write the question

https://kohana.xyz/
1•melan13•58m ago•0 comments

Rheinmetall gambled on Germany's doomed warship project – and lost

https://www.ft.com/content/e3fa2351-72bd-40e1-97e0-5a6ae0a63a2b
2•JumpCrisscross•1h ago•1 comments

Where production policy belongs: building Eliya in public

https://foojay.io/today/where-production-policy-belongs-building-eliya-in-public/
2•fahimfarookme•1h ago•3 comments

Anatomy of a Failed (Nation-State?) Attack

https://grack.com/blog/2026/06/25/dissecting-a-failed-nation-state-attack/
2•signa11•1h ago•0 comments

Ornith-1.0: Self-Scaffolding LLMs for Agentic Coding

https://deep-reinforce.com/ornith_1_0.html
3•modinfo•1h ago•0 comments

Ukrainian Attacks Spur State of Emergency Declaration in Crimea

https://www.nytimes.com/2026/06/26/world/europe/crimea-ukraine-state-emergency.html
4•JumpCrisscross•1h ago•0 comments

Codex-maxxing for long-running work

https://openai.com/index/codex-maxxing-long-running-work/
1•gmays•1h ago•0 comments

Software Is Becoming Marketing

https://www.terezatizkova.com/writing/software-abundance
2•tylerdane•1h ago•0 comments

Cybersecurity firms targeted by fraudulent OpenAI organization invites

https://www.bleepingcomputer.com/news/security/cybersecurity-firms-targeted-by-fraudulent-openai-...
1•Timofeibu•1h ago•0 comments

For Peter

https://lucybellwood.com/for-peter/
3•wonger_•1h ago•1 comments

How China Is Gutting Western Automakers (2025)

https://newsletter.dunneinsights.com/p/how-china-is-gutting-western-automakers
1•toomuchtodo•1h ago•0 comments

A man who did nothing, brilliantly

https://theidlegazette.beehiiv.com/p/the-man-who-did-nothing-brilliantly-5
1•vinhnx•1h ago•0 comments