frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

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.

30 things I've learned from 30 years freelancing

https://lernerpython.com/2025/12/08/30-things-ive-learned-from-30-years-in-business/
1•reuven•5m ago•0 comments

Embrace the Grind (2021)

https://jacobian.org/2021/apr/7/embrace-the-grind/
1•tosh•9m ago•0 comments

What to Write

https://jacobian.org/2009/nov/10/what-to-write/
1•tosh•14m ago•0 comments

Show HN: The largest free animated icon library for Vue (523 Lucide icons)

https://respeak-io.github.io/lucide-motion-vue/
1•evolabs•15m ago•0 comments

Snowflake Datastream: Kafka-native streaming in Snowflake

https://www.snowflake.com/en/product/features/datastream/
1•Dionakra•15m ago•0 comments

Memory AI Server Aims to Shatter the Memory Wall

https://spectrum.ieee.org/huge-memory-ai-server
1•rbanffy•15m ago•0 comments

France Needs 45 Years to Grow its way out

https://julienreszka.com/blog/france-needs-45-years-to-grow-its-way-out/
1•julienreszka•16m ago•0 comments

Do you find yourself aimlessly scrolling? You're not alone

https://www.bbc.com/news/articles/czd2mq505dpo
1•bishopsmother•19m ago•0 comments

Realtime regression in non-English production voice agents

https://community.openai.com/t/realtime-regression-in-non-english-production-voice-agents-gpt-rea...
1•bishopsmother•19m ago•0 comments

Pensero – Token winter is coming

https://pensero.ai/blog/token-winter-is-coming
1•sabatesduran•21m ago•0 comments

KDE Has Long Used Dragons, and Dragons Come from Hatched Eggs

https://techrights.org/n/2026/06/03/KDE_Has_Long_Used_Dragons_and_Dragons_Come_From_Hatched_Eggs....
1•amcclure•22m ago•0 comments

Haiku, a generative music album for macOS

https://www.giorgiosancristoforo.net/ooame/
1•ron_k•22m ago•0 comments

HPE Catches Its First GenAI Wave with Enterprises, Sovereigns, and Neoclouds

https://www.nextplatform.com/compute/2026/06/04/hpe-catches-its-first-genai-wave-with-enterprises...
1•rbanffy•22m ago•0 comments

Drew DeVault Can Still Redeem His Reputation

https://techrights.org/n/2026/06/04/Drew_DeVault_Can_Still_Redeem_His_Reputation_Revisiting_His_A...
1•amcclure•24m ago•1 comments

Microsoft, Atom Computing, EeroQ update their quantum computing progress

https://arstechnica.com/science/2026/06/microsoft-atom-computing-eeroq-update-their-quantum-compu...
1•rbanffy•24m ago•0 comments

Emacs with a native Metal rendering back end (macOS)

https://github.com/tanrax/emacs-gpu
2•andros•27m ago•0 comments

D4M

https://d4m.mit.edu/
1•tosh•28m ago•0 comments

GNU/Linux Usage Rising Among Gamers, but "Hardware Survey Data Not Available."

https://techrights.org/n/2026/06/03/GNU_Linux_Usage_Rising_Among_Gamers_But_Hardware_Survey_Data_...
3•amcclure•28m ago•0 comments

WebGPU simulation of a magnetic table clamp

https://jasmcole.com/2026/05/30/clamperes-law
1•jasmcole•30m ago•0 comments

New York's 3D printer law is NOT gun control; it's manufacturing control [video]

https://www.youtube.com/watch?v=ma12AyQHzYs
1•dataflow•31m ago•0 comments

Signal Without Smartphone

https://github.com/almet/signal-without-smartphone
2•p4bl0•32m ago•0 comments

Pay Attention

https://www.theatlantic.com/ideas/2026/05/nyu-jonathan-haidt-commencement-speech/687168/
1•juliangoetze•34m ago•0 comments

TypeScript Infers Type Variables

https://norswap.com/typescript-type-variable-inference/
1•norswap•35m ago•0 comments

Thanks to robots, Ukraine is now talking about winning, not just surviving

https://www.defenseone.com/technology/2026/06/ukraine-robots-winning/413902/
1•vrganj•35m ago•0 comments

The Winamp Skin Museum whips the Llama's ass (2020)

https://www.rockpapershotgun.com/the-winamp-skin-museum-really-whips-the-llamas-ass
1•Michelangelo11•37m ago•0 comments

Gemma 4 12B: The Developer Guide

https://developers.googleblog.com/gemma-4-12b-the-developer-guide/
2•theanonymousone•39m ago•0 comments

Ask HN: Best Claude Code thinking word you've seen?

3•akashwadhwani35•39m ago•1 comments

Norm – lightweight PostgreSQL SQL helper for Go structs

https://github.com/juggle73/norm
1•juggle73•41m ago•0 comments

Flesh-eating screwworm confirmed in Texas as parasite crosses Mexican border

https://www.reuters.com/business/healthcare-pharmaceuticals/unconfirmed-us-case-flesh-eating-scre...
1•justacrow•44m ago•0 comments

MultiSlack – I achieved perfect context-switching by removing the switch

https://multislack.net/
1•pro_methe5•47m ago•0 comments