惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

The GitHub Blog
The GitHub Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Microsoft Security Blog
Microsoft Security Blog
J
Java Code Geeks
S
SegmentFault 最新的问题
Apple Machine Learning Research
Apple Machine Learning Research
N
Netflix TechBlog - Medium
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
博客园_首页
宝玉的分享
宝玉的分享
Google DeepMind News
Google DeepMind News
B
Blog RSS Feed
Hugging Face - Blog
Hugging Face - Blog
量子位
Blog — PlanetScale
Blog — PlanetScale
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
阮一峰的网络日志
阮一峰的网络日志
D
Docker
罗磊的独立博客
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
云风的 BLOG
云风的 BLOG
IT之家
IT之家
MyScale Blog
MyScale Blog
Microsoft Azure Blog
Microsoft Azure Blog

Hacker News

GitHub - SeanFDZ/macmind: Single-layer transformer in HyperTalk for the classic Macintosh Show HN: Agent-cache – Multi-tier LLM/tool/session caching for Valkey and Redis Bonsai 1-bit WebGPU - a Hugging Face Space by webml-community Moving a large-scale metrics pipeline from StatsD to OpenTelemetry / Prometheus GitHub - Nightmare-Eclipse/RedSun: The Red Sun vulnerability repository GitHub - SethPyle376/hiraeth: Local AWS emulator focused on fast integration testing, with SQS support, SQLite-backed state, and a debug-friendly web UI. GitHub - macOS26/Agent: Any AI, replaces Claude Code, Cursor, OpenClaw. Over 18 LLM providers (Claude, OpenAI, Gemini, Ollama, Zai, HF, Qwen) wired into a native Mac app that writes code, builds Xcode projects, bumps versions, manages git, automates Safari, use AppleScript, JS or Accessibility, extend Agent! w/ MCP Servers, run tasks from your iPhone via Messages. YouTube now lets you turn off Shorts I Made a Terminal Pager Burgers | マクドナルド公式 Commands — HackerNews CLI documentation ChatGPT for Excel PiCore - Raspberry Pi Port of Tiny Core Linux Live Nation illegally monopolized ticketing market, jury finds Google Broke Its Promise to Me. Now ICE Has My Data. Founding Engineer at Adaptional | Y Combinator CRISPR takes important step toward silencing Down syndrome’s extra chromosome GitHub - saffron-health/libretto: The AI toolkit for building reliable browser automations US v. Heppner (S.D.N.Y. 2026) no attorney-client privilege for AI chats [pdf] Retrofitting JIT Compilers into C Interpreters IPv6 – Google The Accursèd Alphabetical Clock Cybersecurity Looks Like Proof of Work Now Fragments: April 14 Cal.com Goes Closed Source: Why AI Security Is Forcing Our Decision | Cal.com - Scheduling Software for Online Bookings Laravel raised money and now injects ads directly into your agent When moving fast, talking is the first thing to break Too much Discussion of the XOR swap trick – Heather Cafe Introduction to Spherical Harmonics for Graphics Programmers The Grand Line
Package Managers need global hooks
Nemo · 2026-06-18 · via Hacker News

17 Jun 2026

This post is an expansion of what I wrote on r/archlinux as a proposal for AUR helpers. It is a call for every package manager to add support for global hooks.

The packaging ecosystems that we all rely on have been under constant attacks. The most interesting countermeasures currently are: Dependency Cooldowns, and Dependency Policies. A third interesting one is Homebrew’s cooldown which is a 1 day wait before they automatically bump a package from Python/NPM ecosystems.

In addition, almost every security vendor now has a package management “firewall” offering (Socket, Datadog, Safedep for eg). The various ways this can work is:

  1. Registry mode, where you can point your package manager at a local registry and it proxies requests, blocking access wherever it deems fit.
  2. Shell wrapper, where you alias your package manager and it intercepts your commands. Shell aliases are a very weak security boundary.
  3. MITM mode, where you configure it as a HTTPS Proxy and it intercepts your network traffic.

I don’t like any of these. All of the above depend heavily on either the Registry APIs, or the command schema. I also don’t like mechanisms that require any additional infra (such as a hosted pass-through registry that scans stuff), since it is additional infrastructure only accessible to companies and not individual developers.

My radical package-manager idea is this: every package manager should support global hooks. Cooldowns and Policies are just implementation details that a decent hook system should already allow you to do. What I mean by a global hook is: Code configured globally that runs before various stages in your package manager’s workflow. This is different from “local package hooks” - package-specific code that runs during/before/after your package gets installed.

I built a Dependency Policy proof-of-concept using the StepSecurity OSS Feed and pnpm’s hook system. Every package install is checked against the threat feed and it raises an exception if we find something malicious being installed. Unfortunately:

  • pnpm’s hooks are on a per-workspace basis. This means you can’t run them for global installs, or configure them globally.
  • NPM does not support hooks.
  • Yarn has a hook API that yarn plugins can use, but I’m not sure if you can configure it globally.

But moving across to other package managers, the same system can help us deal with problems. An AUR helper can add hook-scripts, and you can configure your own threat-feed or malware scanner as a hook in the PreClone or PreBuild stage. More importantly - a hook doesn’t have to be a package, and it should be treated as global configuration.

We shouldn’t have to reinvent every defensive feature in every package manager. Ask your package manager to support global hooks instead:

Published on June 17, 2026