Skip to content

[v16] prevent session id reuse#42133

Merged
capnspacehook merged 2 commits intobranch/v16from
bot/backport-42123-branch/v16
May 30, 2024
Merged

[v16] prevent session id reuse#42133
capnspacehook merged 2 commits intobranch/v16from
bot/backport-42123-branch/v16

Conversation

@capnspacehook
Copy link
Copy Markdown
Contributor

Backport #42123 to branch/v16

changelog: fix session recordings getting overwritten or not uploaded

If a user sets `TELEPORT_SESSION` to a session ID
that isn't running, the sent session ID is ignored
and a new one is used to prevent the user
controlling the value. When parsing a session ID
the parsed result is used to ensure all session
IDs will have the same format.
`CreateSessionTracker` is updated to create
instead of upsert to ensure `SessionTracker`
resources cannot be overwritten by accident.

Clients often need to know the current session ID,
and before when they were in control of it that
wasn't an issue. To fix this servers will send the
current session ID in a SSH channel request on the
channel the SSH session was created on. This
should be fully backwards compatible, as when an
unknown SSH request type is received clients will
just ignore it/reply with false.
@capnspacehook capnspacehook added this pull request to the merge queue May 30, 2024
Merged via the queue into branch/v16 with commit 646bd5f May 30, 2024
@capnspacehook capnspacehook deleted the bot/backport-42123-branch/v16 branch May 30, 2024 02:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants