✓ Verified 💻 Development ✓ Enhanced Data

Totp

TOTP-based OTP verification for sensitive operations (env vars, gateway restarts, backup deletions,

Rating
3.8 (104 reviews)
Downloads
1,627 downloads
Version
1.0.0

Overview

TOTP-based OTP verification for sensitive operations (env vars, gateway restarts, backup deletions, critical config.

Complete Documentation

View Source →

TOTP Verification Skill

Secure OTP verification using TOTP (Time-based One-Time Password) for sensitive operations.

Purpose

Protect access to:

  • .env variables
  • openclaw.json configuration
  • Gateway restarts
  • Backup deletions
  • Critical configuration changes
  • External API key operations

Setup

  • Install dependencies:
bash
npm install
  • Generate secret and QR:
bash
npm run generate
Optionally pass service and account name:
bash
node scripts/generate-secret.js MyService myuser
  • Send the QR image (qr.png) to the user, then delete it immediately:
bash
rm qr.png
  • Set TOTP_SECRET in .env:
env
TOTP_SECRET=YOUR_BASE32_SECRET_HERE
  • Configure Google Authenticator/Authy with the generated secret or QR.

Usage

When a sensitive operation is requested:

  • Agent: "Please provide your OTP"
  • User: Provides 6-digit code from authenticator app
  • Agent: Runs verification:
bash
TOTP_SECRET=$TOTP_SECRET node scripts/verify.js 123456
  • If valid (exit 0): Proceed with operation
  • If invalid (exit 1): Deny access

Files

  • scripts/generate-secret.js - Generate new TOTP secret and QR
  • scripts/verify.js - Verify OTP tokens (window:2 = 1 minute tolerance)
  • SKILL.md - This documentation

Security Notes

  • Window: 2 (1 minute tolerance) for time drift
  • Algorithm: SHA1
  • Digits: 6
  • Period: 30 seconds
  • Secret: Base32 encoded, stored in .env as TOTP_SECRET

Integration

This skill should be integrated into the agent's decision flow when:

  • User requests .env variables
  • User requests openclaw.json contents
  • User requests gateway restart
  • User requests backup deletion
  • Any operation marked as "critical"

Installation

Terminal bash

openclaw install totp
    
Copied!

Tags

#cli_utilities

Quick Info

Category Development
Model Claude 3.5
Complexity One-Click
Author diegofcornejo
Last Updated 3/10/2026
🚀
Optimized for
Claude 3.5
🧠

Ready to Install?

Get started with this skill in seconds

openclaw install totp