Skip to content

infinite loop with crypto.randomBytes() causing 100% CPU hang #813

@edef1c

Description

@edef1c
var crypto = require('crypto')
while (true)
  console.log(crypto.randomBytes(32).toString('hex'))

The process prints a bunch of random numbers (yay!) and then hangs badly (:cry:) at 100% CPU.
I'm not sure how to debug this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    cryptoIssues and PRs related to the crypto subsystem.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions