https://bugs.documentfoundation.org/show_bug.cgi?id=174182
--- Comment #4 from Morten B <[email protected]> --- (Comment 3 above repeats the text of attachment 209582 by mistake; the intended summary follows.) Additional reproduction: fresh installs, ordinary Writer use, no extensions (26.8.1.1, macOS 26.7.1, Apple Silicon) I repeated the observation in a controlled way on a MacBook Air M2 running macOS 26.7.1 (25G241), in three newly created standard user accounts. None of the accounts had any additional extension installed up to and including the step where the signature broke (S2). An extract of the pinned raw measurements is attached; the full snapshots can be provided on request. Setup (identical in all three accounts): - LibreOffice_26.8.1.1_MacOS_aarch64.dmg, 298845477 bytes, SHA-256 ca074e0b13571efb30a31fc531c5f95e997030637325e5d5de92d67aefdf0dfc (same as the mirrorlist hash). - LibreOffice.app copied from the mounted DMG to ~/Applications of the account (owned by that user), fresh user profile, no language packs, UI language English (default). - Before and after each step, a snapshot of the whole bundle (paths, sizes, SHA-256 of every file, symlink targets) and `codesign --verify --deep --strict` and `spctl --assess --type execute -vv`. LibreOffice was quit (Cmd+Q) and confirmed not running before every snapshot. Observed (all three accounts unless stated): 1. After copying, before first launch (S0): codesign rc 0; spctl "accepted", "source=Notarized Developer ID", "origin=Developer ID Application: The Document Foundation (7P5S3ZLCN7)". The bundle was identical in all three accounts (18539 entries). 2. After first launch, Start Center only, quit (S1): no change in the bundle; codesign and spctl unchanged (rc 0, accepted). 3. After File > New > Text Document, entering a short test text, waiting 60 s, closing without saving, quit (S2): - codesign rc 1, reporting "file modified" for 25 shipped files under Contents/Frameworks/LibreOfficePython.framework/Versions/3.13/lib/python3.13/ (all __pycache__/*.cpython-313.pyc); - spctl rc 1, "a sealed resource is missing or invalid"; - new files Contents/Resources/__pycache__/{pythonloader,uno,unohelper}.cpython-313.pyc and Contents/Resources/extensions/dict-en/pythonpath/__pycache__/lightproof_{handler,impl,opts}_en.cpython-313.pyc. This happened with a Danish document (document language set to Danish; accounts 1 and 3) as well as with an English document with grammar checking enabled (account 2, which in addition got lightproof_en.cpython-313.pyc). With the Danish document, the English Lightproof cache files were created too. 4. Relaunching LibreOffice, and later restarting the Mac and relaunching it: no further change in the bundle, which keeps failing codesign/spctl. LibreOffice started normally both times (my own observation as operator; not independently logged). Relation to bug 126409: comment 50 there (24 May 2020) already explains that .pyc files are created only after launch, when opening or creating a Writer document triggers Python-based writing aids, i.e. a modification of the bundle after the Gatekeeper check. The difference in 26.8.1.1 is that besides newly added cache files, 25 shipped and sealed .pyc files are overwritten in place, which fits the stale shipped .pyc files described in this report. Not established by these snapshots: which process wrote the files, whether other writes happened between snapshots, and behaviour on other macOS or LibreOffice versions, Intel Macs or installations in /Applications by an administrator. That CPython rewrites the stale shipped .pyc files on first import is consistent with the data but was not traced directly. LibreOffice kept starting, and no data loss, crash or concrete security compromise has been documented. Severity: since an ordinary Writer session on a fresh, notarized installation is reproducibly enough to make codesign and spctl reject the bundle, could you please consider whether "major" would reflect the impact better than "normal"? -- You are receiving this mail because: You are the assignee for the bug.
