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.

Toyota pump tech could be key to hydrogen-combustion practicality

https://www.autocar.co.uk/car-news/technology/toyota-pump-tech-could-be-key-hydrogen-combustion-p...
1•breve•1m ago•0 comments

Track you Claude Code usage in dollars

https://www.claudeusage.com/leaderboard
1•bazarkua•2m ago•0 comments

Seamless iPad (or any device that can run a web browser) drawing into org-mode

https://github.com/larrasket/org-pad.el
1•lr0•8m ago•0 comments

China cracks down on AI companions, forcing millions to break up

https://www.abc.net.au/news/2026-07-19/china-cracks-down-on-artificial-intelligence-companions/10...
1•defrost•9m ago•1 comments

Archaeologists found Homer's Iliad inside a 1,600-year-old Egyptian mummy

https://www.sciencedaily.com/releases/2026/07/260713084918.htm
2•NordStreamYacht•22m ago•0 comments

IceCream – Never use print() to debug again

https://github.com/gruns/icecream
1•gregsadetsky•23m ago•0 comments

Claude Is Painful

5•kderbyma•24m ago•3 comments

Deepsec

https://github.com/vercel-labs/deepsec
1•handfuloflight•29m ago•0 comments

AI Mania Is Eviscerating Global Decision-Making

https://ludic.mataroa.blog/blog/ai-mania-is-eviscerating-global-decision-making/#fnref:3
3•subset•33m ago•1 comments

Prompt Injection Attacks Are Thwarting AI Hacking Agents

https://arstechnica.com/security/2026/07/now-defenders-are-embracing-the-prompt-injection-too/
1•sbulaev•36m ago•1 comments

Doctors question evidence behind Pentagon plan for testosterone screening

https://www.theguardian.com/us-news/2026/jul/18/us-military-testosterone-screening-doctors
1•wslh•37m ago•1 comments

University of Illinois is insuring itself against a drop in Chinese students

https://www.chicagobusiness.com/education/university-illinois-insurance-decline-chinese-enrollment/
2•MaysonL•38m ago•1 comments

AI as Normal Technology

https://knightcolumbia.org/content/ai-as-normal-technology
1•elsewhen•39m ago•0 comments

Ergonomic keyboard generator with hand scanning

https://ryanis.cool/cosmos/
1•ffin•42m ago•0 comments

My app just got approved by the App Store

https://apps.apple.com/us/app/kleios/id6765974356
2•idclark34•46m ago•5 comments

No, an AI cannot know the future and never will..

https://pulkitsharma.substack.com/p/no-an-ai-cannot-know-the-future-and
1•pulkitsh1234•47m ago•0 comments

Cash is king again at Tokyo's bars after credit processor fails

https://www.japantimes.co.jp/business/2026/07/14/companies/zentoshin-kabukicho-bar-cash/
1•mikhael•47m ago•0 comments

Flightwake – a flight recorder for AI coding agents, not a navigator

https://github.com/kaiwutech-TW/flightwake
1•kaiwuTW•48m ago•0 comments

Superformula

https://en.wikipedia.org/wiki/Superformula
2•elsewhen•51m ago•0 comments

Social media algorithms: accumulated aesthetic artifacts

https://henderson.lol/posts/202607-social-media-algorithms-accumulated-aesthetic-artifacts
3•hendersonreed•59m ago•0 comments

Cloud providers are out of B200 GPUs after the Inkling release

https://twitter.com/Akashi203/status/2078615659366252877
4•Jr23_xd•1h ago•2 comments

Better and Cheaper Than IPTV

https://github.com/stupside/castor
17•xonery•1h ago•6 comments

Lobsters Interview with matheusmoreira about Lone Lisp

https://alexalejandre.com/interviews/interview-with-matheus-moreira/
4•birdculture•1h ago•1 comments

Show HN: EnviousWispr, an open-source Wispr Flow alternative for macOS

https://github.com/saurabhav88/EnviousWispr
1•EnviousLabs•1h ago•0 comments

I built code-repair training data and shipped the eval so you can rerun it

https://huggingface.co/datasets/TrueSET/verified-code-repair
1•TrueSET_Data•1h ago•2 comments

Miserere (Allegri)

https://en.wikipedia.org/wiki/Miserere_(Allegri)
2•thunderbong•1h ago•0 comments

AI Assisted Vulnerability Research on Embedded Targets

https://quentinkaiser.be/security/2026/07/18/ia-assisted-vuln-research/
1•snorbleck•1h ago•0 comments

Cmpunlocker – Unlock Full GA100 Compute and 64GB HBM2e on the Nvidia CMP 170HX

https://github.com/amoghmunikote/cmpunlocker
1•amoghmunikote•1h ago•0 comments

Transcribe.cpp

https://workshop.cjpais.com/projects/transcribe-cpp
48•sebjones•1h ago•8 comments

One token is enough: fingerprinting LLMs from one token output distributions

https://arxiv.org/abs/2607.10252
3•anigbrowl•1h ago•0 comments