A small local bridge that lets the ELAI ledger console and verifythecard.com talk to your USB chip card reader on desktop. Required because modern operating systems claim chip readers exclusively for the system smart-card framework, blocking browser-based WebUSB access. The helper uses the same framework as an API instead of fighting it.
Full disclosure โ here's exactly what the installer does to your Mac:
~/Library/Application Support/ELAI/chip-helper.py (~18 KB, plain text โ read it)~/Library/LaunchAgents/com.americafirst4us.elai-chip-helper.plist โ registers the helper as a background service that starts at login~/Library/Logs/elai-chip-helper.{log,err} โ for debuggingNetwork: The helper opens localhost:8001 โ only reachable from your own machine. It accepts cross-origin requests from americafirst4us.com, verifythecard.com, idregulators.com, 4pdfs.com, and localhost only. No outbound network calls. No telemetry.
Permissions: User-level only. No sudo, no system-wide changes, no kernel extensions. Removal is one command: ./uninstall-mac.sh.
Honest threat model. If you're going to install something on your machine, you deserve to know exactly what its attack surface looks like.
โ What the chip and the helper together refuse to give up โ even if you ask nicely:
INTERNAL AUTHENTICATE doesn't return account data.SELECT or AUTH responses.INTERNAL AUTHENTICATE outside a full payment transaction (you'll see 6985 or 6D00 โ that's a polite refusal, by design).lsof -i if you want to verify.โ What a successful attacker on your machine could observe:
๐ก How we defend against drive-by attacks:
127.0.0.1:8001) โ no remote attacker can reach it. Your home network can't either.americafirst4us.com, verifythecard.com, idregulators.com, 4pdfs.com, and localhost can read responses. A random site that loads in another tab gets blocked.๐ง Known limits โ what we'll harden before broad release:
/chip-event.Bottom line: for current personal + early-user use, the surface is small and your chip itself protects what actually matters. For broader public deployment, the browser extension is the right architecture.
The helper is a Python script. Easiest path on macOS uses Homebrew:
brew install python python3 -m pip install --break-system-packages pyscard
If you don't have Homebrew: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
In Terminal, navigate to where you saved the files and run:
chmod +x install-mac.sh ./install-mac.sh
The installer detects your Python, copies the helper to ~/Library/Application Support/ELAI/, registers it as a macOS LaunchAgent, and starts it. From this point on, the helper auto-starts every time you log in and auto-restarts if it crashes. No terminal window required.
In any terminal:
curl http://localhost:8001/health
You should see JSON like {"ok":true,"reader":"...","atr":"..."}. With a chip card inserted, card_inserted will be true.
Now any ELAI ecosystem surface โ the ledger console, chip-bind.html, future browser extensions โ can enroll chip cards on your Mac.
./uninstall-mac.sh
Unloads the LaunchAgent, removes the plist, optionally removes the installed script. Log files in ~/Library/Logs/elai-chip-helper.{log,err} are left alone.