NEURLFilterManager
A class you use to configure and control a URL filter.
Declaration
class NEURLFilterManagerOverview
The system performs URL filtering on your behalf according to your configuration and URL data set. The system filters all URL requests initiated with the WebKit and URLSession APIs.
During URL filtering, the system performs sub-URL generation to enumurate all possible sub-URLs for the URL in question. For example, the URL
https://www.example.com/a/b/c?id=123#fragmentparses into the following sub-URLs:
example.com
example.com/
www.example.com
www.example.com/
example.com/a
example.com/a/
www.example.com/a
www.example.com/a/
example.com/a/b
example.com/a/b/
www.example.com/a/b
www.example.com/a/b/
example.com/a/b/c
example.com/a/b/c/
www.example.com/a/b/c
www.example.com/a/b/c/
example.com/a/b/c?id=123
example.com/a/b/c?id=123/
www.example.com/a/b/c?id=123
example.com/a/b/c?id=123#fragment
www.example.com/a/b/c?id=123/
www.example.com/a/b/c?id=123#fragment
example.com/a/b/c?id=123#fragment/
www.example.com/a/b/c?id=123#fragment/
The manager matches each of these sub-URLs against your Bloom filter and then against the PIR URL database if there’s a Bloom filter match. The verdict indicates if the app should block the requested URL. Note that the manager Punycodes the requested URL before parsing. Because of this, be sure to Punycode your own URL dataset before constructing your Bloom filter and PIR database. Neither the Bloom filter nor PIR supports wildcards or regular expressions.
Instances of this class are thread-safe.
Topics
Obtaining the shared instance
Working with a Private Information Retrieval server
Working with the filter configuration
setConfiguration(pirServerURL:pirPrivacyPassIssuerURL:pirAuthenticationToken:controlProviderBundleIdentifier:)loadFromPreferences()saveToPreferences()removeFromPreferences()handleConfigChange()