php-internal-docs 8.4.8
Unofficial docs for php/php-src
Loading...
Searching...
No Matches
php_hash_fnv.h File Reference

Go to the source code of this file.

Data Structures

struct  PHP_FNV132_CTX
 
struct  PHP_FNV164_CTX
 

Macros

#define PHP_FNV1_32_INIT   ((uint32_t)0x811c9dc5)
 
#define PHP_FNV_32_PRIME   ((uint32_t)0x01000193)
 
#define PHP_FNV1_64_INIT   ((uint64_t)0xcbf29ce484222325ULL)
 
#define PHP_FNV_64_PRIME   ((uint64_t)0x100000001b3ULL)
 
#define PHP_FNV132_SPEC   "l."
 
#define PHP_FNV164_SPEC   "q."
 

Enumerations

enum  php_fnv_type {
  PHP_FNV_NONE = 0 , PHP_FNV0_32 = 1 , PHP_FNV1_32 = 2 , PHP_FNV1a_32 = 3 ,
  PHP_FNV0_64 = 4 , PHP_FNV1_64 = 5 , PHP_FNV1a_64 = 6
}
 

Functions

PHP_HASH_API void PHP_FNV132Init (PHP_FNV132_CTX *context, ZEND_ATTRIBUTE_UNUSED HashTable *args)
 
PHP_HASH_API void PHP_FNV132Update (PHP_FNV132_CTX *context, const unsigned char *input, size_t inputLen)
 
PHP_HASH_API void PHP_FNV1a32Update (PHP_FNV132_CTX *context, const unsigned char *input, size_t inputLen)
 
PHP_HASH_API void PHP_FNV132Final (unsigned char digest[4], PHP_FNV132_CTX *context)
 
PHP_HASH_API void PHP_FNV164Init (PHP_FNV164_CTX *context, ZEND_ATTRIBUTE_UNUSED HashTable *args)
 
PHP_HASH_API void PHP_FNV164Update (PHP_FNV164_CTX *context, const unsigned char *input, size_t inputLen)
 
PHP_HASH_API void PHP_FNV1a64Update (PHP_FNV164_CTX *context, const unsigned char *input, size_t inputLen)
 
PHP_HASH_API void PHP_FNV164Final (unsigned char digest[8], PHP_FNV164_CTX *context)
 

Macro Definition Documentation

◆ PHP_FNV132_SPEC

#define PHP_FNV132_SPEC   "l."

Definition at line 45 of file php_hash_fnv.h.

◆ PHP_FNV164_SPEC

#define PHP_FNV164_SPEC   "q."

Definition at line 50 of file php_hash_fnv.h.

◆ PHP_FNV1_32_INIT

#define PHP_FNV1_32_INIT   ((uint32_t)0x811c9dc5)

Definition at line 20 of file php_hash_fnv.h.

◆ PHP_FNV1_64_INIT

#define PHP_FNV1_64_INIT   ((uint64_t)0xcbf29ce484222325ULL)

Definition at line 24 of file php_hash_fnv.h.

◆ PHP_FNV_32_PRIME

#define PHP_FNV_32_PRIME   ((uint32_t)0x01000193)

Definition at line 22 of file php_hash_fnv.h.

◆ PHP_FNV_64_PRIME

#define PHP_FNV_64_PRIME   ((uint64_t)0x100000001b3ULL)

Definition at line 26 of file php_hash_fnv.h.

Enumeration Type Documentation

◆ php_fnv_type

Enumerator
PHP_FNV_NONE 
PHP_FNV0_32 
PHP_FNV1_32 
PHP_FNV1a_32 
PHP_FNV0_64 
PHP_FNV1_64 
PHP_FNV1a_64 

Definition at line 32 of file php_hash_fnv.h.

Function Documentation

◆ PHP_FNV132Final()

PHP_HASH_API void PHP_FNV132Final ( unsigned char digest[4],
PHP_FNV132_CTX * context )

Definition at line 104 of file hash_fnv.c.

◆ PHP_FNV132Init()

PHP_HASH_API void PHP_FNV132Init ( PHP_FNV132_CTX * context,
ZEND_ATTRIBUTE_UNUSED HashTable * args )

Definition at line 86 of file hash_fnv.c.

◆ PHP_FNV132Update()

PHP_HASH_API void PHP_FNV132Update ( PHP_FNV132_CTX * context,
const unsigned char * input,
size_t inputLen )

Definition at line 92 of file hash_fnv.c.

◆ PHP_FNV164Final()

PHP_HASH_API void PHP_FNV164Final ( unsigned char digest[8],
PHP_FNV164_CTX * context )

Definition at line 139 of file hash_fnv.c.

◆ PHP_FNV164Init()

PHP_HASH_API void PHP_FNV164Init ( PHP_FNV164_CTX * context,
ZEND_ATTRIBUTE_UNUSED HashTable * args )

Definition at line 121 of file hash_fnv.c.

◆ PHP_FNV164Update()

PHP_HASH_API void PHP_FNV164Update ( PHP_FNV164_CTX * context,
const unsigned char * input,
size_t inputLen )

Definition at line 127 of file hash_fnv.c.

◆ PHP_FNV1a32Update()

PHP_HASH_API void PHP_FNV1a32Update ( PHP_FNV132_CTX * context,
const unsigned char * input,
size_t inputLen )

Definition at line 98 of file hash_fnv.c.

◆ PHP_FNV1a64Update()

PHP_HASH_API void PHP_FNV1a64Update ( PHP_FNV164_CTX * context,
const unsigned char * input,
size_t inputLen )

Definition at line 133 of file hash_fnv.c.