Bug 169148 - [MediaStream iOS] REGRESSION(r212883): Missing function definition breaks sandbox
Summary: [MediaStream iOS] REGRESSION(r212883): Missing function definition breaks san...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Brent Fulgham
URL:
Keywords: InRadar
Depends on: 168756
Blocks:
  Show dependency treegraph
 
Reported: 2017-03-03 14:06 PST by Brent Fulgham
Modified: 2017-03-03 16:33 PST (History)
5 users (show)

See Also:


Attachments
Patch (2.26 KB, patch)
2017-03-03 14:14 PST, Brent Fulgham
no flags Details | Formatted Diff | Diff
Patch (1.68 KB, patch)
2017-03-03 16:15 PST, Brent Fulgham
no flags Details | Formatted Diff | Diff
Patch (1.68 KB, patch)
2017-03-03 16:15 PST, Brent Fulgham
achristensen: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brent Fulgham 2017-03-03 14:06:27 PST
The changes in <https://trac.webkit.org/changeset/212883> add a new call to 'shared-preferences-read'. Unfortunately, 'shared-preferences-read' is a custom function defined in com.apple.WebKit.WebContent.sb.in, but not the iOS-specific com.apple.WebKit.WebContent.sb file. This causes the sandbox to fail to parse.
Comment 1 Brent Fulgham 2017-03-03 14:12:09 PST
<rdar://problem/30825728>
Comment 2 Brent Fulgham 2017-03-03 14:14:17 PST
Created attachment 303341 [details]
Patch
Comment 3 Alexey Proskuryakov 2017-03-03 14:52:06 PST
Comment on attachment 303341 [details]
Patch

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

> Source/WebKit2/Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:116
> +                        (literal (string-append "/Library/Preferences/" domain ".plist"))

Is this where preferences live on iOS? Perhaps we don't need this fallback path at all, and just rely on user-preference-read.

It may be best to just use user-preference-read instead of defining a function.

> Source/WebKit2/Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:117
> +                        (home-library-preferences-literal (string-append "/" domain ".plist"))

Wouldn't we need to define this function too?
Comment 4 Brent Fulgham 2017-03-03 16:15:19 PST
Created attachment 303352 [details]
Patch
Comment 5 Brent Fulgham 2017-03-03 16:15:50 PST
Created attachment 303353 [details]
Patch
Comment 6 Brent Fulgham 2017-03-03 16:33:41 PST
Committed r213394: <http://trac.webkit.org/changeset/213394>