Skip to main content

What it flags

A literal bcrypt cost below the configured minimum (10 by default) passed to hash, hashSync, genSalt or genSaltSync.

How to review or fix

Use a cost at or above your minimum and measure the hashing time. The work factor is 2 raised to the cost. An inline fix proposes 12 when that meets the configured minimum. For a higher minimum, choose the cost manually.

Configuration

Set minCost in loadwise.config.json to an integer from 1 through 31. The default is 10.
Set the rule to "off" in loadwise.config.json to drop its findings: