Skip to content

request body sent in separate SSL segment (bug at 9.6.0) #27573

Closed
@mildsunrise

Description

  • Version: bug introduced in 9.6.0 and still present on 12.1.0
  • Platform: Linux 4.4.0-142-generic Release Cycle Proposal #168-Ubuntu SMP Wed Jan 16 21:00:45 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
  • Subsystem: http / https (maybe tls)
  • Minor bug.

The code:

let req = https.request("https://example.org")
req.end( Buffer.from("hello\n") );

For Node >= 9.6.0, sends two SSL segments (one with request + headers, the other with the body hello\n). Node <= 9.5.0 sends a single SSL segment with everything as expected.

If instead of passing a Buffer, we pass a string:

req.end( "hello\n" );

This works correctly in all Node.JS versions.

Metadata

Assignees

No one assigned

    Labels

    httpIssues or PRs related to the http subsystem.tlsIssues and PRs related to the tls subsystem.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions