256
256
"IPv6) */\n\nvoid VRT_acl_log(const struct sess *, const char "
257
257
"*msg);\n\n/* Regexp related */\nvoid VRT_re_init(void **, "
258
258
"const char *);\nvoid VRT_re_fini(void *);\nint VRT_re_match(cons"
259
"t char *, void *re);\nconst char *VRT_regsub(const struct "
260
"sess *sp, int all, const char *,\n void *, const char *);\n"
261
"\nvoid VRT_panic(const struct sess *sp, const char *, ...);\n"
262
"void VRT_ban(struct sess *sp, char *, ...);\nvoid VRT_ban_string"
263
"(struct sess *sp, const char *);\nvoid VRT_purge(const struct "
264
"sess *sp, double ttl, double grace);\n\nvoid VRT_count(const "
265
"struct sess *, unsigned);\nint VRT_rewrite(const char *, const "
266
"char *);\nvoid VRT_error(struct sess *, unsigned, const char "
267
"*);\nint VRT_switch_config(const char *);\n\nenum gethdr_e "
268
"{ HDR_REQ, HDR_RESP, HDR_OBJ, HDR_BEREQ, HDR_BERESP };\n"
269
"char *VRT_GetHdr(const struct sess *, enum gethdr_e where, "
270
"const char *);\nvoid VRT_SetHdr(const struct sess *, enum "
271
"gethdr_e where, const char *,\n const char *, ...);\n"
272
"void VRT_handling(struct sess *sp, unsigned hand);\n"
273
"\nvoid VRT_hashdata(const struct sess *sp, const char *str, "
274
"...);\n\n/* Simple stuff */\nint VRT_strcmp(const char *s1, "
275
"const char *s2);\nvoid VRT_memmove(void *dst, const void *src, "
276
"unsigned len);\n\nvoid VRT_ESI(const struct sess *sp);\n"
277
"void VRT_Rollback(struct sess *sp);\n\n/* Synthetic pages "
278
"*/\nvoid VRT_synth_page(const struct sess *sp, unsigned flags, "
279
"const char *, ...);\n\n/* Backend related */\nvoid VRT_init_dir("
280
"struct cli *, struct director **, const char *name,\n"
281
" int idx, const void *priv);\nvoid VRT_fini_dir(struct "
282
"cli *, struct director *);\n\n/* VMOD/Modules related */\n"
283
"int VRT_Vmod_Init(void **hdl, void *ptr, int len, const char "
284
"*nm,\n const char *path, struct cli *cli);\nvoid VRT_Vmod_Fin"
285
"i(void **hdl);\n\nstruct vmod_priv;\ntypedef void vmod_priv_free"
286
"_f(void *);\nstruct vmod_priv {\n\tvoid\t\t\t*priv;\n"
287
"\tvmod_priv_free_f\t*free;\n};\n\ntypedef int vmod_init_f(struct"
288
" vmod_priv *, const struct VCL_conf *);\n\nstatic inline "
289
"void\nvmod_priv_fini(const struct vmod_priv *p)\n"
290
"{\n\n\tif (p->priv != (void*)0 && p->free != (void*)0)\n"
291
"\t\tp->free(p->priv);\n}\n\n/* Stevedore related functions "
292
"*/\nint VRT_Stv(const char *nm);\n\n/* Convert things to string "
293
"*/\n\nchar *VRT_IP_string(const struct sess *sp, const struct "
294
"sockaddr_storage *sa);\nchar *VRT_int_string(const struct "
295
"sess *sp, int);\nchar *VRT_double_string(const struct sess "
296
"*sp, double);\nchar *VRT_time_string(const struct sess *sp, "
297
"double);\nconst char *VRT_bool_string(const struct sess *sp, "
298
"unsigned);\nconst char *VRT_backend_string(const struct sess "
299
"*sp, const struct director *d);\n\n#define VRT_done(sp, hand)\t"
300
"\t\t\\\n\tdo {\t\t\t\t\t\\\n\t\tVRT_handling(sp, hand);\t\t"
301
"\\\n\t\treturn (1);\t\t\t\\\n\t} while (0)\n\nconst char *VRT_Wr"
302
"kString(const struct sess *sp, const char *p, ...);\n"
259
"t struct sess *sp, const char *, void *re);\nconst char *VRT_reg"
260
"sub(const struct sess *sp, int all, const char *,\n"
261
" void *, const char *);\n\nvoid VRT_panic(const struct "
262
"sess *sp, const char *, ...);\nvoid VRT_ban(struct sess *sp, "
263
"char *, ...);\nvoid VRT_ban_string(struct sess *sp, const "
264
"char *);\nvoid VRT_purge(const struct sess *sp, double ttl, "
265
"double grace);\n\nvoid VRT_count(const struct sess *, unsigned);"
266
"\nint VRT_rewrite(const char *, const char *);\nvoid VRT_error(s"
267
"truct sess *, unsigned, const char *);\nint VRT_switch_config(co"
268
"nst char *);\n\nenum gethdr_e { HDR_REQ, HDR_RESP, HDR_OBJ, "
269
"HDR_BEREQ, HDR_BERESP };\nchar *VRT_GetHdr(const struct sess "
270
"*, enum gethdr_e where, const char *);\nvoid VRT_SetHdr(const "
271
"struct sess *, enum gethdr_e where, const char *,\n"
272
" const char *, ...);\nvoid VRT_handling(struct sess *sp, "
273
"unsigned hand);\n\nvoid VRT_hashdata(const struct sess *sp, "
274
"const char *str, ...);\n\n/* Simple stuff */\nint VRT_strcmp(con"
275
"st char *s1, const char *s2);\nvoid VRT_memmove(void *dst, "
276
"const void *src, unsigned len);\n\nvoid VRT_ESI(const struct "
277
"sess *sp);\nvoid VRT_Rollback(struct sess *sp);\n"
278
"\n/* Synthetic pages */\nvoid VRT_synth_page(const struct "
279
"sess *sp, unsigned flags, const char *, ...);\n\n"
280
"/* Backend related */\nvoid VRT_init_dir(struct cli *, struct "
281
"director **, const char *name,\n int idx, const void *priv);\n"
282
"void VRT_fini_dir(struct cli *, struct director *);\n"
283
"\n/* VMOD/Modules related */\nint VRT_Vmod_Init(void **hdl, "
284
"void *ptr, int len, const char *nm,\n const char *path, "
285
"struct cli *cli);\nvoid VRT_Vmod_Fini(void **hdl);\n"
286
"\nstruct vmod_priv;\ntypedef void vmod_priv_free_f(void *);\n"
287
"struct vmod_priv {\n\tvoid\t\t\t*priv;\n\tvmod_priv_free_f\t"
288
"*free;\n};\n\ntypedef int vmod_init_f(struct vmod_priv *, "
289
" const struct VCL_conf *);\n\nstatic inline void\n"
290
"vmod_priv_fini(const struct vmod_priv *p)\n{\n\n\tif (p->priv "
291
"!= (void*)0 && p->free != (void*)0)\n\t\tp->free(p->priv);\n"
292
"}\n\n/* Stevedore related functions */\nint VRT_Stv(const "
293
"char *nm);\n\n/* Convert things to string */\n\nchar *VRT_IP_str"
294
"ing(const struct sess *sp, const struct sockaddr_storage *sa);\n"
295
"char *VRT_int_string(const struct sess *sp, int);\n"
296
"char *VRT_double_string(const struct sess *sp, double);\n"
297
"char *VRT_time_string(const struct sess *sp, double);\n"
298
"const char *VRT_bool_string(const struct sess *sp, unsigned);\n"
299
"const char *VRT_backend_string(const struct sess *sp, const "
300
"struct director *d);\n\n#define VRT_done(sp, hand)\t\t\t\\\n"
301
"\tdo {\t\t\t\t\t\\\n\t\tVRT_handling(sp, hand);\t\t\\\n"
302
"\t\treturn (1);\t\t\t\\\n\t} while (0)\n\nconst char *VRT_WrkStr"
303
"ing(const struct sess *sp, const char *p, ...);\n"
305
306
/* ../include/vrt_obj.h */