Skip to content

Add SwiftUI macOS app and improve report handling#4

Merged
linyows merged 4 commits into
mainfrom
swiftui-integration
Apr 12, 2026
Merged

Add SwiftUI macOS app and improve report handling#4
linyows merged 4 commits into
mainfrom
swiftui-integration

Conversation

@linyows

@linyows linyows commented Apr 12, 2026

Copy link
Copy Markdown
Owner

Summary

  • Unify IMAP search: Merge separate DMARC/TLS-RPT searches into single query, classify by parse result. Fixes misclassification of TLS-RPT emails as DMARC
  • Hash-based filenames: Replace slug-based filenames with Fnv1a_64 hash for consistent naming across report types
  • Unify date format: Convert TLS-RPT ISO 8601 datetime to same YYYY-MM-DD HH:MM format as DMARC
  • CLI improvements: Hash ID in list output, reordered columns, --type filter, show supports hash ID lookup
  • SwiftUI macOS app: Native three-column app (Ghostty architecture) with XCFramework integration, badge labels, policy color coding, search/filter

Test plan

  • reports fetch --account <name> correctly classifies DMARC and TLS-RPT
  • reports list shows unified date format and hash IDs
  • reports list --type dmarc / --type tlsrpt filters correctly
  • reports show <hash-id> works
  • cd macos && ./build.sh && make open builds and opens Xcode project
  • macOS app displays list and detail views for both report types

🤖 Generated with Claude Code

linyows and others added 4 commits April 12, 2026 09:27
Merge separate DMARC and TLS-RPT IMAP searches into a single query
(OR SUBJECT "Report Domain:" SUBJECT "TLS-RPT") and determine
report type by attempting JSON parse (TLS-RPT) before XML parse
(DMARC). This fixes misclassification where TLS-RPT emails matched
the DMARC subject search.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace slug-based filenames ({slug}_{report_id}.json) with
Fnv1a_64 hash-based filenames ({16-char hex}.json) for consistent
naming across DMARC and TLS-RPT reports. Convert TLS-RPT ISO 8601
datetime to the same "YYYY-MM-DD HH:MM" format used by DMARC.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add bundle_compiler_rt = true to the static library target so that
128-bit float builtins are included when linking from Xcode.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add native macOS app under macos/ following the Ghostty architecture
(Zig headless core + SwiftUI GUI). The app uses XCFramework built
from libreports-core.a with a C modulemap for Swift interop.

Features:
- Three-column NavigationSplitView (sidebar/list/detail)
- DMARC detail with records table matching CLI show output
- TLS-RPT detail with session stats, progress bar, failure table
- Badge labels for account, type, domain, and policy columns
- Policy color coding (green=safe to gray=unsafe)
- Search, filter by type, and fetch from menu/toolbar

Build: macos/build.sh generates XCFramework and Xcode project
via xcodegen.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@linyows linyows merged commit 69a10a7 into main Apr 12, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant