Is there a memory limit for macOS System Network Extension?

As documented in this thread, there is a hard memory limit for iOS Network Extensions.

Is there a memory limit for macOS System Network Extensions?

Answered by DTS Engineer in 678937022

I don’t think so. In fact, AFAICT macOS doesn’t limit NE appexes either.

So, here’s where I give away some of my secrets (-: These limits are actually encoded in a file on the system, /System/Library/LaunchDaemons/com.apple.jetsamproperties.Mac.plist. Here’s a relevant snippet:

<key>com.apple.networkextension.app-proxy</key>
<dict>
    <key>ActiveHardMemoryLimit</key>
    <integer>-1</integer>
    <key>InactiveHardMemoryLimit</key>
    <integer>-1</integer>
    <key>JetsamPriority</key>
    <integer>14</integer>
</dict>
<key>com.apple.networkextension.packet-tunnel</key>
<dict>
    <key>ActiveHardMemoryLimit</key>
    <integer>-1</integer>
    <key>InactiveHardMemoryLimit</key>
    <integer>-1</integer>
    <key>JetsamPriority</key>
    <integer>14</integer>
</dict>

IMPORTANT The location and format of this file is not considered API. It’s fine to poke around in the file to get a better understanding of how the system works, but you must not ship code that relies on its details.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Accepted Answer

I don’t think so. In fact, AFAICT macOS doesn’t limit NE appexes either.

So, here’s where I give away some of my secrets (-: These limits are actually encoded in a file on the system, /System/Library/LaunchDaemons/com.apple.jetsamproperties.Mac.plist. Here’s a relevant snippet:

<key>com.apple.networkextension.app-proxy</key>
<dict>
    <key>ActiveHardMemoryLimit</key>
    <integer>-1</integer>
    <key>InactiveHardMemoryLimit</key>
    <integer>-1</integer>
    <key>JetsamPriority</key>
    <integer>14</integer>
</dict>
<key>com.apple.networkextension.packet-tunnel</key>
<dict>
    <key>ActiveHardMemoryLimit</key>
    <integer>-1</integer>
    <key>InactiveHardMemoryLimit</key>
    <integer>-1</integer>
    <key>JetsamPriority</key>
    <integer>14</integer>
</dict>

IMPORTANT The location and format of this file is not considered API. It’s fine to poke around in the file to get a better understanding of how the system works, but you must not ship code that relies on its details.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Is there a memory limit for macOS System Network Extension?
 
 
Q