A race condition occurs in ASP.NET Core when using shared resources with improper synchronization, which allows an authorized attacker to elevate privileges locally. Specifically, in the Kestrel Named Pipes transport, a listener configured with `CurrentUserOnly` can lose protected namespace ownership during recovery. This allows another local user to claim the pipe path and bypass security features.