teleport
teleport copied to clipboard
[v10] auditlog: fix panic during concurrent streams of the same session
The code attempts to wait on an existing download if one is already in progress rather than starting a concurrent download of the same session. If this code path runs, we incorrectly defer a call to a nil function, triggering a panic.
This bug was introduced in #7360.
In some cases, an auth server can see a response from the uploader with an empty session ID. If this is the case, skip emitting the session end and upload events, as there's no action to take.
This scenario can happen when multiple auth servers are running upload completers and working on the same uploads simultaneously.
Forward port of #15348