1 /* -*- Mode: C; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
2 /* NetworkManager -- Network link manager
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License along
15 * with this program; if not, write to the Free Software Foundation, Inc.,
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
18 * Copyright (C) 2008 - 2012 Red Hat, Inc.
21 #define NMD_SCRIPT_DIR_DEFAULT NMCONFDIR "/dispatcher.d"
22 #define NMD_SCRIPT_DIR_PRE_UP NMD_SCRIPT_DIR_DEFAULT "/pre-up.d"
23 #define NMD_SCRIPT_DIR_PRE_DOWN NMD_SCRIPT_DIR_DEFAULT "/pre-down.d"
24 #define NMD_SCRIPT_DIR_NO_WAIT NMD_SCRIPT_DIR_DEFAULT "/no-wait.d"
26 #define NM_DISPATCHER_DBUS_SERVICE "org.freedesktop.nm_dispatcher"
27 #define NM_DISPATCHER_DBUS_INTERFACE "org.freedesktop.nm_dispatcher"
28 #define NM_DISPATCHER_DBUS_PATH "/org/freedesktop/nm_dispatcher"
30 #define NMD_CONNECTION_PROPS_PATH "path"
31 #define NMD_CONNECTION_PROPS_FILENAME "filename"
32 #define NMD_CONNECTION_PROPS_EXTERNAL "external"
34 #define NMD_DEVICE_PROPS_INTERFACE "interface"
35 #define NMD_DEVICE_PROPS_IP_INTERFACE "ip-interface"
36 #define NMD_DEVICE_PROPS_TYPE "type"
37 #define NMD_DEVICE_PROPS_STATE "state"
38 #define NMD_DEVICE_PROPS_PATH "path"
41 #define NMD_ACTION_HOSTNAME "hostname"
42 #define NMD_ACTION_PRE_UP "pre-up"
43 #define NMD_ACTION_UP "up"
44 #define NMD_ACTION_PRE_DOWN "pre-down"
45 #define NMD_ACTION_DOWN "down"
46 #define NMD_ACTION_VPN_PRE_UP "vpn-pre-up"
47 #define NMD_ACTION_VPN_UP "vpn-up"
48 #define NMD_ACTION_VPN_PRE_DOWN "vpn-pre-down"
49 #define NMD_ACTION_VPN_DOWN "vpn-down"
50 #define NMD_ACTION_DHCP4_CHANGE "dhcp4-change"
51 #define NMD_ACTION_DHCP6_CHANGE "dhcp6-change"
54 DISPATCH_RESULT_UNKNOWN = 0,
55 DISPATCH_RESULT_SUCCESS = 1,
56 DISPATCH_RESULT_EXEC_FAILED = 2,
57 DISPATCH_RESULT_FAILED = 3,
58 DISPATCH_RESULT_TIMEOUT = 4,