mirror of
https://github.com/morluto/rea.git
synced 2026-11-05 06:45:22 +00:00
[GH-ISSUE #4852] [Bug] XML plist decoder reports Apple-rejected integer, real, date and boolean text as observed values #3017
Closed
opened 2026-10-31 00:34:54 +00:00 by bsakaguchi
·
4 comments
No Branch/Tag specified
main
codex/procedure-reference-stacked
release-please--branches--main--components--rea-agents
release-please--branches--main--components--rea-agents--release-notes
codex/kuna-independent-retry
codex/byte-search-overlay-coverage
codex/open-failure-target-receipt
codex/kuna-xref-evidence
codex/ghidra-ambiguous-procedure-recovery
codex/function-source-bundle
codex/trace-function-integration-prototype
codex/snapshot-source-closure
codex/recorded-evidence-array-pages
codex/evidence-recovery-redesign
codex/trace-feature-address-scope
codex/call-discovery-scope
codex/ghidra-literal-candidate-evidence
codex/decompile-directory-independent-retry
codex/retry-provenance-base
codex/value-flow-capability-experiment
codex/ghidra-containing-instruction
cursor/readme-discord-button-ef9f
dependabot/github_actions/actions/setup-node-7.1.0
dependabot/github_actions/actions/upload-artifact-7.0.2
dependabot/npm_and_yarn/npm-minor-and-patch-d8d97ce6df
codex/kuna-1989
fix/8559-native-ui-fixture-ownership
fix/8555-go-verifier-mcp-ownership
codex/provider-capability-recovery
fix/8642-rizin-target-stdin
codex/ghidra-memory-effect-scope
codex/ghidra-annotation-entry-selector
codex/ghidra-readonly-recovery
codex/ghidra-regex-verifier-recovery
codex/evidence-discovery-view-guidance
fix/8545-bulk-append-overflow
fix/8428-navigation-refusal-alternatives
codex/address-context-recovery
codex/matching-member-limitations
codex/unknown-scope-contract
codex/evidence-view-guidance
feat/8373-native-trace-views
codex/ghidra-snapshot-verifier-binding
codex/elf-export-visibility
codex/evidence-view-recovery
codex/native-reference-cli-help
codex/provider-candidate-observation-scope
codex/kuna-session-verification
codex/ghidra-switch-lifetime-guidance
codex/pseudocode-paging-discovery
codex/clarify-evidence-view-support
codex/kuna-xrefs-selector-recovery
codex/context-capacity-recovery
codex/evidence-closure-large-links
codex/same-function-evidence-identity
codex/ghidra-verifier-inspected-jdk
codex/audit-guided-workflows
codex/crash-prompt-retained-dossiers
codex/analysis-view-error-recovery
codex/kuna-verifier-target-selection
codex/ghidra-selected-project-call-coverage
codex/docs-native-analysis-scope
codex/ghidra-java-socket-boundary
codex/ghidra-retained-snapshot-verifier
codex/ghidra-search-inventory-facts
fix/8284-zero-argument-parameter-bindings
fix/8198-ui-action-handler-offset
fix/8257-elf-entry-label-identity
fix/8304-deferred-output-schema-projection
fix/8277-call-path-computed-target-uncertainty
fix/pr-8089-conflicts
fix/ci-static-duplicate-export
dependabot/npm_and_yarn/lint-staged-17.6.0
dependabot/github_actions/actions/download-artifact-8.0.2
dependabot/npm_and_yarn/write-file-atomic-8.0.0
dependabot/npm_and_yarn/canonicalize-5.1.0
dependabot/github_actions/actions/cache/restore-6.1.0
dependabot/npm_and_yarn/toon-format/toon-4.4.0
dependabot/github_actions/actions/deploy-pages-5.0.1
codex/review-fixes-pr-2403
codex/review-fixes-pr-2400
codex/process-terminal-width
codex/test-brittleness-cleanup
verify/7167-browser-connect-macos
fix/7167-browser-connect
feat/native-matching-allowance-setting
feat/browser-scenario-dry-run
test/managed-caller-parameters-20261024
codex/parser-fortythird-boundaries
fix/6926-pinvoke-platform-decorations-20261023
fix/6889-har-body-encoding-20261023
fix/6888-sqlite-schema-budget-20261023
fix/dependency-security-gates-6708
cursor/evidence-overwrite-rebase-b4ac
feat/4057-verify-native-exports
fix/windows-acl-observer-overhead-20261022
cursor/erlang-beam-restack-4476
cursor/pe-certificate-review-bf32
fix/6116-javascript-application-fs-errors
fix/6061-unmapped-runtime-script-unknown
feat/browser-scenario-summary
fix/pe-certificates
codex/verify-3407
cursor/rebase-5699
cursor/rebase-5352
cursor/rebase-5600
cursor/fix-cli-schema-omission-10a8
codex/audit-hopper-shutdown-reasons-20261021
fix/demangle-swift-omitted-record
fix/nib-boolean-value-types
cursor/cancellation-partial-observation-a5ac
fix/ib-object-limit-reasons
fix/electron-fuse-limit-advice
fix/kuna-doctor-dangling-cache
fix/fixed-budget-refusal-advice
fix/js-ipc-listener-dedup
fix/js-return-member-provenance
fix/dmg-integrity-retry-advice
fix/ida-doctor-readiness
fix/kuna-version-probe-output-drain
fix/legacy-swift-runtime-name-matching
fix/dylib-lazy-load-commands
fix/browser-scenario-startup-cancel
fix/swift-nested-punycode-classification
fix/compare-unselected-scopes
fix/objc-method-budget-coverage
fix/dmg-mounted-root-observations
audit/ci-tests-20261019-round2
release/6.7.0
fix/wabt-cleanup-retry-resolution
fix/electron-fuse-elf-pe-architecture
fix/native-plist-descriptor-ownership
fix/kuna-caller-cleanup-ownership
experiment/atomic-codemode-20261016
review/first-contributor-3776
fix/call-resolution-full-read-cycles
fix/member-mutation-selection-repeat
experiment/atomic-re-tools-20261015
perf/member-mutation-lazy-origins
perf/static-network-mutation-index
fix/hopper-startup-lifecycle
audit/3050-windows-proof-20261015
feat/windows-window-capture-2183
audit/3049-windows-proof-20261015
audit/3735-macos-fixtures-20261015
fix/batch-decompile-null-pseudocode
fix/kuna-inventory-honors-jobs
experiment/browser-codemode-tool-design-20261015
fix/hopper-clean-runtime-argv
codex/review-2049-27f1b367
review-fixes/pr-2787-routing
fix/3360-scoped-this-emitters
fix/3367-replaced-global-effects
fix/3838-compact-any-value-items
test/hopper-download-probe-20261015
codex/windows-runtime-creation-red-green-20261015
codex/windows-readonly-root-red-green-20261015
codex/windows-root-share-red-green-20261015
codex/exp-1685-win-mcp-startup
codex/bug-sweep-20261015
investigate/2190-windows-package-phases
investigate/3543-macos-cli-deadline
perf/3281-reverse-tools-feedback-quality
fix/3406-hopper-doctor-fixture
fix/3341-wrapper-require-test-context
fix/3301-owned-uninstall-fixtures
fix/3164-compiler-input-ownership
fix/pcap-cleanup-stdout-newline-20261014
perf/interface-builder-summary
codex/review-fixes-pr-1977
fix/ghidra-effective-jvm-platform
fix/docs-turkish-rust-link-20261013
fix/main-maintenance-ci-20261010
fix/recover-binary-session-process-effects
codex/review-fixes-pr-2457
codex/ci-required-cancellation-gate
fix/main-format-baseline-20261013
fix/setup-preserve-entry-fields
cursor/restore-main-checks-1ffc
fix/ghidra-bridge-hashmap-import
codex/shared-ci-jadx-json-default-20261013
codex/shared-ci-ghidra-test-groups-20261013
codex/shared-ci-java-fixture-format-20261013
codex/fix-intrinsic-invocation-boundaries
test/release-preflight-reusable-jobs
test/js-parameter-provenance-expectation
fix/linux-hopper-verification-current
test/2419-ghidra-elf-probe-size
followup/pr-1544-native-ida
codex/fold-pr-2230-contribution
docs/readme-responsible-use
fix/issue-2064
fix/issue-2050
fix/issue-2053
fix/issue-1968
fix/issue-1945
experiment/codemode-bridge-20261011
fix/tool-effects-negative-wording-1904-20261012
fix/1842-electron-interop-provenance
feat/recover-javascript-multi-input
refactor/website-i18n-prep
fix/nativeaot-pe-virtual-extent
fix/browser-verifier-ci-hang
fix/pe-resources-input-selection
docs/beginner-friendly-guides
docs/beginner-setup-guide
fix/javascript-analysis-worker-1563
fix/1649-ghidra-duplicate-names
fix/javascript-export-keys-integration-1369
test/maintenance-boundary-contracts-20261011
review/javascript-export-keys-1369
review/process-live-progress-1483
test/javascript-1495-growth-ratio
fix/ci-escape-timing
docs/normalized-terminal-geometry-1450
release/6.3.0
archive/release-6.3.0-pr1381
release/6.2.0
fix/electron-preload-dynamic-override
fix/javascript-self-referential-bundler-edges
release/6.1.0
cursor/grok-client-cherry-pick-0b56
feat/signature-posture
feat/dyld-shared-cache
feat/artifact-integrity-policy
feat/pkg-inventory
release/6.0.0
chore/sync-release-5.0.0
release/5.0.0
cursor/cloud-agent-node-787e
fix/javascript-xhr-open-endpoints
review/pr-711-realpath-fallback-wording
cleanup/replay-confinement
codex/test-suite-performance
codex/issue-foundations
codex/address-open-issues-2026-07-20
agent/javascript-vite-rollup-esbuild-adapters
agent/process-cleanup
agent/triage-integration
agent/unknown-commands-registry
feat/mcp-identity-metadata
morlvps/issue_cleanup
codex/installer-redesign
morl/roadmap-investigation-core
morl/roadmap-investigation-docs
release-please--branches--main--components--rea
rea-agents-6.8.0
rea-agents-6.7.0
rea-agents-6.6.0
experiment/atomic-codemode-wait-runtime-20261016
rea-agents-6.5.0
rea-agents-6.4.0
rea-agents-6.3.0
rea-agents-6.2.0
rea-agents-6.1.0
rea-agents-6.0.0
rea-agents-5.0.0
rea-agents-4.1.0
rea-agents-4.0.1
rea-agents-4.0.0
rea-agents-3.2.1
rea-agents-3.2.0
rea-agents-3.1.0
rea-agents-3.0.0
rea-agents-2.7.0
rea-agents-2.6.0
rea-agents-2.5.1
rea-agents-2.5.0
rea-agents-2.4.0
rea-agents-2.3.0
rea-agents-2.2.0
rea-agents-2.1.0
rea-agents-2.0.0
rea-agents-1.7.0
rea-agents-1.6.0
rea-agents-1.5.0
rea-agents-1.4.0
rea-agents-1.3.0
rea-agents-1.2.0
rea-agents-1.1.0
rea-agents-1.0.0
rea-agents-0.5.0
rea-agents-0.4.0
rea-agents-0.3.0
rea-0.2.1
rea-0.2.0
Labels
Clear labels
area: bridge
area: bridge
area: build
area: build
area: build
area: cli
area: domain
area: evidence
area: mcp
area: native
area: providers
area: runtime
area: server
area: setup
area: tests
bug
design
documentation
enhancement
enhancement
enhancement
experiment
help wanted
i18n
invalid
P0: critical
P1: high
P2: medium
P2: medium
P2: medium
P3: low
performance
provider-request
pull-request
Mirrored from GitHub Pull Request
question
roadmap
triage
No labels
area: bridge
area: bridge
area: build
area: build
area: build
area: cli
area: domain
area: evidence
area: mcp
area: native
area: providers
area: runtime
area: server
area: setup
area: tests
bug
design
documentation
enhancement
enhancement
enhancement
experiment
help wanted
i18n
invalid
P0: critical
P1: high
P2: medium
P2: medium
P2: medium
P3: low
performance
provider-request
pull-request
question
roadmap
triage
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".
No due date set.
Dependencies
No dependencies set.
Reference
morluto/rea#3017
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @apitoagents on GitHub (Oct 17, 2026).
Original GitHub issue: https://github.com/morluto/rea/issues/4852
Before submitting
Area
Evidence, artifacts, or reconstruction
Observed behavior
REA's own XML plist decoder (
parseXmlPropertyList, used byinspect-keyed-archive, Interface Builder documents and the non-macOS plist paths) accepts<integer>,<real>,<date>and<true>text that Apple's property-list parser rejects, and returns a value withstatus: observedand Evidence confidenceobserved. In most cases no limitation discloses that the text was not a valid literal. One case also depends on the host time zone.Each row is one keyed archive whose
$objects[1]holds the element shown.plutilis/usr/bin/plutil -p/-linton the same file; REA is the built CLIinspect-keyed-archive <file> --json --full-outputon main742b6f587.$objects[1]observed)<integer> 42 </integer><integer>42<integer>42abc</integer><integer>42<integer>4.2</integer>4<integer>1e3</integer><integer>1<integer>4<!-- c -->2</integer>4<integer><![CDATA[42]]></integer><integer>42<real> 1.5 </real>1.5<real>1.5abc</real>1.5<real>1,5</real>1<real>0x1p3</real>0<date>2026-10-17T12:00:00+02:00</date><date>2026-10-17T10:00:00.000Z<date>2026-10-17T12:00:00.5Z</date><date>2026-10-17T12:00:00.500Z<date>2026-10-17T12:00:00</date><date>2026-10-17T10:00:00.000Zon a UTC+2 host<true>x</true><true>trueControls on the same path:
<integer>42</integer>,<integer>+42</integer>,<integer>042</integer>,<real>.5</real>,<real>5.</real>,<real>1e3</real>,<real>1<![CDATA[.5]]></real>and<date>…Z</date>agree with plutil.<integer></integer>and<real></real>are refused by both (REA with a genericartifact_operation_failed/execution_failurerather than a typed format error).Reproduction
Executed on macOS 13.2.1 arm64, Node 24.15.0, source build of main
742b6f587, host time zone UTC+2. For one row:/usr/bin/plutil -lint real_comma.plist→Encountered misformatted real on line 3.node scripts/rea.mjs inspect-keyed-archive /absolute/path/real_comma.plist --json --full-output→ exit 0,objects[1]={"kind":"scalar","status":"observed","value":1},confidence: "observed",limitationscontain only the three standing keyed-archive notes.Each row in the table was executed once the same way; the controls were executed once each.
Expected behavior
A literal Apple's parser refuses should not become an observed value. Either refuse the document with a typed format error naming the element and text, as the
<integer></integer>case already does in spirit, or return an explicit unknown with a limitation naming the invalid literal. Which of the two fits the Evidence contract is a maintainer decision; what should not happen isstatus: observedwith the wrong number, a time-zone-dependent date, or no disclosure.Decoding should also not depend on the host time zone:
<date>without a zone designator is invalid for Apple, and REA currently returns a different instant on each machine.Impact and scope
Affects every consumer of
parseXmlPropertyList: keyed archives, Interface Builder documents, andinspect_pliston Linux and Windows (on macOSinspect_plistgoes through plutil, which refuses these files, so the macOS native path is not affected). Hand-edited or generated plists are where such text appears; frequency in shipped applications is unknown and was not measured. Binary plists are unaffected.REA version
source commit
742b6f587(main), package 6.5.0Runtime and platform
Node 24.15.0; macOS 13.2.1 arm64; plutil from that macOS as the control
Target and artifact context
Self-authored one-value XML keyed archives; no third-party target
Interface
CLI
Earliest failure stage
Request parsing or validation
Relevant output or evidence
inspect-keyed-archiveon the<real>1,5</real>fixture (trimmed):confidence: "observed", no limitation beyond the standing keyed-archive notes.Typed outcome or recovery expected
A typed format/input failure for the document, or an explicit unknown scalar with a limitation naming the element and literal. Not an observed value.
Analysis or suspected cause
Source-derived,
src/domain/propertyListXml.ts:integer: whenparsePlistIntegerLiteralreturnsundefined, the decoder falls back toNumber.parseInt(first.nodeValue, 10)and only callsnumbers.markIncomplete().parseIntreads a leading decimal prefix, so42abc,4.2,1e3and4<!-- -->2decode to a number, and the only disclosure is the integer-precision limitation, which describes a different problem.<integer> 42 </integer>passesparsePlistIntegerLiteralafter trimming, so nothing is marked.real:Number.parseFloat(literal.text)accepts leading whitespace and stops at the first non-numeric character, so1,5→1,1.5abc→1.5,0x1p3→0, andliteral.completeis true, sonumbers.real(value)records them as good reals.date:new Date(string)accepts ISO 8601 offsets, fractional seconds and zone-less text, and treats zone-less text as local time.true/false: the element content is not checked.A strict literal grammar at this one owner (sign + digits or
0xhex for integers, asparsePlistIntegerLiteralalready defines; a decimal/exponent grammar for reals;YYYY-MM-DDTHH:MM:SSZfor dates; empty content for booleans) would make the decoder agree with the native parser. I can prepare a PR once the maintainers choose between refusal and explicit unknown.Additional context
Found while cross-checking REA's decoder against plutil on a set of 50 edge-case plists; the other rows agreed. Related but distinct: #4714 (malformed XML admission) and #4849 (lost plutil diagnostic on macOS).
@xu91102 commented on GitHub (Oct 17, 2026):
Independently reproduced through the built public CLI on main
3460ceac3f5dc93c767b1e7c39a511f026b41baa, Node 24.18.0, macOS arm64, using self-authored keyed archives./usr/bin/plutil -lintrejects each of these five inputs, whileinspect-keyed-archive --json --full-outputexits 0 and reports the scalar asobserved, with Evidence confidenceobserved:<integer> 42 </integer>and<integer>42abc</integer>become42.<real>1,5</real>becomes1.<date>2026-10-17T12:00:00+02:00</date>becomes a UTC timestamp.<true>x</true>becomestrue.Four positive controls (plain integer, plain real, a real split across text and CDATA, and a UTC date) succeed in both tools. All nine input hashes remain unchanged. These are our own executions, not a replay of another contributor's results.
The first incorrect interpretation is in the shared XML scalar decoder: prefix numeric parsing, permissive JavaScript date parsing, and ignored boolean content. I am preparing a focused admission fix there, using the existing format-failure path. Native controls also confirm that non-finite reals, short/extended years, and real CDATA need to retain their supported handling. No Windows/Linux or other contributor's branch execution is claimed.
Compatibility note after checking the owning contract: current
docs/native-investigation.mdexplicitly says that mixed XML numeric content and unclassified integer text retain decoded values with a precision limitation. That existing fallback policy conflicts with making all such inputs format failures. No production code has been changed, and I am not claiming a completed fix or submitting a contract-changing patch. The reproduction and native controls above remain valid.@shivsingh78 commented on GitHub (Oct 17, 2026):
I've reproduced the issue and have a local patch with strict scalar validation and regression tests. The focused suite passes, but the change makes malformed integer literals and mixed numeric markup fail where docs/native-investigation.md currently specifies retaining decoded values with a precision limitation.
Before submitting a PR, could a maintainer confirm whether this issue should change that documented contract to reject malformed scalar content, or preserve the existing fallback behavior and report an explicit unknown/limitation instead?
I have not committed or opened a PR because this decision affects the decoder's existing behavior and compatibility contract.
@XinwangTao commented on GitHub (Oct 18, 2026):
确认这是与 #4714(畸形 XML)不同的一类问题:本报告针对 well-formed 但 Apple 解析器拒绝的 scalar 文本,REA 自带的 XML plist 解码器却把它们当作 observed values 输出。看到 #4849 及后续 fix(plist) 系列提交已按"保留 observed 非有限 real 拼写 / 让 XML 数值未知化"的方向处理,方向合理——解析器应当反映 Apple plutil 的判定边界,而不是把非法文本包装成合法值。建议为这些被 Apple 拒绝的 integer/real/date/boolean 文本各补一个回归测试,防止将来解码器放宽后重新吞掉判定。
@morluto commented on GitHub (Oct 18, 2026):
Fixed in 3537e58c1.
The root cause was permissive downstream JavaScript interpretation: numeric prefixes, string-date parsing and ignored boolean content turned invalid literals into apparent values. The shared XML owner now interprets complete original scalar spans. Malformed or unrepresentable scalars retain their element, exact content and failure reason in
$plist_type: "unknown"wrappers, with counted limitations. The surrounding archive remains useful. Unknown numerics never enter the number facts, so unrelated unsafe integers keep their exact decimal identity. Runtime wrapper identity keeps lookalike user dictionaries ordinary.This replaces the old partial-number fallback and XML
real/value:nullunknown representation; the commit marks that compatibility change as breaking and updates the documented contract. Real references and CDATA remain supported; integer/date parsing uses raw spelling. Date fields are parsed in UTC. Unsupported calendar overflow remains unknown rather than emulating CoreFoundation normalization. Object status still describes observation of the serialized slot; an unknown wrapper does not assert an observed scalar value.Validation executed on macOS/Node 24.18:
1,5became1. The fix's expanded public archive checks 20 invalid scalars, valid controls, both host time zones, CLI/MCP agreement, exact unsafe-integer recovery and unchanged original-byte digests.plutilwhitespace controls, plus independent scalar controls; actual macOS plist XML/binary conversion is covered in the 60 compiled tests. Full static/architecture checks, check:fast and docs checks passed. Two independent design/consumer reviews caught whitespace and ownership details before publication.External research: DeepWiki, pinned Apple CF source, and Context7's xmldom locator/normalization documentation checked against installed 0.9.12. Native controls take precedence where older CF source differs (notably U+202F).
Tiny completed CLI costs: three calls per variant/task, separate first process and two alternating repeated processes, no true cold-cache claim. Repeated medians for a canonical task: 597→597 estimated cl100k output tokens, 0.447→0.441 s elapsed, 0.655→0.647 s CPU, 360→354 MB sampled peak process-family RSS. Malformed-real task: 596→704 output tokens, 0.435→0.439 s elapsed, 0.672→0.653 s CPU, 367→359 MB sampled RSS. These are small, noisy controls, not a speedup claim; whole-agent/catalog/request/MCP/large-input costs are unmeasured. An earlier exploratory round overlapped validation and is excluded from these medians.
No Linux/Windows or deep-provider runtime qualification, and no full CoreFoundation parity claim. The broader parser/lifecycle audit remains open.