npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

uzzar-cli

v0.1.0

Published

System command safety blocker

Downloads

93

Readme

tl;dr with Uzzar, you can't rm -rf /, dd if=/dev/zero of=/dev/, mkfs, chmod -R 777 /, chown -R, find / -delete, shutdown, reboot, or kill -9 -1

the real flex here was testing this tool to see that is works. good luck!🤘

uzzar

uzzar is a command wrapper installer that intercepts high-risk binaries and blocks policy-matched commands. You can't run rm -rf /, rm -rf /*, --no-preserve-root, dd if=/dev/zero of=/dev/, dd if=/dev/random of=/dev/, mkfs, chmod -R 777 /, chown -R, find / -delete, shutdown, reboot, or kill -9 -1 with uzzar enabled.

What Gets Wrapped

uzzar install attempts to wrap these binaries when present:

  • rm
  • dd
  • chmod
  • chown
  • mv
  • find
  • shutdown
  • reboot
  • kill
  • ln
  • mkfs

Enforcement Scope

npm i -g uzzar only installs the CLI package. Actual command interception starts after sudo uzzar install, which replaces target binaries with wrappers.

Install

npm i -g uzzar
sudo uzzar install

Expected outcome:

  • /usr/local/uzzar is created
  • a backup of each wrapped binary is stored under /usr/local/uzzar/original
  • wrapper scripts are placed at original binary paths
  • a manifest is written to /usr/local/uzzar/install-manifest.json

Uninstall

sudo uzzar uninstall

Expected outcome:

  • each wrapped binary is restored from manifest-backed backups
  • /usr/local/uzzar is removed

Policy

Default policy file:

/usr/local/uzzar/policy.json

Default bundled policy template:

assets/policy.json

Policy contract:

  • JSON object with blockPatterns as string[]
  • matching is case-insensitive normalized command matching with * wildcard support

Example:

{
  "blockPatterns": [
    "rm -rf /",
    "--no-preserve-root",
    "mkfs"
  ]
}

Hardening Behavior

uzzar applies best-effort immutable flags during install:

  • macOS: chflags uchg
  • Linux: chattr +i

And removes flags during uninstall:

  • macOS: chflags nouchg
  • Linux: chattr -i

If immutable tooling is unavailable, installation still proceeds.

Recovery Scenarios

Command blocked unexpectedly

Check:

cat /usr/local/uzzar/policy.json

Recovery:

  1. Remove or adjust the matching blockPatterns entry.
  2. Re-run the command.

Missing guard runtime or policy file

Symptoms:

  • wrapper prints uzzar guard runtime missing or uzzar policy file missing.

Recovery:

  1. Reinstall:
    sudo uzzar uninstall
    sudo uzzar install

Partial uninstall due missing backup

Symptoms:

  • uninstall logs Skipping restore, backup missing: ...

Recovery:

  1. Restore that binary manually from OS package manager or trusted backup.
  2. Re-run sudo uzzar uninstall.

Development

Build:

pnpm run build

Test:

pnpm run test

Tests use a fake system root and do not modify host /bin paths.

Optional Shell Hook

For shell-level patterns that are not binary invocations, add a shell hook:

preexec() {
  case "$1" in
    ":(){ :|:& };:"|\
    *"> /etc/passwd"*|\
    *"> ~/.ssh/authorized_keys"*)
      echo "uzzar blocked this"
      return 1
    ;;
  esac
}

Enterprise Path

For non-bypassable enforcement on managed fleets:

  • macOS: EndpointSecurity system extension (ES_EVENT_TYPE_AUTH_EXEC)
  • Linux: SELinux, AppArmor, or eBPF-based exec policy

Detailed blocked-command examples:

  • docs/commands/README.md