Should work as I dont need to open my app on the managed device for
enabling the web content filter?
Yes.
When you think about this it’s a clear requirement of the current design. By definition the user of a supervised device can’t make device-wide changes, and thus there’s no way that they can configure the filter from your app. That means that the
only way to configure the filter is via a configuration profile.
Correlating your profile to the
documentation I see a number of problems:
You don’t need FilterDataProviderBundleIdentifier and FilterDataProviderDesignatedRequirement on iOS.
You can omit FilterPackets because packet filters aren’t a thing on iOS.
You’ve redacted the PluginBundleID value, so it’s not clear what bundle ID you’re using. The documentation isn’t particularly forthcoming on this either so, just to be clear, this must be the bundle ID of the container app.
When I want to set up stuff like this I lean heavily on
Apple Configurator. The following is an example of what it generates when you supply all the required parameters and nothing else:
Code Block | <dict> |
| <key>FilterBrowsers</key> |
| <true/> |
| <key>FilterSockets</key> |
| <true/> |
| <key>FilterType</key> |
| <string>Plugin</string> |
| <key>PayloadDescription</key> |
| <string>Configures content filtering settings</string> |
| <key>PayloadDisplayName</key> |
| <string>My Filter Config</string> |
| <key>PayloadIdentifier</key> |
| <string>com.apple.webcontent-filter.2EF1184F-FC41-4477-BA81-D46AB318D8BB</string> |
| <key>PayloadType</key> |
| <string>com.apple.webcontent-filter</string> |
| <key>PayloadUUID</key> |
| <string>2EF1184F-FC41-4477-BA81-D46AB318D8BB</string> |
| <key>PayloadVersion</key> |
| <integer>1</integer> |
| <key>PluginBundleID</key> |
| <string>com.example.apple-samplecode.Test667016</string> |
| <key>UserDefinedName</key> |
| <string>Test667016 Filter Config</string> |
| </dict> |
Share and Enjoy
—
Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"