Bug 238609 - Expand adattributiond sandbox slightly to avoid sandbox crashes
Summary: Expand adattributiond sandbox slightly to avoid sandbox crashes
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alex Christensen
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-03-31 08:11 PDT by Alex Christensen
Modified: 2022-03-31 13:55 PDT (History)
2 users (show)

See Also:


Attachments
Patch (2.27 KB, patch)
2022-03-31 08:12 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff
Patch (2.32 KB, patch)
2022-03-31 08:14 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff
Patch (2.02 KB, patch)
2022-03-31 09:42 PDT, Alex Christensen
pvollan: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Christensen 2022-03-31 08:11:31 PDT
Expand adattributiond sandbox slightly to avoid sandbox crashes
Comment 1 Alex Christensen 2022-03-31 08:12:17 PDT
Created attachment 456238 [details]
Patch
Comment 2 Alex Christensen 2022-03-31 08:12:21 PDT
<rdar://problem/91073280>
Comment 3 Alex Christensen 2022-03-31 08:14:43 PDT
Created attachment 456239 [details]
Patch
Comment 4 Per Arne Vollan 2022-03-31 08:45:20 PDT
Comment on attachment 456239 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=456239&action=review

> Source/WebKit/Resources/SandboxProfiles/ios/com.apple.WebKit.adattributiond.sb.in:151
> +;; Note this does not allow subpaths of "/"
> +(allow file-read*
> +       (literal "/"))
> +

Is there a way to make this more specific? Would allowing file-read-metadata be sufficient?
Comment 5 Alex Christensen 2022-03-31 08:55:48 PDT
No.  file-read-metadata is insufficient.  It needs at least file-read-data and at that point may as well allow file-read*
Comment 6 Alex Christensen 2022-03-31 09:36:53 PDT
We also need file-test-existence
Comment 7 Alex Christensen 2022-03-31 09:42:09 PDT
Created attachment 456249 [details]
Patch
Comment 8 Per Arne Vollan 2022-03-31 10:33:07 PDT
Comment on attachment 456249 [details]
Patch

R=me.
Comment 9 Alex Christensen 2022-03-31 13:55:20 PDT
r292171