Skip to content

A throwing replay() leaks the session and its maxSessions slot #8

Description

@damusix

If replay() throws while a client reconnects, the session stays registered for good, and its keep-alive timer keeps running. With maxSessions set, every later client gets a 503. On 1.1.0 the same throw crashes the process with ERR_HTTP_HEADERS_SENT.

publish() can trigger this by itself. It records an event whose id contains a null character, even though session.push() rejects that id. So every reconnect that replays the event throws.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions