Skip to content

NetworkExtension iOS xcode15.0 b7

Haritha Mohan edited this page Sep 20, 2023 · 3 revisions

#NetworkExtension.framework https://github.com/xamarin/xamarin-macios/pull/19059

diff -ruN /Applications/Xcode_15.0.0-beta6.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelay.h /Applications/Xcode_15.0.0-beta7.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelay.h
--- /Applications/Xcode_15.0.0-beta6.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelay.h	2023-08-02 23:30:27
+++ /Applications/Xcode_15.0.0-beta7.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelay.h	2023-08-15 19:30:00
@@ -41,6 +41,20 @@
 @property (copy, nullable) NSURL *dnsOverHTTPSURL;
 
 /*!
+ * @property syntheticDNSAnswerIPv4Prefix
+ * @discussion An IPv4 address prefix (such as "192.0.2.0/24") that will be used to synthesize
+ *      DNS answers for apps that use `getaddrinfo()` to resolve domains included in `matchDomains`
+ */
+@property (copy, nullable) NSString *syntheticDNSAnswerIPv4Prefix;
+
+/*!
+ * @property syntheticDNSAnswerIPv6Prefix
+ * @discussion An IPv6 address prefix (such as "2001:DB8::/32") that will be used to synthesize
+ *      DNS answers for apps that use `getaddrinfo()` to resolve domains included in `matchDomains`
+ */
+@property (copy, nullable) NSString *syntheticDNSAnswerIPv6Prefix;
+
+/*!
  * @property additionalHTTPHeaderFields
  * @discussion Additional HTTP header field names and values to be added to all relay requests.
  */
diff -ruN /Applications/Xcode_15.0.0-beta6.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelayManager.h /Applications/Xcode_15.0.0-beta7.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelayManager.h
--- /Applications/Xcode_15.0.0-beta6.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelayManager.h	2023-07-14 20:06:23
+++ /Applications/Xcode_15.0.0-beta7.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS.sdk/System/Library/Frameworks/NetworkExtension.framework/Headers/NERelayManager.h	2023-08-08 04:35:05
@@ -25,6 +25,7 @@
 #endif
 
 @class NERelay;
+@class NEOnDemandRule;
 
 /*!
  * @typedef NERelayManagerError
@@ -113,6 +114,19 @@
  * @discussion An array of strings containing domain names. If the destination host name of a connection shares a suffix with one of these strings then the relay will not be used.
  */
 @property (copy, nullable) NSArray<NSString *> *excludedDomains;
+
+/*!
+ * @property onDemandRules
+ * @discussion An array of NEOnDemandRule objects. If nil, the associated relay will always apply. If non-nil, the array describes the networks on which the relay should be used or not.
+ */
+@property (copy, nullable) NSArray<NEOnDemandRule *> *onDemandRules;
+
+/*!
+ * @method loadAllManagersFromPreferencesWithCompletionHandler:
+ * @discussion This function asynchronously reads all of the NERelay configurations created by the calling app that have previously been saved to disk and returns them as NERelayManager objects.
+ * @param completionHandler A block that takes an array NERelayManager objects. The array passed to the block may be empty if no NERelay configurations were successfully read from the disk.  The NSError passed to this block will be nil if the load operation succeeded, non-nil otherwise.
+ */
++ (void)loadAllManagersFromPreferencesWithCompletionHandler:(void (^)(NSArray<NERelayManager *> *managers, NSError * __nullable error))completionHandler;
 
 @end
 
Clone this wiki locally