Because the API Security Workbench ingests Highly Confidential code, raw HTTP responses (containing PII), and API Keys for active scanning, the application itself must be an impenetrable fortress on the analyst's machine.
If the analyst's laptop is stolen, the SQLite database containing the API mappings and scan results must be useless to an attacker.
- SQLite Encryption: We will use
sqlcipherinstead of standard SQLite in the Rust backend. - The Key:
- The DB is encrypted with an AES-256 key.
- This key is never stored in plain text. It is securely stored in the operating system's native secure enclave using the Rust
keyringcrate:- Windows: Windows Credential Manager.
- macOS: Apple Keychain.
- Linux: Secret Service API / D-Bus.
- Workflow: When the app launches, Rust silently requests the master key from the OS Keychain, unlocks the SQLite DB in memory, and the app functions seamlessly. The user does nothing.
When a user provides a Bearer Token or AWS Key to actively scan an environment:
- Never Store: We do not store active authentication tokens in
sqlcipher. They are ephemeral. - Environment Variables: The user inputs them into a strictly memory-only "Vault" array in the React state.
- Zero-Logging Policy: The Rust scanning engine must be strictly audited to ensure
reqwesterrors or panic logs never write full HTTP headers to a local text file. All custom debug logging will sanitizeAuthorization: Bearer <scrubbed>.
To distribute this professional tool, we need a bulletproof build pipeline. Tauri makes this complex but powerful.
This pipeline triggers when a Git Tag (e.g., v1.0.0) is pushed.
- Matrix Build: Spins up
ubuntu-latest,windows-latest, andmacos-latestsimultaneously. - Setup: Installs Rust
stable, Node.js20.x, and OS-specific dependencies (e.g.,libwebkit2gtk-4.0-devfor Linux). - Lint & Test:
- Frontend:
npm run lint&npm run test(Vitest). - Backend:
cargo clippy -- -D warnings&cargo test.
- Frontend:
- Compile & Package (Tauri Build):
- Windows: Outputs an
.msiinstaller and an.exe. - macOS: Outputs a
.dmgand an.app(M1/ARM64 and Intel builds). - Linux: Outputs an
AppImageand a.deb.
- Windows: Outputs an
- Code Signing:
- Essential for enterprise distribution so Windows Defender/MacOS Gatekeeper don't block the app.
- Inject Apple Developer ID certificates and Windows Authenticode signatures securely via GitHub Secrets.
- Publish: Automatically creates a GitHub Release and attaches all binaries.