@eagleoutice/flowr - v2.16.3
    Preparing search index...

    Function isAllowedWebSocketOrigin

    • Whether a WebSocket client with the given Origin header may connect. Browsers send the origin of the page that opens the connection, so this keeps arbitrary web pages from talking to a local server (cross-site WebSocket hijacking). Clients that are no browser usually send no origin and are allowed, as are pages served from this machine and the origins in allowed (* allows all).

      Parameters

      • origin: string | undefined
      • allowed: readonly string[] = []

      Returns boolean