1 /*
2   +----------------------------------------------------------------------+
3   | Copyright (c) The PHP Group                                          |
4   +----------------------------------------------------------------------+
5   | This source file is subject to version 3.01 of the PHP license,      |
6   | that is bundled with this package in the file LICENSE, and is        |
7   | available through the world-wide-web at the following url:           |
8   | http://www.php.net/license/3_01.txt                                  |
9   | If you did not receive a copy of the PHP license and are unable to   |
10   | obtain it through the world-wide-web, please send a note to          |
11   | license@php.net so we can mail you a copy immediately.               |
12   +----------------------------------------------------------------------+
13   | Authors: Amish                                                       |
14   | PHP 4.0: Mikael Johansson <mikael AT synd DOT info>                  |
15   |          Chad Cunningham                                             |
16   +----------------------------------------------------------------------+
17 */
18 
19 #ifndef PHP_PAM_H
20 #define PHP_PAM_H
21 
22 extern zend_module_entry pam_module_entry;
23 #define phpext_pam_ptr &pam_module_entry
24 
25 #define PHP_PAM_VERSION "2.2.3"
26 
27 #ifdef PHP_WIN32
28 #	define PHP_PAM_API __declspec(dllexport)
29 #elif defined(__GNUC__) && __GNUC__ >= 4
30 #	define PHP_PAM_API __attribute__ ((visibility("default")))
31 #else
32 #	define PHP_PAM_API
33 #endif
34 
35 #ifdef ZTS
36 #include "TSRM.h"
37 #endif
38 
39 ZEND_BEGIN_MODULE_GLOBALS(pam)
40 	char *servicename;
41 	zend_bool force_servicename;
42 ZEND_END_MODULE_GLOBALS(pam)
43 
44 typedef struct {
45 	char *name, *pw;
46 } pam_auth_t;
47 
48 typedef struct {
49 	char *name, *oldpw, *newpw;
50 	int count;
51 } pam_chpass_t;
52 
53 #define PAM_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(pam, v)
54 
55 #if defined(ZTS) && defined(COMPILE_DL_PAM)
56 ZEND_TSRMLS_CACHE_EXTERN()
57 #endif
58 
59 #endif	/* PHP_PAM_H */
60 
61 
62 /*
63  * Local variables:
64  * tab-width: 4
65  * c-basic-offset: 4
66  * End:
67  * vim600: noet sw=4 ts=4 fdm=marker
68  * vim<600: noet sw=4 ts=4
69  */
70