diff options
author | Remi Collet <remi@remirepo.net> | 2024-09-13 10:13:12 +0200 |
---|---|---|
committer | Remi Collet <remi@php.net> | 2024-09-13 10:13:12 +0200 |
commit | ef4627a6a618b460cbbea109e3e0522c891be72c (patch) | |
tree | 466a4678a4c18d4a636f3375f4b72e3045cde437 /xpass.stub.php | |
parent | 5bca3985ce597abd2db703e0944160a8f73dd84a (diff) |
More bindings (function missing in php)
- add crypt_gensalt(?string $salt = null, int $count = 0): ?string {}
- add crypt_preferred_method(): ?string {}
- add crypt_checksalt(string $salt): int {}
and bump version to 1.1.0-dev (new functions)
Diffstat (limited to 'xpass.stub.php')
-rw-r--r-- | xpass.stub.php | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/xpass.stub.php b/xpass.stub.php new file mode 100644 index 0000000..4038b41 --- /dev/null +++ b/xpass.stub.php @@ -0,0 +1,58 @@ +<?php + +/** @generate-class-entries */ + +/* use XPASS prefix to avoid conflicts with standard constants */ + +/** @var string */ +const XPASS_CRYPT_STD_DES = ''; +/** @var string */ +const XPASS_CRYPT_EXT_DES = '_'; +/** @var string */ +const XPASS_CRYPT_MD5 = '$1$'; +/** @var string */ +const XPASS_CRYPT_BLOWFISH = '$2y$'; +/** @var string */ +const XPASS_CRYPT_SHA256 = '$5$'; +/** @var string */ +const XPASS_CRYPT_SHA512 = '$6$'; +/** @var string */ +const XPASS_CRYPT_SCRYPT = '$7$'; +/** @var string */ +const XPASS_CRYPT_GOST_YESCRYPT = '$gy$'; +/** @var string */ +const XPASS_CRYPT_YESCRYPT = '$y$'; + +/** + * @var int + * @cvalue CRYPT_SALT_OK + */ +const CRYPT_SALT_OK = UNKNOWN; +/** + * @var int + * @cvalue CRYPT_SALT_INVALID + */ +const CRYPT_SALT_INVALID = UNKNOWN; +/** + * @var int + * @cvalue CRYPT_SALT_METHOD_DISABLED + */ +const CRYPT_SALT_METHOD_DISABLED = UNKNOWN; +/** + * @var int + * @cvalue CRYPT_SALT_METHOD_LEGACY + */ +const CRYPT_SALT_METHOD_LEGACY = UNKNOWN; +/** + * @var int + * @cvalue CRYPT_SALT_TOO_CHEAP + */ +const CRYPT_SALT_TOO_CHEAP = UNKNOWN; + + +function crypt_gensalt(?string $salt = null, int $count = 0): ?string {} + +function crypt_preferred_method(): ?string {} + +function crypt_checksalt(string $salt): int {} + |