Push Tracker
ria-ran--sim-drop/portal/index.html
A ashkan@beigi.net 8672b0de6b Add Phase-1 eSIM provisioning implementation
Full working closed-loop eSIM provisioning stack (spec in claude.md / plan/):
Flask API, SQLite subscriber store, credential/profile generator, Open5GS
and free5gc core adapters, captive portal, operational scripts, systemd
units, network configs, and a 44-test suite.

Profile generation currently returns a mock JSON profile; real SGP.22
generation via pySim is the planned Phase-2 upgrade.

Fixes two bugs found while getting the suite green:
- generate_imsi hardcoded a 10-digit MSIN, producing 16-digit IMSIs for a
  3-digit MNC; MSIN length is now 15 - len(mcc) - len(mnc).
- check_rate_limit compared timestamps as strings across mismatched formats
  (SQLite CURRENT_TIMESTAMP vs Python isoformat); both sides now normalized
  via SQLite datetime() so the window check is chronologically correct.

Add .gitignore for venv, caches, runtime config.yaml, and databases.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-01 05:56:31 +00:00

59 lines
1.8 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Emergency 5G — eSIM Activation</title>
<link rel="stylesheet" href="/css/style.css">
</head>
<body>
<div class="card">
<div class="logo">📡</div>
<h1>Emergency 5G Network</h1>
<p class="subtitle">Activate your free eSIM to connect to the 5G network</p>
<!-- Idle state -->
<div id="state-idle">
<button id="btn-activate" class="btn-primary">Activate eSIM</button>
<p class="hint">Tap to generate your personal eSIM profile</p>
</div>
<!-- Loading state -->
<div id="state-loading" hidden>
<div class="spinner"></div>
<p>Generating your eSIM profile&hellip;</p>
</div>
<!-- Success state -->
<div id="state-success" hidden>
<div class="icon-success"></div>
<h2>eSIM Ready!</h2>
<p>Your profile has been generated successfully.</p>
<a id="download-link" class="btn-primary" download="esim-profile.bin">
Download Profile
</a>
<div class="instructions">
<h3>Next Steps</h3>
<ol>
<li>Tap <strong>Download Profile</strong> above</li>
<li>Go to <strong>Settings → Mobile Data → Add eSIM</strong></li>
<li>Choose <em>Import from file</em> and select the downloaded file</li>
<li>Disconnect from this WiFi</li>
<li>Your device will connect to 5G automatically</li>
</ol>
</div>
</div>
<!-- Error state -->
<div id="state-error" hidden>
<div class="icon-error"></div>
<h2>Activation Failed</h2>
<p id="error-message">An error occurred. Please try again.</p>
<button id="btn-retry" class="btn-secondary">Try Again</button>
</div>
</div>
<script src="/js/script.js"></script>
</body>
</html>