๐Ÿ” Cryptographic HMAC-SHA256 Verification

Telegram Authentication Console

Demonstrating the full flow: frontend widget approval, secure HTTPS payload transfer, backend HMAC-SHA256 signature validation, and JWT session issuance.

๐Ÿš€ Official Telegram Widget
@StudyBroTalTech_bot

The official Telegram login button. When authorized on your configured domain (Lovable or localhost), Telegram provides a signed payload.

Loading Telegram Widget...
๐Ÿ’ก Note: For this widget to render on local browsers, your bot's domain in @BotFather must be set to localhost or tested directly from your Lovable deployment.
๐Ÿงช Cryptographic Test Sandbox
Developer Tool

Test the backend verification algorithm instantly. Send genuine signatures or simulate attack vectors to see how the server responds:

โšก Verification Pipeline
Idle
1
Frontend receives signed payload from Telegram
2
POST payload over HTTPS to /api/auth/telegram
3
Backend derives secret key: SHA256(bot_token)
4
Rebuilds sorted key=value\n data-check-string
5
Timing-safe comparison: hmac.compare_digest
6
Replay protection: auth_date freshness check
7
Session issued: Signed JWT Bearer token returned
๐Ÿ‘ค Authenticated Session
Not Logged In

Authenticate via Telegram or click the simulator to establish a secure session.

๐Ÿ” Payload & JWT Inspector
// Awaiting incoming payload...