Skip to content

Instantly share code, notes, and snippets.

@OlivierJaquemet
Created September 9, 2024 16:04
Show Gist options
  • Save OlivierJaquemet/1edc274a927aef6fe2ecd78c6b9e140e to your computer and use it in GitHub Desktop.
Save OlivierJaquemet/1edc274a927aef6fe2ecd78c6b9e140e to your computer and use it in GitHub Desktop.
Default work factor for bcrypt in various implementations across languages

Table with different bcrypt implementations across languages, their default work factors, and links to sources for more information:

Language / Library Default Work Factor Source Information
Python (bcrypt library) 12 https://pypi.org/project/bcrypt/
Java (jBCrypt) 10 https://www.mindrot.org/projects/jBCrypt/
JavaScript (bcrypt.js) 10 https://github.com/dcodeIO/bcrypt.js
C# (.NET BCrypt.Net) 11 https://github.com/BcryptNet/bcrypt.net
PHP (password_hash()) 10 https://www.php.net/manual/en/function.password-hash.php
Ruby (bcrypt-ruby) 12 https://github.com/codahale/bcrypt-ruby
Go (golang/x/crypto/bcrypt) 10 https://pkg.go.dev/golang.org/x/crypto/bcrypt
Laravel (PHP) 12 https://readouble.com/laravel/11.x/en/hashing.html

This table summarizes the default work factor for bcrypt in various implementations across languages and provides direct links to their respective sources.

Last checked on 2024-09-09

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