This file is indexed.

/usr/include/libzia/zhttp.h is in libzia-dev 4.06-2+b1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
/*
    zhttp.h - http client
    Copyright (C) 2012 Ladislav Vaiz <ok1zia@nagano.cz>

    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
    version 2 as published by the Free Software Foundation.

*/

#ifndef __ZHTTP_H
#define __ZHTTP_H

#include <zasyncdns.h>
#include <zbinbuf.h>
#include <zselect.h>

#include <glib.h>
	
enum zhttp_state{
	ZHTTPST_NEW,
	ZHTTPST_DNS,
	ZHTTPST_CONNECTING,
	ZHTTPST_REQUEST,
	ZHTTPST_HEADER,
	ZHTTPST_DATA,
	ZHTTPST_DONE,
	ZHTTPST_ERROR
};

struct zhttp{
    void (*callback)(struct zhttp *);
	void *arg;
    struct zbinbuf *request;
    struct zbinbuf *response;
    struct zasyncdns *adns; 
	struct zselect *zsel;
	char *url;
    char *errorstr;
    char *server;
	char *serveraddr;
    int port;
    char *page;
    int sock;
	int status; // HTTP status
	int dataofs;
	int sent; // sent data
	int origreqlen; // original length of request
	enum zhttp_state state;
	GPtrArray *posts;
	GHashTable *cookies;
	char *datastr; // decoded data, freeed with object
};

struct zhttp_post_var{
	char *name;
	char *value;
	char *filename;
	char *localfilename;
};

struct zhttp *zhttp_init(void);
void zhttp_free(struct zhttp *http);
#define zhttp_free0(http) { zhttp_free(http); http = NULL; }

void zhttp_get(struct zhttp *http, struct zselect *zsel, const char *url, void (*callback)(struct zhttp *), void *arg);
void zhttp_post_free(struct zhttp *http);
void zhttp_post_add(struct zhttp *http, const char *name, const char *value);
void zhttp_post_add_file_mem(struct zhttp *http, const char *name, const char *filename, const char *value);
void zhttp_post_add_file_disk(struct zhttp *http, const char *name, const char *filename, const char *localfilename);
void zhttp_post(struct zhttp *http, struct zselect *zsel, const char *url, void (*callback)(struct zhttp *), void *arg);


void zhttp_status(struct zhttp *http, GString *gs);
int zhttp_write_data(struct zhttp *http, const char *filename);

void zhttp_store_cookies(struct zhttp *http, const char *data, int len);

char *http_get_data(struct zhttp *http);



#endif