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.

Coding too fast to collaborate

https://chrisloy.dev/post/2026/07/19/coding-too-fast-to-collaborate
1•chrisloy•1m ago•0 comments

RedisME:Modern, Lightweight, Cross-Platform RDM

https://www.hepengju.com/
1•hepengju•1m ago•0 comments

Node graphs suck for metrics and traces

https://play.mapgl.org
1•vaduga•5m ago•1 comments

Dumber Mini: A Nokia-Style Phone with WhatsApp and Maps

https://dumbermini.com/
1•thunderbong•7m ago•0 comments

Trump, not Iran, is the greatest danger

https://www.theguardian.com/commentisfree/2026/jul/18/donald-trump-iran-world-danger-bombing-us
2•0x54MUR41•8m ago•0 comments

Show HN: AI mock interview tool that scores your answers – free, no signup

https://interviewpracticeai.com
1•BenGallagh•11m ago•0 comments

An Interesting Number (2005)

https://www.cut-the-knot.org/blue/InterestingStory.shtml
1•wolfi1•11m ago•0 comments

South Korea wants the port of Busan to become a hub for polar shipping

https://asia.nikkei.com/spotlight/policy-asia/south-korea-s-lee-seeks-arctic-lift-for-country-s-s...
2•cromka•11m ago•0 comments

Qwen 3.8 Max Preview

https://www.qwencloud.com/pricing/token-plan
1•lebovic•12m ago•1 comments

Valve say there's no end in sight to the memory crisis, prices going to increase

https://www.pcgamer.com/hardware/steam-machines/valve-says-theres-no-end-in-sight-to-the-memory-c...
2•haunter•13m ago•0 comments

Qwen 3.8 with 2.4T parameters, available on Alibaba Token plan

https://twitter.com/Alibaba_Qwen/status/2078754377473601787
1•theanonymousone•14m ago•1 comments

Facebook Is Down

https://www.facebook.com/
2•eric_khun•17m ago•4 comments

Show HN: Shikigami, run AI coding agents in parallel, each in a Git worktree

https://shikigami.dev/
1•igor_nast•20m ago•0 comments

Half a Second – a book about the XZ backdoor

https://www.half-second.com/
1•zvr•20m ago•0 comments

Moon Phase Clock – Realistic, Full Screen

https://medium.com/@thesuperrepemail/moon-phase-clock-with-full-screen-mode-1a1e230fa710
2•mssblogs•22m ago•0 comments

Boys' ADHD symptoms linked to addictive social media use in new study

https://www.msn.com/en-us/health/other/boys-adhd-symptoms-linked-to-addictive-social-media-use-in...
2•jnord•22m ago•0 comments

Qwen3.8 is launching and going open-weight soon

https://twitter.com/Alibaba_Qwen/status/2078759124914098291
40•nh43215rgb•24m ago•4 comments

More emulation goodness, an Intel Itanium (IA-64) emulator that boots Windows

https://raymii.org/s/blog/Intel_Itanium_IA-64-Emulator_that_boots_Windows.html
1•jandeboevrie•31m ago•0 comments

Victora proposes new laws to target big tech and online trolls

https://www.abc.net.au/news/2026-07-19/victoria-social-media-big-tech-laws/106932668
2•aragilar•34m ago•0 comments

Anthropic runs large-scale code migrations with Claude Code

https://claude.com/blog/ai-code-migration
2•vinhnx•38m ago•0 comments

Ask HN: Is anyone else facing login issues on Facebook?

3•wasi0013•39m ago•3 comments

Protester calls out Amazon CTO for allowing Israel to use their AI towards Gaza

https://www.reddit.com/r/chaoticgood/s/4Pla2e38AV
3•trymas•39m ago•0 comments

Where I erred in my original post about Kimi and my views on open-weight AI

https://twitter.com/deanwball/status/2078619513575137330
2•tosh•40m ago•1 comments

When China's open-source AI is a trap

https://www.economist.com/international/2026/07/14/when-chinas-open-source-ai-is-a-trap
3•chvid•42m ago•2 comments

LG Monitors Caught Installing Adware and App with Access to All System Resources

https://www.privacyguides.org/news/2026/07/17/lg-monitors-caught-installing-adware-and-app-with-a...
3•taubek•43m ago•0 comments

DeepSeek routes your request to Fable5

https://twitter.com/synthwavedd/status/2078514339552628880
2•lijialjun•44m ago•1 comments

Refs: Mutable Arrays in jax

https://docs.jax.dev/en/latest/array_refs.html
1•cl3misch•44m ago•0 comments

We Merged with Machines a Long Time Ago – Futurology and Berggruen Institute [video]

https://www.youtube.com/watch?v=tDccIoz-SFI
1•lioeters•44m ago•0 comments

All the Cool Kids Are Birding

https://www.theatlantic.com/health/2026/07/birding-millennials-genz/687910/
1•ep_jhu•47m ago•0 comments

Show HN: OfflineTTS — Free browser-based TTS & STT that runs locally

https://offlinetts.com/
2•twainyoung•48m ago•1 comments