kernl API
    Preparing search index...

    Function createGuardConfig

    • Build the complete guard configuration for a profile.

      The firewall field is kehto's defaultConfig() tightened to the profile. What each layer enforces:

      • The kehto engine (evaluate) enforces the content matchers, the per-applet rates registered by applyNappletRules, the generic default rate and the unfocused multiplier. Its init-burst guard only fires for callers that supply initElapsedMs; kernl's focus firewall does not, so inside kernl the per-second burst is enforced by the ingress guard, and the burstGuard field exists so a runtime firewall configured from this object agrees with it.
      • The ingress guard enforces ingressBurst, ingressQueue, quarantineThreshold, hiddenResourceAllowance and the envelope size caps.
      • The visibility gate enforces deferQueue.

      Parameters

      Returns GuardConfig

      The profile's limits and derived firewall config.

      const config = createGuardConfig('strict');
      config.limits.ingressBurst; // 8
      config.firewall.unfocusedMultiplier; // 0.25