Skip to content

[Plugin] Smartcard plugin — Workstation Agent #41

Description

@maxzaikin

Summary

Implement VaultFlower.Agent.Workstation Windows Service.
Reads Mifare NFC card UID from USB NFC reader and
exposes it via localhost WebSocket to the browser.

Context

See Plugin-Smartcard — Workstation Agent section and
Architecture-Container-Architecture

Acceptance Criteria

  • .NET 9 Windows Service project
  • NFC reader access via PC/SC (WinSCard API)
  • Polls for card presence every 200ms
  • WebSocket server on localhost:7777 (loopback ONLY — never 0.0.0.0)
  • CORS: AllowedOrigins = ["https://vfw-core.contoso.com"] only
  • On card detected: sends JSON { "uid": "A1B2C3D4", "card_type": "MIFARE_DESFIRE" }
  • On card removed: sends JSON { "uid": null }
  • No persistence — UID only in memory, never written to disk or log
  • Service auto-starts on Windows boot
  • Works without admin rights after initial installation
  • Installer (MSI or Setup.exe) for GPO deployment
  • Supports: ACS ACR122U, ACS ACR1252U, HID OMNIKEY 5022
  • Unit tests for WebSocket message format

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    Status
    Ready

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions