Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Generated on May 18, 2024 via composer

symfony/password-hasher v7.0.4

Provides password hashing utilities
Package summary
Share
0
issues
1
license
1
MIT
Package created
14 Feb 2021
Version published
12 Feb 2024
Maintainers
1
Total deps
1
Direct deps
0
License
MIT

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
1 Packages, Including:
symfony/password-hasher@v7.0.4
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

0
All Dependencies CSV
β“˜ This is a list of symfony/password-hasher 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities

Visualizations

Frequently Asked Questions

What does symfony/password-hasher do?

The Symfony/Password-Hasher is a PHP package that is typically used in securing applications. It provides password hashing utilities, granting developers an extra layer of security in their applications. This package allows for the creation and verification of secure hashes of plain passwords, making it an excellent tool to employ in the safeguarding of user data.

How do you use symfony/password-hasher?

To use the Symfony/Password-Hasher, make sure you have composer installed. You can then pull in the package by running $ composer require symfony/password-hasher. Here's a simple usage example:

use Symfony\Component\PasswordHasher\Hasher\PasswordHasherFactory;

// Configure different password hashers via the factory
$factory = new PasswordHasherFactory([
    'common' => ['algorithm' => 'bcrypt'],
    'memory-hard' => ['algorithm' => 'sodium'],
]);

// Retrieve the right password hasher by its name
$passwordHasher = $factory->getPasswordHasher('common');

// Hash a plain password
$hash = $passwordHasher->hash('plain'); // returns a bcrypt hash

// Verify that a given plain password matches the hash
$passwordHasher->verify($hash, 'wrong'); // returns false
$passwordHasher->verify($hash, 'plain'); // returns true (valid)

This script first creates a new instance of the PasswordHasherFactory. After, it configures bcrypt for general use and sodium for memory-hard tasks. Then, it retrieves a hasher and uses it to hash and verify a password.

Where are the symfony/password-hasher docs?

To gain a deeper understanding about the Symfony/Password-Hasher package, the documentation is your best resource. You can access it via the following link: Symfony/Password-Hasher Documentation. This contains comprehensive information on how to use and configure the password hasher to meet your specific needs.