All blog posts Blog

When your AI security layer goes down

Fail open everywhere and an outage becomes an open path to refunds. Fail closed everywhere and customers can't ask where their order is. Decide per boundary, before the outage.

Koreshield Labs2026-10-243 min read

The question to answer before launch

What happens to the workflow when the security layer is unavailable? If the answer is "everything keeps working, unprotected", an outage silently becomes an open path to refund and payment tools. If the answer is "everything stops", customers cannot even ask where their order is.

The right answer depends on what the request is about to do. In the Flur Commerce deployment, input and context checks fail open so browsing and ordinary support continue, while consequential actions such as orders and payments fail closed once enforcement is on.

Input, context and output checks degrade open; action and redaction checks block when Koreshield is unreachable
The SDK defaults: the failure behaviour follows what the request is about to do.

Safe defaults in the SDKs

Koreshield's Python and TypeScript SDKs encode that asymmetry so teams do not have to hand-write it.

  • Input, context and output checks time out in 2 to 3 seconds and, if Koreshield is unreachable, allow the request and mark it degraded.
  • Action and redaction checks time out in 2 seconds and block if Koreshield is unreachable.
  • A decorator can guard a tool function directly, so the action check cannot be forgotten.

Be strict about the right failures

Outages and misconfiguration are different problems. Invalid API keys and invalid requests raise errors in the SDKs; they never fail open. A misconfigured key that silently allows everything is worse than no integration at all, because everyone believes the workflow is protected.

Retries happen only on network errors, 429 and 503, and they honour Retry-After. Fail loudly on configuration, retry politely on load, and decide deliberately on outages.

Fail fast under load

A security layer that hangs under load is a liability. The worst outcome is requests piling up until sockets reset and nobody knows what was checked.

Koreshield's API is built to fail fast instead. When the scan ceiling or database pool is saturated, it returns a retryable 503, so the SDK can back off and the application's fallback can apply. Capacity tiers are only approved after load, spike, recovery and soak tests pass.

A short checklist

Before enforcement, write down for each workflow:

  • Which boundaries fail open and which fail closed.
  • What the customer sees when an action is held.
  • Who is alerted when requests are marked degraded.
  • How the team will review actions that were held during an outage.

Sources and further reading

Koreshield SDKs and integration guideDetect first: rolling out AI security without breaking support