# Why We Need to Schedule Post-Quantum Cryptography Around the Weather

> Source: <https://dev.to/skeletorpirate/why-we-need-to-schedule-post-quantum-cryptography-around-the-weather-2lhk>
> Published: 2026-08-27 11:21:01+00:00

The security industry is undergoing one of the largest migrations in history: moving from classical cryptography (RSA/ECC) to **Post-Quantum Cryptography (PQC)**.

While algorithms like **ML-KEM** (FIPS 203) are quantum-resistant, they have a hidden cost: they are **CPU-intensive**. Compared to classical algorithms, key generation, signing, and verification consume significantly more compute.

More compute = more electricity. For bulk operations (signing millions of docs, encrypting petabytes of backups), this spikes carbon footprint — bad for net-zero goals.

What if we schedule these workloads to run **only when the grid is cleanest**?

Enter **Quant Harvest**.

**Quant Harvest** is an open-source Go control plane — a carbon-aware deferred-execution queue for PQC workloads.

Instead of executing heavy crypto immediately, it buffers workloads and monitors grid carbon intensity (gCO2e/kWh). Dirty grid (fossil) → pause queue. Clean grid (solar/wind) → resume and harvest.

```
                  ┌──────────────────────┐
                  │   Workload Enqueued  │
                  └──────────┬───────────┘
                             ▼
                  ┌──────────────────────┐
                  │    Task Buffered     │
                  └──────────┬───────────┘
                             ▼
               No  /───────────────────\
             ┌────/  Grid Clean enough? \
             │    \   (Under threshold) /
             │     \───────────────────/
             ▼               │ Yes
     ┌──────────────┐        ▼
     │ Queue Paused │ ┌──────────────┐
     └──────────────┘ │ Execute Task │
                      └──────────────┘
```

**Try it live:** [https://quant-harvest.onrender.com](https://quant-harvest.onrender.com)

```
curl -X POST https://quant-harvest.onrender.com/api/tasks \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: demo-123" \
  -d '{"name":"pqc-batch-signing","payload":"ml-kem-768"}'

# Watch /api/status — when carbon >200 it defers, when <200 it runs
curl https://quant-harvest.onrender.com/api/status | jq
```

`modernc.org/sqlite`

pure-Go driver) — busy timeouts, atomic claims, idempotency via `Idempotency-Key`

`/metrics`

(`qharvest_task_queue_size`

, `qharvest_carbon_intensity`

) + `/healthz`

`/readyz`

`/`

— real-time grid chart + queue + WAL logs (see live demo)`deploy/`

```
// pqc.go — integration boundary ready for ML-KEM
func EnvelopeIdentifier(data []byte) [32]byte {
    return sha256.Sum256(data) // placeholder for vetted ML-KEM/FIPS203
}
2026/08/15 12:01:45 Q-HARVEST listening on :8080
2026/08/15 12:02:00 scheduler: deferring queue at 270gCO2e/kWh
2026/08/15 12:02:15 scheduler: carbon intensity dropped to 145gCO2e/kWh
2026/08/15 12:02:15 scheduler: executing pqc-bulk-signing
```

Green computing is usually "use less." Quant Harvest is "use **when** clean." Same jobs, shifted to renewable windows — simplest decarbonization win for PQC migration.

Apache-2.0. If you're Go/DevOps/crypto, try the live demo and roast the scheduler logic!
