1 /* This is a generated file, edit the .stub.php file instead.
2 * Stub hash: 6bbbdc8c4a33d1ff9984b3d81e4f5c9b76efcb14 */
3
4 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_name, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
5 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, name, IS_STRING, 1, "null")
6 ZEND_END_ARG_INFO()
7
8 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_module_name, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
9 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, module, IS_STRING, 1, "null")
10 ZEND_END_ARG_INFO()
11
12 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_save_path, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
13 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, path, IS_STRING, 1, "null")
14 ZEND_END_ARG_INFO()
15
16 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_id, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
17 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, id, IS_STRING, 1, "null")
18 ZEND_END_ARG_INFO()
19
20 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_create_id, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
21 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, prefix, IS_STRING, 0, "\"\"")
22 ZEND_END_ARG_INFO()
23
24 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_regenerate_id, 0, 0, _IS_BOOL, 0)
25 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, delete_old_session, _IS_BOOL, 0, "false")
26 ZEND_END_ARG_INFO()
27
28 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_decode, 0, 1, _IS_BOOL, 0)
29 ZEND_ARG_TYPE_INFO(0, data, IS_STRING, 0)
30 ZEND_END_ARG_INFO()
31
32 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_encode, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
33 ZEND_END_ARG_INFO()
34
35 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_destroy, 0, 0, _IS_BOOL, 0)
36 ZEND_END_ARG_INFO()
37
38 #define arginfo_session_unset arginfo_session_destroy
39
40 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_gc, 0, 0, MAY_BE_LONG|MAY_BE_FALSE)
41 ZEND_END_ARG_INFO()
42
43 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_get_cookie_params, 0, 0, IS_ARRAY, 0)
44 ZEND_END_ARG_INFO()
45
46 #define arginfo_session_write_close arginfo_session_destroy
47
48 #define arginfo_session_abort arginfo_session_destroy
49
50 #define arginfo_session_reset arginfo_session_destroy
51
52 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_status, 0, 0, IS_LONG, 0)
53 ZEND_END_ARG_INFO()
54
55 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_register_shutdown, 0, 0, IS_VOID, 0)
56 ZEND_END_ARG_INFO()
57
58 #define arginfo_session_commit arginfo_session_destroy
59
60 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_set_save_handler, 0, 1, _IS_BOOL, 0)
61 ZEND_ARG_INFO(0, open)
62 ZEND_ARG_INFO(0, close)
63 ZEND_ARG_TYPE_INFO(0, read, IS_CALLABLE, 0)
64 ZEND_ARG_TYPE_INFO(0, write, IS_CALLABLE, 0)
65 ZEND_ARG_TYPE_INFO(0, destroy, IS_CALLABLE, 0)
66 ZEND_ARG_TYPE_INFO(0, gc, IS_CALLABLE, 0)
67 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, create_sid, IS_CALLABLE, 1, "null")
68 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, validate_sid, IS_CALLABLE, 1, "null")
69 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, update_timestamp, IS_CALLABLE, 1, "null")
70 ZEND_END_ARG_INFO()
71
72 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_cache_limiter, 0, 0, MAY_BE_STRING|MAY_BE_FALSE)
73 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, value, IS_STRING, 1, "null")
74 ZEND_END_ARG_INFO()
75
76 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_session_cache_expire, 0, 0, MAY_BE_LONG|MAY_BE_FALSE)
77 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, value, IS_LONG, 1, "null")
78 ZEND_END_ARG_INFO()
79
80 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_set_cookie_params, 0, 1, _IS_BOOL, 0)
81 ZEND_ARG_TYPE_MASK(0, lifetime_or_options, MAY_BE_ARRAY|MAY_BE_LONG, NULL)
82 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, path, IS_STRING, 1, "null")
83 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, domain, IS_STRING, 1, "null")
84 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, secure, _IS_BOOL, 1, "null")
85 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, httponly, _IS_BOOL, 1, "null")
86 ZEND_END_ARG_INFO()
87
88 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_session_start, 0, 0, _IS_BOOL, 0)
89 ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, options, IS_ARRAY, 0, "[]")
90 ZEND_END_ARG_INFO()
91
92 ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_SessionHandlerInterface_open, 0, 2, _IS_BOOL, 0)
93 ZEND_ARG_TYPE_INFO(0, path, IS_STRING, 0)
94 ZEND_ARG_TYPE_INFO(0, name, IS_STRING, 0)
95 ZEND_END_ARG_INFO()
96
97 ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_SessionHandlerInterface_close, 0, 0, _IS_BOOL, 0)
98 ZEND_END_ARG_INFO()
99
100 ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_MASK_EX(arginfo_class_SessionHandlerInterface_read, 0, 1, MAY_BE_STRING|MAY_BE_FALSE)
101 ZEND_ARG_TYPE_INFO(0, id, IS_STRING, 0)
102 ZEND_END_ARG_INFO()
103
104 ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_SessionHandlerInterface_write, 0, 2, _IS_BOOL, 0)
105 ZEND_ARG_TYPE_INFO(0, id, IS_STRING, 0)
106 ZEND_ARG_TYPE_INFO(0, data, IS_STRING, 0)
107 ZEND_END_ARG_INFO()
108
109 ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_SessionHandlerInterface_destroy, 0, 1, _IS_BOOL, 0)
110 ZEND_ARG_TYPE_INFO(0, id, IS_STRING, 0)
111 ZEND_END_ARG_INFO()
112
113 ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_MASK_EX(arginfo_class_SessionHandlerInterface_gc, 0, 1, MAY_BE_LONG|MAY_BE_FALSE)
114 ZEND_ARG_TYPE_INFO(0, max_lifetime, IS_LONG, 0)
115 ZEND_END_ARG_INFO()
116
117 ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(arginfo_class_SessionIdInterface_create_sid, 0, 0, IS_STRING, 0)
118 ZEND_END_ARG_INFO()
119
120 #define arginfo_class_SessionUpdateTimestampHandlerInterface_validateId arginfo_class_SessionHandlerInterface_destroy
121
122 #define arginfo_class_SessionUpdateTimestampHandlerInterface_updateTimestamp arginfo_class_SessionHandlerInterface_write
123
124 #define arginfo_class_SessionHandler_open arginfo_class_SessionHandlerInterface_open
125
126 #define arginfo_class_SessionHandler_close arginfo_class_SessionHandlerInterface_close
127
128 #define arginfo_class_SessionHandler_read arginfo_class_SessionHandlerInterface_read
129
130 #define arginfo_class_SessionHandler_write arginfo_class_SessionHandlerInterface_write
131
132 #define arginfo_class_SessionHandler_destroy arginfo_class_SessionHandlerInterface_destroy
133
134 #define arginfo_class_SessionHandler_gc arginfo_class_SessionHandlerInterface_gc
135
136 #define arginfo_class_SessionHandler_create_sid arginfo_class_SessionIdInterface_create_sid
137
138
139 ZEND_FUNCTION(session_name);
140 ZEND_FUNCTION(session_module_name);
141 ZEND_FUNCTION(session_save_path);
142 ZEND_FUNCTION(session_id);
143 ZEND_FUNCTION(session_create_id);
144 ZEND_FUNCTION(session_regenerate_id);
145 ZEND_FUNCTION(session_decode);
146 ZEND_FUNCTION(session_encode);
147 ZEND_FUNCTION(session_destroy);
148 ZEND_FUNCTION(session_unset);
149 ZEND_FUNCTION(session_gc);
150 ZEND_FUNCTION(session_get_cookie_params);
151 ZEND_FUNCTION(session_write_close);
152 ZEND_FUNCTION(session_abort);
153 ZEND_FUNCTION(session_reset);
154 ZEND_FUNCTION(session_status);
155 ZEND_FUNCTION(session_register_shutdown);
156 ZEND_FUNCTION(session_set_save_handler);
157 ZEND_FUNCTION(session_cache_limiter);
158 ZEND_FUNCTION(session_cache_expire);
159 ZEND_FUNCTION(session_set_cookie_params);
160 ZEND_FUNCTION(session_start);
161 ZEND_METHOD(SessionHandler, open);
162 ZEND_METHOD(SessionHandler, close);
163 ZEND_METHOD(SessionHandler, read);
164 ZEND_METHOD(SessionHandler, write);
165 ZEND_METHOD(SessionHandler, destroy);
166 ZEND_METHOD(SessionHandler, gc);
167 ZEND_METHOD(SessionHandler, create_sid);
168
169
170 static const zend_function_entry ext_functions[] = {
171 ZEND_FE(session_name, arginfo_session_name)
172 ZEND_FE(session_module_name, arginfo_session_module_name)
173 ZEND_FE(session_save_path, arginfo_session_save_path)
174 ZEND_FE(session_id, arginfo_session_id)
175 ZEND_FE(session_create_id, arginfo_session_create_id)
176 ZEND_FE(session_regenerate_id, arginfo_session_regenerate_id)
177 ZEND_FE(session_decode, arginfo_session_decode)
178 ZEND_FE(session_encode, arginfo_session_encode)
179 ZEND_FE(session_destroy, arginfo_session_destroy)
180 ZEND_FE(session_unset, arginfo_session_unset)
181 ZEND_FE(session_gc, arginfo_session_gc)
182 ZEND_FE(session_get_cookie_params, arginfo_session_get_cookie_params)
183 ZEND_FE(session_write_close, arginfo_session_write_close)
184 ZEND_FE(session_abort, arginfo_session_abort)
185 ZEND_FE(session_reset, arginfo_session_reset)
186 ZEND_FE(session_status, arginfo_session_status)
187 ZEND_FE(session_register_shutdown, arginfo_session_register_shutdown)
188 ZEND_FALIAS(session_commit, session_write_close, arginfo_session_commit)
189 ZEND_FE(session_set_save_handler, arginfo_session_set_save_handler)
190 ZEND_FE(session_cache_limiter, arginfo_session_cache_limiter)
191 ZEND_FE(session_cache_expire, arginfo_session_cache_expire)
192 ZEND_FE(session_set_cookie_params, arginfo_session_set_cookie_params)
193 ZEND_FE(session_start, arginfo_session_start)
194 ZEND_FE_END
195 };
196
197
198 static const zend_function_entry class_SessionHandlerInterface_methods[] = {
199 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionHandlerInterface, open, arginfo_class_SessionHandlerInterface_open, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
200 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionHandlerInterface, close, arginfo_class_SessionHandlerInterface_close, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
201 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionHandlerInterface, read, arginfo_class_SessionHandlerInterface_read, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
202 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionHandlerInterface, write, arginfo_class_SessionHandlerInterface_write, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
203 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionHandlerInterface, destroy, arginfo_class_SessionHandlerInterface_destroy, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
204 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionHandlerInterface, gc, arginfo_class_SessionHandlerInterface_gc, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
205 ZEND_FE_END
206 };
207
208
209 static const zend_function_entry class_SessionIdInterface_methods[] = {
210 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionIdInterface, create_sid, arginfo_class_SessionIdInterface_create_sid, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
211 ZEND_FE_END
212 };
213
214
215 static const zend_function_entry class_SessionUpdateTimestampHandlerInterface_methods[] = {
216 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionUpdateTimestampHandlerInterface, validateId, arginfo_class_SessionUpdateTimestampHandlerInterface_validateId, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
217 ZEND_ABSTRACT_ME_WITH_FLAGS(SessionUpdateTimestampHandlerInterface, updateTimestamp, arginfo_class_SessionUpdateTimestampHandlerInterface_updateTimestamp, ZEND_ACC_PUBLIC|ZEND_ACC_ABSTRACT)
218 ZEND_FE_END
219 };
220
221
222 static const zend_function_entry class_SessionHandler_methods[] = {
223 ZEND_ME(SessionHandler, open, arginfo_class_SessionHandler_open, ZEND_ACC_PUBLIC)
224 ZEND_ME(SessionHandler, close, arginfo_class_SessionHandler_close, ZEND_ACC_PUBLIC)
225 ZEND_ME(SessionHandler, read, arginfo_class_SessionHandler_read, ZEND_ACC_PUBLIC)
226 ZEND_ME(SessionHandler, write, arginfo_class_SessionHandler_write, ZEND_ACC_PUBLIC)
227 ZEND_ME(SessionHandler, destroy, arginfo_class_SessionHandler_destroy, ZEND_ACC_PUBLIC)
228 ZEND_ME(SessionHandler, gc, arginfo_class_SessionHandler_gc, ZEND_ACC_PUBLIC)
229 ZEND_ME(SessionHandler, create_sid, arginfo_class_SessionHandler_create_sid, ZEND_ACC_PUBLIC)
230 ZEND_FE_END
231 };
232
register_session_symbols(int module_number)233 static void register_session_symbols(int module_number)
234 {
235 REGISTER_LONG_CONSTANT("PHP_SESSION_DISABLED", php_session_disabled, CONST_PERSISTENT);
236 REGISTER_LONG_CONSTANT("PHP_SESSION_NONE", php_session_none, CONST_PERSISTENT);
237 REGISTER_LONG_CONSTANT("PHP_SESSION_ACTIVE", php_session_active, CONST_PERSISTENT);
238 }
239
register_class_SessionHandlerInterface(void)240 static zend_class_entry *register_class_SessionHandlerInterface(void)
241 {
242 zend_class_entry ce, *class_entry;
243
244 INIT_CLASS_ENTRY(ce, "SessionHandlerInterface", class_SessionHandlerInterface_methods);
245 class_entry = zend_register_internal_interface(&ce);
246
247 return class_entry;
248 }
249
register_class_SessionIdInterface(void)250 static zend_class_entry *register_class_SessionIdInterface(void)
251 {
252 zend_class_entry ce, *class_entry;
253
254 INIT_CLASS_ENTRY(ce, "SessionIdInterface", class_SessionIdInterface_methods);
255 class_entry = zend_register_internal_interface(&ce);
256
257 return class_entry;
258 }
259
register_class_SessionUpdateTimestampHandlerInterface(void)260 static zend_class_entry *register_class_SessionUpdateTimestampHandlerInterface(void)
261 {
262 zend_class_entry ce, *class_entry;
263
264 INIT_CLASS_ENTRY(ce, "SessionUpdateTimestampHandlerInterface", class_SessionUpdateTimestampHandlerInterface_methods);
265 class_entry = zend_register_internal_interface(&ce);
266
267 return class_entry;
268 }
269
register_class_SessionHandler(zend_class_entry * class_entry_SessionHandlerInterface,zend_class_entry * class_entry_SessionIdInterface)270 static zend_class_entry *register_class_SessionHandler(zend_class_entry *class_entry_SessionHandlerInterface, zend_class_entry *class_entry_SessionIdInterface)
271 {
272 zend_class_entry ce, *class_entry;
273
274 INIT_CLASS_ENTRY(ce, "SessionHandler", class_SessionHandler_methods);
275 class_entry = zend_register_internal_class_ex(&ce, NULL);
276 zend_class_implements(class_entry, 2, class_entry_SessionHandlerInterface, class_entry_SessionIdInterface);
277
278 return class_entry;
279 }
280