]> git.ipfire.org Git - thirdparty/systemd.git/blame - src/core/dbus-execute.h
hashmap: be a bit more conservative with pre-allocating hash tables and items
[thirdparty/systemd.git] / src / core / dbus-execute.h
CommitLineData
03467c88 1/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
4139c1b2 2
c2f1db8f 3#pragma once
4139c1b2
LP
4
5/***
6 This file is part of systemd.
7
8 Copyright 2010 Lennart Poettering
9
10 systemd is free software; you can redistribute it and/or modify it
5430f7f2
LP
11 under the terms of the GNU Lesser General Public License as published by
12 the Free Software Foundation; either version 2.1 of the License, or
4139c1b2
LP
13 (at your option) any later version.
14
15 systemd is distributed in the hope that it will be useful, but
16 WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
5430f7f2 18 Lesser General Public License for more details.
4139c1b2 19
5430f7f2 20 You should have received a copy of the GNU Lesser General Public License
4139c1b2
LP
21 along with systemd; If not, see <http://www.gnu.org/licenses/>.
22***/
23
24#include <dbus/dbus.h>
25
26#include "manager.h"
d200735e 27#include "dbus-common.h"
4139c1b2 28
b58b4116
LP
29#define BUS_EXEC_STATUS_INTERFACE(prefix) \
30 " <property name=\"" prefix "StartTimestamp\" type=\"t\" access=\"read\"/>\n" \
b21a0ef8 31 " <property name=\"" prefix "StartTimestampMonotonic\" type=\"t\" access=\"read\"/>\n" \
b58b4116 32 " <property name=\"" prefix "ExitTimestamp\" type=\"t\" access=\"read\"/>\n" \
b21a0ef8 33 " <property name=\"" prefix "ExitTimestampMonotonic\" type=\"t\" access=\"read\"/>\n" \
b58b4116
LP
34 " <property name=\"" prefix "PID\" type=\"u\" access=\"read\"/>\n" \
35 " <property name=\"" prefix "Code\" type=\"i\" access=\"read\"/>\n" \
36 " <property name=\"" prefix "Status\" type=\"i\" access=\"read\"/>\n"
37
4139c1b2 38#define BUS_EXEC_CONTEXT_INTERFACE \
4288f619 39 " <property name=\"Environment\" type=\"as\" access=\"read\"/>\n" \
92dd3633 40 " <property name=\"EnvironmentFiles\" type=\"a(sb)\" access=\"read\"/>\n" \
4288f619 41 " <property name=\"UMask\" type=\"u\" access=\"read\"/>\n" \
82c121a4
LP
42 " <property name=\"LimitCPU\" type=\"t\" access=\"read\"/>\n" \
43 " <property name=\"LimitFSIZE\" type=\"t\" access=\"read\"/>\n" \
44 " <property name=\"LimitDATA\" type=\"t\" access=\"read\"/>\n" \
45 " <property name=\"LimitSTACK\" type=\"t\" access=\"read\"/>\n" \
46 " <property name=\"LimitCORE\" type=\"t\" access=\"read\"/>\n" \
47 " <property name=\"LimitRSS\" type=\"t\" access=\"read\"/>\n" \
48 " <property name=\"LimitNOFILE\" type=\"t\" access=\"read\"/>\n" \
49 " <property name=\"LimitAS\" type=\"t\" access=\"read\"/>\n" \
50 " <property name=\"LimitNPROC\" type=\"t\" access=\"read\"/>\n" \
51 " <property name=\"LimitMEMLOCK\" type=\"t\" access=\"read\"/>\n" \
52 " <property name=\"LimitLOCKS\" type=\"t\" access=\"read\"/>\n" \
53 " <property name=\"LimitSIGPENDING\" type=\"t\" access=\"read\"/>\n" \
54 " <property name=\"LimitMSGQUEUE\" type=\"t\" access=\"read\"/>\n" \
55 " <property name=\"LimitNICE\" type=\"t\" access=\"read\"/>\n" \
56 " <property name=\"LimitRTPRIO\" type=\"t\" access=\"read\"/>\n" \
57 " <property name=\"LimitRTTIME\" type=\"t\" access=\"read\"/>\n" \
4288f619
LP
58 " <property name=\"WorkingDirectory\" type=\"s\" access=\"read\"/>\n" \
59 " <property name=\"RootDirectory\" type=\"s\" access=\"read\"/>\n" \
dd6c17b1 60 " <property name=\"OOMScoreAdjust\" type=\"i\" access=\"read\"/>\n" \
82c121a4
LP
61 " <property name=\"Nice\" type=\"i\" access=\"read\"/>\n" \
62 " <property name=\"IOScheduling\" type=\"i\" access=\"read\"/>\n" \
63 " <property name=\"CPUSchedulingPolicy\" type=\"i\" access=\"read\"/>\n" \
64 " <property name=\"CPUSchedulingPriority\" type=\"i\" access=\"read\"/>\n" \
65 " <property name=\"CPUAffinity\" type=\"ay\" access=\"read\"/>\n" \
a38d1d28 66 " <property name=\"TimerSlackNSec\" type=\"t\" access=\"read\"/>\n" \
4288f619
LP
67 " <property name=\"CPUSchedulingResetOnFork\" type=\"b\" access=\"read\"/>\n" \
68 " <property name=\"NonBlocking\" type=\"b\" access=\"read\"/>\n" \
69 " <property name=\"StandardInput\" type=\"s\" access=\"read\"/>\n" \
70 " <property name=\"StandardOutput\" type=\"s\" access=\"read\"/>\n" \
71 " <property name=\"StandardError\" type=\"s\" access=\"read\"/>\n" \
72 " <property name=\"TTYPath\" type=\"s\" access=\"read\"/>\n" \
beaccad0
LP
73 " <property name=\"TTYReset\" type=\"b\" access=\"read\"/>\n" \
74 " <property name=\"TTYVHangup\" type=\"b\" access=\"read\"/>\n" \
75 " <property name=\"TTYVTDisallocate\" type=\"b\" access=\"read\"/>\n" \
4288f619
LP
76 " <property name=\"SyslogPriority\" type=\"i\" access=\"read\"/>\n" \
77 " <property name=\"SyslogIdentifier\" type=\"s\" access=\"read\"/>\n" \
74922904 78 " <property name=\"SyslogLevelPrefix\" type=\"b\" access=\"read\"/>\n" \
82c121a4 79 " <property name=\"Capabilities\" type=\"s\" access=\"read\"/>\n" \
4288f619 80 " <property name=\"SecureBits\" type=\"i\" access=\"read\"/>\n" \
7c3d67ef 81 " <property name=\"CapabilityBoundingSet\" type=\"t\" access=\"read\"/>\n" \
4288f619
LP
82 " <property name=\"User\" type=\"s\" access=\"read\"/>\n" \
83 " <property name=\"Group\" type=\"s\" access=\"read\"/>\n" \
df1f0afe 84 " <property name=\"SupplementaryGroups\" type=\"as\" access=\"read\"/>\n" \
5b6319dc 85 " <property name=\"TCPWrapName\" type=\"s\" access=\"read\"/>\n" \
82c121a4
LP
86 " <property name=\"PAMName\" type=\"s\" access=\"read\"/>\n" \
87 " <property name=\"ReadWriteDirectories\" type=\"as\" access=\"read\"/>\n" \
88 " <property name=\"ReadOnlyDirectories\" type=\"as\" access=\"read\"/>\n" \
89 " <property name=\"InaccessibleDirectories\" type=\"as\" access=\"read\"/>\n" \
90 " <property name=\"MountFlags\" type=\"t\" access=\"read\"/>\n" \
91 " <property name=\"PrivateTmp\" type=\"b\" access=\"read\"/>\n" \
92dd3633 92 " <property name=\"PrivateNetwork\" type=\"b\" access=\"read\"/>\n" \
2e22afe9 93 " <property name=\"SameProcessGroup\" type=\"b\" access=\"read\"/>\n" \
64747e2d 94 " <property name=\"UtmpIdentifier\" type=\"s\" access=\"read\"/>\n" \
8351ceae
LP
95 " <property name=\"IgnoreSIGPIPE\" type=\"b\" access=\"read\"/>\n" \
96 " <property name=\"NoNewPrivileges\" type=\"b\" access=\"read\"/>\n" \
97 " <property name=\"SystemCallFilter\" type=\"au\" access=\"read\"/>\n"
fe68089d
LP
98
99#define BUS_EXEC_COMMAND_INTERFACE(name) \
b708e7ce 100 " <property name=\"" name "\" type=\"a(sasbttuii)\" access=\"read\"/>\n"
4139c1b2 101
d200735e 102extern const BusProperty bus_exec_context_properties[];
4139c1b2 103
d200735e
MS
104#define BUS_EXEC_COMMAND_PROPERTY(name, command, indirect) \
105 { name, bus_execute_append_command, "a(sasbttttuii)", (command), (indirect), NULL }
fe68089d 106
bfebab7f 107int bus_execute_append_command(DBusMessageIter *u, const char *property, void *data);