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.

Avatar-cursor/- an AI shop assistant that points and acts on your site

https://github.com/eliasschwalme/avatar-cursor/blob/main/demo.gif
1•eschwalme•4m ago•0 comments

Anthro researcher: you're hypocritical, therefore you're wrong

https://twitter.com/Mononofu/status/2080937562739531837
1•flurly•5m ago•0 comments

Rauno's Field Notes #2

https://rauno.me/notes/2
5•acmnrs•15m ago•0 comments

North Korea arrests hackers for stealing funds from country's Central bank

https://www.coindesk.com/business/2026/07/25/north-korea-arrests-hackers-accused-of-laundering-st...
2•thisislife2•15m ago•0 comments

The Word for Art Is Human

https://saffroncr.itch.io/katavatis/devlog/1558443/the-word-for-art-is-human
2•r3trohack3r•15m ago•0 comments

Trump Caught Between Apple and Micron in Fight over Chinese Chips

https://www.wsj.com/tech/trump-apple-micron-china-chips-784bbd3d
3•thewebguyd•15m ago•0 comments

Gattaca and the quiet Doomsday of genetic determinism

https://thebulletin.org/premium/2026-07/gattaca-and-the-quiet-doomsday-of-genetic-determinism/
4•bookofjoe•17m ago•0 comments

Minecraft punishes casual players. I made a datapack to fix it [video]

https://www.youtube.com/watch?v=zyRH8W58fRI
2•theNotFractured•18m ago•0 comments

How to Write a Git Commit Message (2014)

https://cbea.ms/git-commit/
2•downbad_•18m ago•1 comments

First spatially resolved spectral-index map of a black hole's event horizon

https://www.eurekalert.org/news-releases/1136724
2•MarcoDewey•18m ago•0 comments

Why do some languages feel weirdly familiar?

https://www.thecambridgelanguagecollective.com/linguistics/why-do-some-languages-feel-weirdly-fam...
2•theanonymousone•19m ago•0 comments

Amen Break

https://en.wikipedia.org/wiki/Amen_break
7•root-parent•20m ago•0 comments

Politician reads AI prompt during assembly

https://www.youtube.com/watch?v=wlYa8NV5k-U
5•root-parent•23m ago•0 comments

Lone dev spends 2 years figuring out how to make anyone 10 times more productive

https://www.taskloco.com/
2•taskloco_nyc•27m ago•0 comments

Re: I Stopped "Creating Content"

https://unattributed.cc/re-why-i-stopped-creating-content
2•speckx•27m ago•0 comments

Hermes AI agent used to automate attack on Thai Finance Ministry

https://www.bleepingcomputer.com/news/security/hermes-ai-agent-used-to-automate-attack-on-thai-fi...
2•Brajeshwar•28m ago•0 comments

The Chuwi MiniBook X N150, One Year Later

https://taoofmac.com/space/reviews/2026/07/25/1700
3•rcarmo•33m ago•0 comments

Writing a (valid) C program without main()

https://labs.iximiuz.com/tutorials/c-program-without-main-a1eea557
11•birdculture•33m ago•2 comments

The End of Physical Games: What We Lost When Games Went Digital [video]

https://www.youtube.com/watch?v=EkWZGv9hRVs
2•vinhnx•35m ago•0 comments

Show HN: Free mentor for learning programming languages, fast and efficient

https://github.com/KubiKDB/AI-Tools-For-Learning
2•superquizonline•39m ago•0 comments

Wildfires Overrun NASA Deep Space Communications Complex in Spain

https://newscord.org/article/wildfires-overrun-nasa-deep-space-communications-complex-in-robledo-...
3•OgsyedIE•42m ago•0 comments

Virginia study on groundwater, data centers calls for tighter water regulations

https://apnews.com/article/data-centers-virginia-groundwater-gov-spanberger-study-564e5d3c2520190...
3•1vuio0pswjnm7•43m ago•0 comments

Wind turbine is being used to produce zero-carbon "green ammonia" fertilizer

https://energiesmedia.com/wind-turbine-stopped-electricity-wind-water-air/
41•speckx•45m ago•20 comments

MouthPad: Human-Mouth Interface [video]

https://www.youtube.com/watch?v=xReyIF5pwRo
2•mgh2•45m ago•0 comments

ChatGPT invoked God, told pastor not to worry about his symptoms

https://www.wionews.com/trending/chatgpt-invoked-god-told-pastor-not-to-worry-about-his-symptoms-...
3•theanonymousone•45m ago•1 comments

Show HN: Less-pager-mini: What a cross-platform pager would be like

https://github.com/dawsonhuang0/Less-Pager-Mini
2•dawson0•46m ago•1 comments

Zig by Example

https://zigbyexample.neocities.org/
4•signa11•47m ago•0 comments

C/C++ Path Library

https://likle.github.io/cwalk/
2•ankitg12•47m ago•0 comments

FreeBSD ports frozen after someone commits the 150MB Linux Copilot binary

https://www.osnews.com/story/145593/freebsd-ports-frozen-after-someone-commits-the-entire-150mb-l...
3•birdculture•48m ago•0 comments

Soccer outcome probabilities are calculated

https://ronikobrosly.github.io/blog/2026/7/23/soccer_sim/
2•venice_dev•49m ago•0 comments