← Back to Skills Marketplace
deadlysilent

Codex Auth

by DeadlySilent · GitHub ↗ · v1.0.6 · MIT-0
cross-platform ✓ Security Clean
344
Downloads
0
Stars
0
Active Installs
7
Versions
Install in OpenClaw
/install codex-auth
Description
DEPRECATED shim skill for /codex_auth. Use codex-profiler instead; codex-auth is no longer the maintained path.
README (SKILL.md)

⚠️ Deprecated: codex-auth is no longer maintained as a standalone skill. Use codex-profiler for all ongoing /codex_auth and /codex_usage operations.

Run scripts/codex_auth.py to generate a login URL and apply callback URL tokens to auth-profiles.json.

Safe defaults

  • Treat callback URLs/tokens as sensitive and never echo full values.
  • Use queued apply flow for controlled restart behavior.
  • See RISK.md for allowed/denied operation boundaries.

Commands

  • /codex_auth → selector (discovered profiles)
  • /codex_auth \x3Cprofile>
  • /codex_auth finish \x3Cprofile> \x3Ccallback_url>

Interaction adapter

  • If inline buttons are supported: show selector buttons.
  • If inline buttons are not supported: send text fallback (default | \x3Cprofile>).
  • Callback message handling must never echo full callback URLs (treat as sensitive).
  • Use callback_data namespace prefix codex_auth_* to avoid collisions.

How to run

Start flow:

python3 skills/codex-auth/scripts/codex_auth.py start --profile default

Finish flow (after browser redirect URL is pasted):

python3 skills/codex-auth/scripts/codex_auth.py finish --profile default --callback-url "http://localhost:1455/auth/callback?code=...&state=..."

Queue safe apply (stops/restarts gateway in background):

python3 skills/codex-auth/scripts/codex_auth.py finish --profile default --callback-url "http://localhost:1455/auth/callback?code=...&state=..." --queue-apply
python3 skills/codex-auth/scripts/codex_auth.py status

Safety posture

  • No remote shell execution (curl|bash, wget|sh) is allowed by this skill.
  • No sudo/SSH/system package mutation is performed by this skill.
  • OAuth callback URLs are sensitive: never echo full callback URLs or tokens in chat output.
  • Writes are limited to auth profile state files with lock-based coordination.

Notes

  • Uses the same OpenAI Codex OAuth constants/method as OpenClaw onboarding (auth.openai.com + localhost callback).
  • OAuth success here does not guarantee chatgpt.com/backend-api/wham/usage acceptance; usage endpoint may reject token/session format with 401 and should be handled by usage/profiler skills.
  • Endpoint trust boundary: OpenAI auth hosts + localhost callback flow only; do not send callbacks/tokens to third-party hosts.
  • Writes ~/.openclaw/agents/main/agent/auth-profiles.json with file locking to reduce race risk while gateway is running.
  • Profile IDs map as:
    • default -> openai-codex:default (or first discovered codex profile if default missing)
    • any other selector -> openai-codex:\x3Cselector>
  • Pending auth state is stored in /tmp/openclaw/codex-auth-pending.json.
Usage Guidance
This skill appears to do what it says: run a Codex OAuth flow, store the resulting tokens in your OpenClaw auth profiles, and (optionally) stop/start the local gateway to apply changes. Before running it: - Prefer the maintained alternative: the SKILL.md itself says use 'codex-profiler' instead; prefer that if available. - Inspect the included scripts/codex_auth.py yourself (it is bundled) to confirm there are no unexpected network endpoints or logging of tokens. The file is present so you can audit it prior to execution. - Be aware the script will write tokens to ~/.openclaw/.../auth-profiles.json and may modify ~/.openclaw/openclaw.json; it also runs 'openclaw gateway stop/start'. Make backups or test in an environment where restarting the gateway is safe. - Because the agent can invoke skills autonomously by default, consider disabling autonomous invocation for this skill (or require manual invocation) if you do not want the agent to modify config or restart services without explicit consent. - Only use the flow with the documented OpenAI auth endpoints (auth.openai.com). If you see the script or SKILL.md referencing other hosts, do not proceed. - If you have low trust in the skill owner or source provenance, do not run it on production machines.
Capability Analysis
Type: OpenClaw Skill Name: codex-auth Version: 1.0.6 The codex-auth skill is a utility for managing OpenAI Codex OAuth authentication via a PKCE flow. The core logic in scripts/codex_auth.py handles token exchange with official OpenAI endpoints (auth.openai.com), manages local configuration files (~/.openclaw/openclaw.json), and provides a mechanism to restart the OpenClaw gateway to apply new credentials. The skill demonstrates good security practices, including the use of PKCE, state validation, file locking, atomic writes, and automatic backups of configuration files before modification. No evidence of data exfiltration, unauthorized remote execution, or malicious prompt injection was found.
Capability Assessment
Purpose & Capability
The name/description (codex-auth shim) aligns with the included script and SKILL.md: it starts/finishes an OpenAI Codex OAuth flow, exchanges tokens with auth.openai.com, and writes auth profiles. The subprocess calls to 'openclaw gateway stop/start' and updates to ~/.openclaw/openclaw.json and auth-profiles.json are coherent with applying a new auth profile.
Instruction Scope
SKILL.md instructs running the included script to start/finish flows and to queue safe apply. The script reads/writes files under the user's home (~/.openclaw/...) and /tmp, stores pending state, exchanges tokens over the OpenAI OAuth token endpoint, decodes JWTs, and constructs revert commands. These actions are within the stated scope but are privileged (modify agent config and auth files, and restart the gateway). SKILL.md's safety guidance about not echoing callback URLs is respected in intent, but you should verify the script's actual output if you care about secrets not being logged or echoed.
Install Mechanism
No install spec — instruction-only with a bundled script. Nothing is downloaded or installed automatically by the skill, which reduces external install risk. The code will run locally when you execute the script.
Credentials
The skill does not request environment variables or external credentials beyond performing an OAuth flow with hardcoded CLIENT_ID and standard OpenAI auth endpoints. It writes tokens into local auth-profiles.json as expected for an auth helper. No unrelated secrets or service credentials are requested.
Persistence & Privilege
The skill does not force permanent inclusion (always:false). However, the script performs persistent, privileged actions: it writes to ~/.openclaw/openclaw.json and ~/.openclaw/.../auth-profiles.json, creates backups, and executes local commands to stop/start the gateway. Because the skill can be invoked autonomously by the model (default), consider whether you want an agent to be able to run these operations without manual approval.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install codex-auth
  3. After installation, invoke the skill by name or use /codex-auth
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.6
Deprecation notice: standalone codex-auth is deprecated; users should migrate to maintained codex-profiler path.
v1.0.5
Clarify OAuth-vs-usage endpoint behavior: successful OAuth refresh does not guarantee WHAM usage endpoint acceptance; document 401 handling expectations for companion usage/profiler skills.
v1.0.4
Add RISK.md policy + safe-defaults section; clarify endpoint trust boundary and sensitive callback/token handling.
v1.0.3
Doc hardening: explicit safety posture and strict callback/token secrecy guidance.
v1.0.2
Cross-channel UX update: selector fallback guidance, callback namespace guidance, and stricter callback secrecy notes.
v1.0.1
Added SECURITY.md with scope/data/egress/operational safety notes.
v1.0.0
Initial release: profile OAuth start/finish, callback handling, profile declaration sync, auth order updates, and queued safe apply with restart warning/status.
Metadata
Slug codex-auth
Version 1.0.6
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 7
Frequently Asked Questions

What is Codex Auth?

DEPRECATED shim skill for /codex_auth. Use codex-profiler instead; codex-auth is no longer the maintained path. It is an AI Agent Skill for Claude Code / OpenClaw, with 344 downloads so far.

How do I install Codex Auth?

Run "/install codex-auth" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Codex Auth free?

Yes, Codex Auth is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Codex Auth support?

Codex Auth is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Codex Auth?

It is built and maintained by DeadlySilent (@deadlysilent); the current version is v1.0.6.

💬 Comments