Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    User Detection & Session Context Reviewer

    2

    Review macOS admin scripts for reliable current-user detection and safe session-context handling.

    $14.99

    Secure checkout via Stripe

    Money-back guarantee

    Converts to your local currency at checkout

    Security scanned
    User Detection & Session Context Reviewer

    User Detection & Session Context Reviewer

    Example session with this skill installed

    Review this Jamf check-in script that uses $3 to identify the user and tell me if the UI prompt will work reliably during background runs.

    • Read your context and instructions
    • Compiled the user detection

    Context Review

    • Issue: Script uses static Jamf $3 which is empty during check-in policies.
    • Fix: Implement 'stat -f %Su /dev/console' with a loginwindow check.
    • Risk: UI prompt will hang if no user is logged in.
    • Test: Verify behavior during Fast User Switching and Setup Assistant.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Defensive review for macOS current-user logic

    User Detection & Session Context Reviewer reviews Jamf, Kandji, and Iru scripts that need to identify the logged-in user or show a user-facing prompt.

    What it checks

    • Current-user patterns such as stat -f %Su /dev/console, scutil, Jamf $3, and related approaches.
    • Root execution versus user UI context, including launchctl asuser.
    • Loginwindow, logout, setup assistant, Fast User Switching, and stale-user edge cases.
    • Prompt patterns that avoid logs, process listings, and persistent files.
    • Jamf, Kandji, and Iru workflow differences.

    Boundaries

    This is a defensive admin-review skill. Use redacted or synthetic examples. It does not collect, validate, store, transmit, or request real passwords, tokens, recovery keys, or private tenant values.

    Output

    You get a context-readiness verdict, edge-case notes, safer detection and prompt patterns, validation checklist, and open questions for local policy or vendor documentation.

    • Cannot execute or test scripts on live hardware.
    • Reviews logic only; does not verify MDM server-side API permissions.
    • Limited to shell scripts (zsh/bash), not Swift or Objective-C binaries.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    Fresh listing

    Recently published to Agensi

    Money-back guarantee

    Doesn't do what its page promises? You get your money back.

    Trust & safety

    Security scan

    Security scan passed 5 months ago

    Requires

    macOS

    Permissions

    No special permissions declared or detected

    Listed5 months ago
    Updated1 month ago

    What's inside

    Frequently Asked Questions

    It identifies common failures in macOS admin scripts, such as scripts running as root failing to target the active user, or detection logic failing during Fast User Switching or at the login window.

    Yes, it provides platform-specific advice for Jamf (including $3 logic), Kandji, and Iru, ensuring your scripts account for the unique ways these MDM agents execute commands.

    Simply provide the script logic or the specific user-detection command you intend to use; the skill will analyze the block and return a context-readiness verdict and a checklist of edge cases.

    This skill focuses on defensive code review; it does not require access to your MDM environment and should be used with redacted or synthetic scripts to maintain your organization's privacy.

    The skill is designed to catch 'stale-user' errors, such as when /dev/console points to a user who has logged out, or when Setup Assistant is active and no user is logged in yet.

    You receive a comprehensive review including a context-readiness score, safer alternative patterns for shell commands, and specific questions to verify against your local security policy.

    New in Security