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
|
#ifndef _X_AUTHORITY_H_
#define _X_AUTHORITY_H_
#include <glib-object.h>
#include <gio/gio.h>
G_BEGIN_DECLS
enum
{
XAUTH_FAMILY_INTERNET = 0,
XAUTH_FAMILY_DECNET = 1,
XAUTH_FAMILY_CHAOS = 2,
XAUTH_FAMILY_SERVER_INTERPRETED = 5,
XAUTH_FAMILY_INTERNET6 = 6,
XAUTH_FAMILY_LOCALHOST = 252,
XAUTH_FAMILY_KRB5_PRINCIPAL = 253,
XAUTH_FAMILY_NETNAME = 254,
XAUTH_FAMILY_LOCAL = 256,
XAUTH_FAMILY_WILD = 65535
};
typedef struct XAuthorityPrivate XAuthorityPrivate;
typedef struct
{
GObjectClass parent_instance;
XAuthorityPrivate *priv;
} XAuthority;
typedef struct
{
GObjectClass parent_class;
} XAuthorityClass;
typedef struct XAuthorityRecordPrivate XAuthorityRecordPrivate;
typedef struct
{
GObjectClass parent_instance;
XAuthorityRecordPrivate *priv;
} XAuthorityRecord;
typedef struct
{
GObjectClass parent_class;
} XAuthorityRecordClass;
GType x_authority_get_type (void);
GType x_authority_record_get_type (void);
XAuthority *x_authority_new (void);
gboolean x_authority_load (XAuthority *authority, const gchar *filename, GError **error);
XAuthorityRecord *x_authority_match_local (XAuthority *authority, const gchar *authorization_name);
XAuthorityRecord *x_authority_match_localhost (XAuthority *authority, const gchar *authorization_name);
XAuthorityRecord *x_authority_match_inet (XAuthority *authority, GInetAddress *address, const gchar *authorization_name);
guint16 x_authority_record_get_authorization_data_length (XAuthorityRecord *record);
const guint8 *x_authority_record_get_authorization_data (XAuthorityRecord *record);
gboolean x_authority_record_check_cookie (XAuthorityRecord *record, const guint8 *cookie_data, guint16 cookie_data_length);
G_END_DECLS
#endif /* _X_AUTHORITY_H_ */
|