31
|
1 |
/*
|
|
2 |
* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
*
|
|
14 |
* Description:
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
|
|
21 |
#ifndef BUS_SELINUX_H
|
|
22 |
#define BUS_SELINUX_H
|
|
23 |
|
|
24 |
#ifndef __SYMBIAN32__
|
|
25 |
#include <dbus/dbus-hash.h>
|
|
26 |
#else
|
|
27 |
#include "dbus-hash.h"
|
|
28 |
#endif //__SYMBIAN32__
|
|
29 |
#include <dbus/dbus-connection.h>
|
|
30 |
#include "services.h"
|
|
31 |
|
|
32 |
dbus_bool_t bus_selinux_pre_init (void);
|
|
33 |
dbus_bool_t bus_selinux_full_init(void);
|
|
34 |
void bus_selinux_shutdown (void);
|
|
35 |
|
|
36 |
dbus_bool_t bus_selinux_enabled (void);
|
|
37 |
|
|
38 |
void bus_selinux_id_ref (BusSELinuxID *sid);
|
|
39 |
void bus_selinux_id_unref (BusSELinuxID *sid);
|
|
40 |
|
|
41 |
DBusHashTable* bus_selinux_id_table_new (void);
|
|
42 |
BusSELinuxID* bus_selinux_id_table_lookup (DBusHashTable *service_table,
|
|
43 |
const DBusString *service_name);
|
|
44 |
dbus_bool_t bus_selinux_id_table_insert (DBusHashTable *service_table,
|
|
45 |
const char *service_name,
|
|
46 |
const char *service_context);
|
|
47 |
void bus_selinux_id_table_print (DBusHashTable *service_table);
|
|
48 |
const char* bus_selinux_get_policy_root (void);
|
|
49 |
|
|
50 |
dbus_bool_t bus_selinux_append_context (DBusMessage *message,
|
|
51 |
BusSELinuxID *context,
|
|
52 |
DBusError *error);
|
|
53 |
|
|
54 |
dbus_bool_t bus_selinux_allows_acquire_service (DBusConnection *connection,
|
|
55 |
BusSELinuxID *service_sid,
|
|
56 |
const char *service_name,
|
|
57 |
DBusError *error);
|
|
58 |
|
|
59 |
dbus_bool_t bus_selinux_allows_send (DBusConnection *sender,
|
|
60 |
DBusConnection *proposed_recipient,
|
|
61 |
const char *msgtype, /* Supplementary audit data */
|
|
62 |
const char *interface,
|
|
63 |
const char *member,
|
|
64 |
const char *error_name,
|
|
65 |
const char *destination,
|
|
66 |
DBusError *error);
|
|
67 |
|
|
68 |
BusSELinuxID* bus_selinux_init_connection_id (DBusConnection *connection,
|
|
69 |
DBusError *error);
|
|
70 |
|
|
71 |
|
|
72 |
|
|
73 |
#endif /* BUS_SELINUX_H */
|