VaporWeb certificates should be per-device per-VaporNET

Resolved 💬 2 comments Opened Dec 5, 2025 by connectedway Closed Jan 6, 2026

Summary

Currently, VaporWeb certificates are associated with a user for a VaporNET, not per-device. This causes confusion when a user has multiple devices - all devices share the same certificate, and the certificate common name may reference an old device name.

Current Behavior

  • Backend VaporWebCertificateRequest model tracks: vapornet, requester (user), common_name
  • No device identifier is stored
  • When a user requests a certificate on device "gandalf-20", it may show certificate "gandalf-14" (from an earlier device)
  • All devices for the same user share one certificate per VaporNET

Expected Behavior

  • Each device should have its own certificate per VaporNET
  • If a user has 3 devices and is a member of 2 VaporNETs, they should have 6 certificates total (3 devices × 2 VaporNETs)
  • Certificate common names should match the device that requested them

Technical Changes Required

Backend (CloudHub)

  1. Add device_id field to VaporWebCertificateRequest model
  2. Update SubmitCertificateRequestView to accept and store device ID
  3. Update GetMyCertificatesView to filter by device ID (or return all with device info)
  4. Allow multiple signed certificates per user per VaporNET (one per device)

Frontend (Gridlock App)

  1. Include device ID when submitting certificate requests
  2. Store certificates locally per VaporNET AND per device (or just match by common name)
  3. Only fetch/use certificates that match the current device

Files Involved

Backend:

  • /home/vnc/git/cloudhub/src/cloudhub/models.py - VaporWebCertificateRequest model
  • /home/vnc/git/cloudhub/src/cloudhub/views/vaporweb.py - Certificate request/fetch views

Frontend:

  • /home/vnc/git/gridlock-app/app/src/main/java/com/gridlock/app/service/CertificateManager.kt
  • /home/vnc/git/gridlock-app/app/src/main/java/com/gridlock/app/data/api/VaporWebService.kt

🤖 Generated with Claude Code

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗