Use crypt () in PHP for user authentication. The crypt () function returns a string encrypted with DES, Blowfish, or MD5. In different operating systems, the behavior of this function is different. some operating systems support more than one
There are many encryption functions in php functions, one of which can implement data encryption functions is called the crypt () function. The crypt () function uses a one-way algorithm without corresponding decryption functions. It returns a
The crypt () function returns a string encrypted with DES, Blowfish, or MD5. In different operating systems, the behavior of this function is different. Some operating systems support more than one algorithm type. During installation, PHP checks
Data encryptionData encryption uses cryptography technology to encrypt information, realize the concealment of information, and thus play a role in protecting information security. It uses the encryption algorithm and the encryption key to process
The back-end password store is via
crypt function +
salt , as follows:
pwd = crypt(value ,salt)
The salt format is $2a$08$aabbccddee , so the encryption algorithm should be blowfish , then the problem comes, how to implement the crypt function
The crypt () function returns a string that is encrypted using the DES, Blowfish, or MD5 algorithms.
On different operating systems, the function behaves differently, and some operating systems support more than one type of algorithm. At
PHP Learning--php Encryption, PHP learning--php encryption
There are several types of encryption in PHP:
1. MD5 Encryption
String MD5 (string $str [, bool $raw _output = false])
Parameters
STR--the original string.
Raw_output--If the optional
Several methods to implement encryption in PHP are introduced. Several methods for implementing encryption in PHP this article mainly introduces several methods for implementing encryption in PHP, which are very comprehensive and practical and are
Introduction of several ways to implement encryption in PHP
This article mainly introduces the PHP implementation of several methods of encryption, very comprehensive and practical, are often needed in the project, the need for friends can refer to
This article mainly introduces several PHP encryption methods, which are very comprehensive and practical. they are often used in projects. if you need them, you can refer to the following PHP encryption methods:
1. MD5 encryption
String md5
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.