Zum Hauptinhalt springen
tsecurity.de LIVE
Echtzeit-Radar & Feeds
Alle RSS Feeds
👥 Community & Social
IT NachrichtenFritzbox-Besitzer sollten diesen Speedtest kennen(24.09.2026 um 06:39 Uhr)
IT NachrichtenApple iOS 27.0.1: Wichtiges Update steht bereit(24.09.2026 um 06:44 Uhr)
Android Tipps & SecurityBYD strebt dichtes Netz an Ladestationen auf Tankstellen-Level an(24.09.2026 um 07:00 Uhr)
IT NachrichtenFritzbox-Besitzer sollten diesen Speedtest kennen(24.09.2026 um 06:39 Uhr)
IT NachrichtenApple iOS 27.0.1: Wichtiges Update steht bereit(24.09.2026 um 06:44 Uhr)
Android Tipps & SecurityBYD strebt dichtes Netz an Ladestationen auf Tankstellen-Level an(24.09.2026 um 07:00 Uhr)
Intelligence View
⚡ tsecurity.de Intelligence

CORS + Auth Worked Perfectly Locally, Then Broke the Moment I Deployed (Here's Why)

I ran into this bug recently and it took me longer to fix than I'd like to admit: my React + Express app worked flawlessly on localhost, but the moment I deployed it, authenticated requests started silently failing. No errors in my own…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!

 I ran into this bug recently and it took me longer to fix than I'd like to admit: my React + Express app worked flawlessly on localhost, but the moment I deployed it, authenticated requests started silently failing. No errors in my own code — just requests that looked like they went out, but the backend never seemed to receive the session/token.

The setup



React frontend and Express backend deployed to separate origins (different domains/subdomains)

Auth relying on a cookie (or JWT sent with credentials) set by the backend

Locally, both ran on localhost with different ports, which browsers treat more leniently



What actually happened

Once frontend and backend were on genuinely different origins in production, a few things I'd gotten away with locally stopped working:



My CORS config allowed origin: '*' — which silently breaks anything using credentials, since browsers won't send cookies/auth headers when the origin is a wildcard.

The cookie itself wasn't configured for cross-site use — no SameSite=None; Secure, which most browsers now require for any cookie sent across origins over HTTPS.

On the frontend, requests weren't explicitly sending credentials (credentials: 'include' in fetch, or withCredentials: true in axios).



Locally, same-origin-ish behavior papered over all three problems at once.

The fix



Set CORS to an explicit origin (not *) and credentials: true on the Express side

Set the cookie with SameSite=None; Secure so browsers allow it cross-site

Explicitly send credentials on every authenticated request from the frontend



Once all three were aligned, everything that had been "randomly failing" in production started working immediately.

Takeaway: if your auth works locally but silently fails after deploy, check CORS origin config, cookie SameSite/Secure attributes, and whether the frontend is actually sending credentials — together, not just one of them.

SOC Incident Playbook: Vulnerability Remediation & Verification
title: Detect Exploitation - CORS + Auth Worked Perfectly Locally, Then Broke the Moment I Deployed (Here's Why)
id: 7cefe36c-6c42-4894-a3d5-802b10fb854e
status: experimental
description: Automatisch generierte SIEM-Erkennungsregel basierend auf CTI Intelligence
references:
  - https://tsecurity.de/
author: iShareStuff CTI Automated Detection Engine
date: 2026-09-24
logsource:
  category: network_connection
  product: any
detection:
  selection:
      CommandLine|contains:
        - 'exploit'
  condition: selection
falsepositives:
  - Legitime administrative Zugriffe oder Penetrationstests
level: high
tags:
  - attack.initial_access
rule CTI_Threat_Indicator {
    meta:
        author = "iShareStuff CTI Automated Detection Engine"
        date = "2026-09-24"
        description = "YARA Signature for "
    strings:
        $str = "CORS + Auth Worked Perfectly L" ascii wide
    condition:
        any of them
}
tsecurity.de Cognitive Threat RAG
Fokus-Vektor:

Kognitive Analyse für identifizierte Bedrohung: Erhöhte Bedrohungslage im Bereich CORS + Auth Worked Perfectly Locally, Th.... Basierend auf 368k Vektor-Korrelationen werden sofortige Isolationsmaßnahmen für betroffene Endpunkte empfohlen.

🛡️ Angriffsfläche & Exposure

Netzwerk/Remote-Zugriff ohne Vorauthentifizierung möglich.

Empfohlene Sofortmaßnahmen
  • 1. Perimeter-Inspektion: Relevante Portfreigaben und exponierte Endpunkte unverzüglich scannen.
  • 2. Patch-Applikation: Hersteller-Hotfix einspielen oder betroffene Daemons in isolierte DMZ-Segmente überführen.
  • 3. Telemetrie & EDR-Alerts: Prozessaufrufe und Child-Processes auf anomale Shell-Spawns überwachen.
🔗 Semantisch verwandte Zero-Days MariaDB 11.7 VEC
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten CORS + Auth Worked Perfectly Locally, Then Broke the Moment I Deployed (Here's Why)

Thematisch verwandte Begriffe: CORS, Auth, Worked, Perfectly · 6 Treffer

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-96676 | A vulnerability was identified in Fast FAC1900R 20190827_2.0.2. The impa…
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Themen-Radar & Intelligence Matrix
Echtzeit-Taxonomie nach Angriffsvektoren & Plattformen

tsecurity.de Live Threat Radar

🔴 LIVE RADAR
MONITORING
AKTIV
CVE-DATENBANK
LIVE
🔍
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Bearbeitungsmodus — Senden überschreibt deine Nachricht
Community-Puls — was gerade passiert
lädt…
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
Zurück Ziehen Vor
Links: vorheriger Artikel Rechts: nächster Artikel unten: schließen
News NIS-2 Frühwarnung Tier-1 Intel TTP ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

Zurück: vorheriger Vor: nächster
↗ Original-Quelle
Social Reaktionen Deine Reaktion zählt
Einstufung & Relevanz-Poll 0 Stimmen
In sozialen Netzwerken teilen 1-Klick