Sharing data via App groups broken for Network Extension

Originator:mayurjoshi7
Number:rdar://37309638 Date Originated:February 7 2018
Status:Open Resolved:
Product: Product Version:
Classification: Reproducible:iOS 11
 
Goal is to create a Network Extension. Data Provider checks for rules, if the rule doesn't exist, it passes that URL to be handled by Control Provider. Issues :

1. URL in Control Provider only contains domain and not the full URL.
2. For the 1st issue, I am using App Groups where I set the URL in Data Provider which will be fetched eventually by Control Provider. This was working fine in iOS 10. But since iOS 11, this is breaking. If I set something in Data Provider, it is not being fetched in Control Provider. 

Steps to Reproduce:
- Create a network extension with NEFilterDataProvider and NEFilterControlProvider
- Set proper entitlements for App Groups
- Set some value in Data Provider in handleNewFlow function, Eg. 
[defaults setObject:@"MyText" forKey:@"MyKey"]
- Try to access this value in Control Provider in handleNewFlow functions, Eg.
NSString* myText = [defaults objectForKey:@"MyKey"]
- myText is nil

Expected Results:
myText var should have the value set in Data Provider

Actual Results:
myText is nil

Version/Build:
iOS 11.2.5

Configuration:
iPhone 6

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!