Skip to content

[Feature] Decode compiled Apple storyboard and nib archives into UI graphs #480

Closed

Description

@morluto

Before submitting

  • I searched the open and closed issues and pull requests for a related proposal.
  • I removed credentials, tokens, private paths, and sensitive target data.

Area

Evidence, artifacts, or reconstruction

Current limitation

REA can inventory Apple application bundles and recover some UI clues from resources, strings, and native class metadata. Compiled UIKit/AppKit storyboard and nib archives remain opaque to the static artifact workflow. On current Apple tooling, ibtool cannot inspect already-compiled nib archives. Without decoding those archives, an analyst can find controller-to-nib mappings and code-populated outlets, but cannot recover the authored view hierarchy, segue connections, constraints, or most directly configured control properties in a systematic, evidence-linked way.

Use cases

  • Reconstruct screen structure and navigation for an application when source XIB/storyboard files are not shipped.
  • Connect view controllers, controls, action selectors, outlets, segue identifiers, and bundled assets to code references.
  • Compare compiled interface resources across application versions.

Current artifact inventory and string/xref operations provide useful resource discovery, but they do not produce an interface-object graph or recover Auto Layout relationships.

Desired outcome and success criteria

Provide a read-only operation that analyzes compiled Apple storyboard/nib resources and returns a bounded, paginated UI graph with Evidence v2 provenance. When recoverable, include:

  • scene/controller identifiers, class/module names, and source nib/storyboard membership;
  • view and control object hierarchy, labels, accessibility values, identifiers, and selected style/state properties;
  • outlet, action, segue, placeholder, and external-object connections with source and destination IDs;
  • Auto Layout constraints, priorities, layout guides, and authored frames where encoded;
  • referenced images, colors, fonts, and other interface resources;
  • archive format/version, decoding coverage, and explicit unsupported or ambiguous nodes.

Success requires deterministic fixture coverage for storyboards and nibs compiled from source fixtures on supported Xcode versions; stable behavior on malformed and partially supported archives; exact totals and truncation metadata; and cross-references from decoded selectors/classes/resources to existing binary Evidence. Unsupported data must remain unknown rather than being rendered as an empty hierarchy.

Authority boundaries and non-goals

  • Static archive decoding only: do not launch the target or instantiate its views.
  • Do not extract or write archive contents implicitly; use the existing explicit artifact extraction boundary when needed.
  • Preserve original artifact hashes, occurrence paths, and provider limitations.
  • Do not promise pixel-perfect runtime rendering from archived constraints alone; trait collections, code-created views, and runtime state may affect the final screen.
  • Do not infer reachability from a storyboard identifier alone.

Alternatives considered

  • strings, Objective-C/Swift metadata, and controller decompilation recover useful names and code behavior but not the complete authored UI graph.
  • ibtool is useful for source interface documents but refuses compiled nib archives.
  • Runtime screenshot capture can show rendered states but does not replace the archive's authored connections or constraints and requires a separately authorized runtime workflow.

Possible direction

Add an Apple interface archive parser to the artifact provider, or a dedicated read-only UI-resource capability. Normalize relationships into the artifact graph and preserve raw archive object IDs and decode provenance so claims can be traced back to the shipped resource.

References

Activity

  1. added
    enhancement
    triage
    on Sep 28, 2026
  2. morluto commented on Oct 2, 2026

    @morluto
    OwnerAuthor

    Additional reverse-engineering evidence may help shape the decoder's supported visual-property output and fixtures. A real bundled Apple app contained 460 compiled .nib archives. A static census recovered 1,615 UIFont records, 1,256 UIColor records, and 33 distinct archived color tuples. Those records exposed useful authored fonts, point sizes, alpha values, and view bounds for screens and reusable controls.

    The same investigation also showed the evidence boundary: archived properties did not establish the final appearance of custom drawRect controls or their pressed/selected states. Those required separate native-code analysis and screenshots. It would be useful for this decoder to return supported authored style values with object-level provenance, while preserving unsupported custom classes and runtime-dependent styling as explicit unknowns. This kind of bundle corpus should be a good coverage fixture for nested archives, repeated reusable controls, and exact truncation accounting.

  3. morluto commented on Oct 8, 2026

    @morluto
    OwnerAuthor

    Verified fixed on main (7a7460f). NibArchive.ts + InterfaceBuilderAnalysis ship storyboard/nib to UI graph decoding with NibArchive.test.ts passing (3/3). Closing per audit.

  4. added
    area: evidence
    on Nov 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: evidenceenhancementtriage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions