프로퍼티 | 타입 | 설명 | |
---|---|---|---|
$_key | string | ||
$_mcrypt | resource |
메소드 | 설명 | |
---|---|---|
__construct ( string | array $options = [] ) | Crypt constructor. | |
decrypt ( string $text, string $key = null ) : string | Decrypts an encrypted text | |
encrypt ( string $text, string $key = null ) : string | Encrypts a text |
public __construct ( string | array $options = [] ) | ||
$options | string | array |
echo $crypt->decrypt($encrypted, "decrypt password");
$encrypted = $crypt->encrypt("Ultra-secret text", "encrypt password");