Storing Credentials Securely: AES-256-GCM and JWT

Part of the PurelyManage series. PurelyManage handles two categories of sensitive data: IMAP passwords submitted by users during migration, and the session tokens that keep sysadmins logged in. Neither can be stored carelessly. This post covers how both are handled and why each design decision was made the way it was. Encrypting IMAP Credentials at Rest The problem with storing passwords When a user submits IMAP credentials for a migration job, the backend needs to hold onto those credentials until the job actually runs, which might be minutes or hours later depending on the queue. They have to live in the database. The question is in what form. ...

December 3, 2025 · 7 min · 1313 words · Sagar Nayak

PurelyManage: Open-Source Admin Panel for PurelyMail

What PurelyManage is an open-source, self-hosted web UI for PurelyMail. PurelyMail is a paid email hosting service. It handles email well, but its account dashboard is minimal. If you are managing more than a handful of users or domains, you are either writing curl commands against their API or clicking through a basic web interface one action at a time. PurelyManage wraps that API and adds what is missing: a proper admin panel. ...

November 27, 2025 · 5 min · 971 words · Sagar Nayak

Telegram Attendance Tracker with n8n and Google Sheets

What An attendance tracking system where team members send “IN” or “OUT” to a Telegram group. An n8n workflow processes each message, validates the state, logs it to Google Sheets, and replies with a confirmation. No manual work involved. Components: Telegram bot for message interface n8n workflow for automation logic Google Sheets for data storage and calculations OpenAI GPT-4o-mini (optional) for intelligent message filtering Real scenario: Your team works remotely or in office. Each person sends “IN” when they start work, “OUT” when they finish. The system automatically tracks hours, prevents errors (like double check-ins), and maintains a permanent record in Google Sheets. ...

November 23, 2025 · 13 min · 2698 words · Sagar Nayak

ESP32 Development Setup on Ubuntu

What Install ESP-IDF (Espressif IoT Development Framework) on Ubuntu and run a hello world example on ESP32. Why Official SDK: ESP-IDF is Espressif’s native framework with full hardware support. No Arduino overhead: Direct hardware access, smaller binaries, complete control. Production-ready: Same toolchain used in commercial ESP32 development. How System Requirements Ubuntu/Debian-based Linux Python 3.6 or newer At least 4GB free disk space USB port for ESP32 Video Tutorial ESP32 Setup on Linux: https://www.youtube.com/watch?v=Jt6ZDct4bZk ...

November 22, 2025 · 4 min · 846 words · Sagar Nayak

ESP32 WiFi Ping Server for On-Prem Power Monitoring

What A minimal ESP32 web server that responds with OK when pinged. Used to detect on-prem power/network status in cloud-failover architectures. The typical setup: an on-prem server with a cloud standby. A Lambda or cron job pings the ESP32 every 30 seconds. Three consecutive failures trigger failover. When it responds again, on-prem is back. The server runs on the ESP32 over WiFi using ESP-IDF’s HTTP server component on port 80. If ESP-IDF is not yet installed on your machine, start with ESP32 Development Setup on Ubuntu. ...

November 22, 2025 · 7 min · 1282 words · Sagar Nayak