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.

Ukrainian drones hit Russia's refinery Zelenskyy says Siberia now 'within reach'

https://www.cnbc.com/2026/07/07/ukraine-russia-omsk-oil-refinery-putin-nato.html
1•tcp_handshaker•1m ago•0 comments

TRCR – Time tracking, projects, CRM and invoicing in one tool

https://trcr.pro
1•mihailshumilov•2m ago•0 comments

Midtown NYC building 'shifting' and in danger of 'localized collapse'

https://nypost.com/2026/07/07/us-news/midtown-nyc-building-shifting-and-in-danger-of-localized-co...
1•appreciatorBus•3m ago•0 comments

No Effort

https://tomreinert.de/no-effort/
1•tom2948329494•3m ago•0 comments

Show HN: Docx-CLI: agents read/edit Word docs using 1/2 the time and tokens

https://github.com/kklimuk/docx-cli
1•kirillklimuk•4m ago•1 comments

PL/Ruby: Ruby as a procedural language for PostgreSQL (functions, triggers, SPI)

https://github.com/commandprompt/plruby
2•thunderbong•5m ago•0 comments

Show HN: How AI-generated is this website?

https://slopcop.adriankrebs.ch
1•hubraumhugo•5m ago•0 comments

Show HN: Fork – Let users build features on top of existing applications

https://withfork.co/
1•realdjpaulyd•6m ago•0 comments

Former Facebook insiders sketch a low-cost AI endgame on Threads for Meta

https://runtimewire.com/article/former-facebook-insiders-sketch-meta-s-low-cost-ai-endgame-on-thr...
1•ryanmerket•6m ago•0 comments

Rich Guy Quote Journalism

https://stringinamaze.net/p/rich-guy-quote-journalism
1•i4i•7m ago•1 comments

We learned to trust our AI code reviewer at DoorDash

https://careersatdoordash.com/blog/how-we-learned-to-trust-our-ai-code-reviewer-at-doordash/
1•luispa•8m ago•0 comments

Notes on Software Quality

https://anthonyhobday.com/blog/20260410
1•speckx•9m ago•0 comments

Show HN: OpenSpeech – Compare open-source TTS models side-by-side

https://www.openspeech.dev
1•ushercakes•9m ago•0 comments

FOMO-Driven Development

https://estuary.dev/blog/fomo-driven-development/
1•danthelion•9m ago•0 comments

AI needs the best-of-breed data stack: Postgres and ClickHouse

https://clickhouse.com/blog/ai-best-of-breed-data-stack
1•saisrirampur•10m ago•0 comments

Show HN: Cfswitch – Switch between multiple Cloudflare accounts in Wrangler

https://github.com/dukeeagle/cfswitch
1•lukeigel•11m ago•0 comments

Abusing the Sandbox for a Critical Cross-Tenant Vulnerability in Writer AI

https://www.sandsecurity.ai/blog/writeout-writer-ai-cross-tenant
1•talhof8•13m ago•0 comments

Every night trillions of tiny creatures rise from the ocean depths

https://www.bbc.com/future/article/20260706-the-deep-sea-creatures-that-rise-every-night
1•saikatsg•14m ago•0 comments

A new runtime for k and q: l

https://lv1.sh/
2•skruger•15m ago•0 comments

The MFA Rollout Disaster

https://stuartdotson.substack.com/p/the-wetness-humaning-multiplier
1•sdotson•15m ago•0 comments

Tech jobs market in 2026, part 3: hiring managers and job seekers

https://newsletter.pragmaticengineer.com/p/tech-jobs-market-in-2026-part-3-hiring
2•nedruod•18m ago•0 comments

Opbox: Real-time sync for plaintext files

https://www.opbox.dev/
1•shikhar•19m ago•0 comments

Who's doing what on AI security in the US government?

https://horizonlaunchpad.substack.com/p/whos-doing-what-on-ai-security
1•paulpauper•21m ago•0 comments

Why the West stopped making land

https://worksinprogress.co/issue/why-the-west-stopped-making-land/
2•paulpauper•21m ago•0 comments

Tell HN: Fable 5 promotion extended through July 12, 2026 at 11:59:59 PM PT

5•theanonymousone•21m ago•0 comments

Wiesbaden Notes

https://marginalrevolution.com/marginalrevolution/2026/07/wiesbaden-notes.html
1•paulpauper•21m ago•0 comments

Visual Studio Code Learn

https://code.visualstudio.com/learn
1•saikatsg•23m ago•0 comments

Show HN: An agentic CRM, built for AI agents to drive over plain HTTP

https://github.com/crmkit/crmkit
1•_pdp_•23m ago•0 comments

We will happily disempower ourselves: Go edition

https://blog.jcx.au/posts/we-will-happily-disempower-ourselves-go-edition
1•speckx•23m ago•0 comments

How to widen access to the critical minerals that the world needs

https://www.nature.com/articles/d41586-026-02100-8
1•Bender•24m ago•0 comments