Bug 12787 - Latest macOS uses copy-chunk on named streams which results in metadata corruption
Summary: Latest macOS uses copy-chunk on named streams which results in metadata corru...
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: File services (show other bugs)
Version: unspecified
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Ralph Böhme
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-05-12 04:01 UTC by Ralph Böhme
Modified: 2018-07-07 14:04 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ralph Böhme 2017-05-12 04:01:12 UTC
Copy-chunk on streams is currently not supported. We actually end up doing a copy in the data stream (!) and the copy-chunk on the stream returns success.

Subsequently the client calls setinfo(size) on the stream which acutally creates the stream with the correct size but filled with 0 bytes.

Voila, unnoticed data corruption. Though the user might notice that the macOS metadata is somehow broken, eg Finder tags are lost.
Comment 1 Ralph Böhme 2018-07-07 14:04:34 UTC
Patches in master -7 9d30d47b1ec33c815d204198952bf597cd602b49 and in 4.7 and 4.8.