2 * Copyright (c) 2000, 2001, 2003-2005, 2011, 2012, 2015, 2019 Apple Inc. All rights reserved.
4 * @APPLE_LICENSE_HEADER_START@
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. Please obtain a copy of the License at
10 * http://www.opensource.apple.com/apsl/ and read it before using this
13 * The Original Code and all software distributed under the License are
14 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
18 * Please see the License for the specific language governing rights and
19 * limitations under the License.
21 * @APPLE_LICENSE_HEADER_END@
25 * Modification History
27 * June 1, 2001 Allan Nathanson <ajn@apple.com>
28 * - public API conversion
30 * March 24, 2000 Allan Nathanson <ajn@apple.com>
34 #include <mach/std_types.defs>
35 #include <mach/mach_types.defs>
37 subsystem config 20000;
40 import "config_types.h";
43 * serialized XML or UTF8 data (client->server)
45 type xmlData = ^ array [] of MACH_MSG_TYPE_BYTE
49 * serialized XML or UTF8 data (server->client)
51 type xmlDataOut = ^ array [] of MACH_MSG_TYPE_BYTE
58 type task_move_send_t = MACH_MSG_TYPE_MOVE_SEND
64 * CAUTION CAUTION CAUTION CAUTION CAUTION CAUTION
66 * Be very careful when adding, removing, or changing any
67 * of the MiG routes below. Everything tends to work fine
68 * when the SCDynamicStore client code (in the framework)
69 * and SCDynamicStore server code (in configd) are in sync.
70 * But, when the two are NOT in sync as is often the
71 * case when running the iOS Simulator, the conflict can
74 * CAUTION CAUTION CAUTION CAUTION CAUTION CAUTION
79 * Connection management API's
82 routine configopen ( server : mach_port_t;
85 out session : mach_port_move_send_t;
87 ServerAuditToken audit_token : audit_token_t);
89 skip; /* was configclose */
90 skip; /* was configlock */
91 skip; /* was configunlock */
93 skip; /* reserved for future use */
94 skip; /* reserved for future use */
95 skip; /* reserved for future use */
96 skip; /* reserved for future use */
99 * Dynamic store access API's
102 routine configlist ( server : mach_port_t;
105 out list : xmlDataOut, dealloc;
107 ServerAuditToken audit_token : audit_token_t);
109 routine configadd ( server : mach_port_t;
112 out newInstance : int; // no longer used
114 ServerAuditToken audit_token : audit_token_t);
116 routine configget ( server : mach_port_t;
118 out data : xmlDataOut, dealloc;
119 out newInstance : int; // no longer used
121 ServerAuditToken audit_token : audit_token_t);
123 routine configset ( server : mach_port_t;
127 out newInstance : int; // no longer used
129 ServerAuditToken audit_token : audit_token_t);
131 routine configremove ( server : mach_port_t;
134 ServerAuditToken audit_token : audit_token_t);
136 skip; /* was configtouch */
138 routine configadd_s ( server : mach_port_t;
141 out newInstance : int; // no longer used
144 routine confignotify ( server : mach_port_t;
147 ServerAuditToken audit_token : audit_token_t);
149 routine configget_m ( server : mach_port_t;
152 out data : xmlDataOut, dealloc;
154 ServerAuditToken audit_token : audit_token_t);
156 routine configset_m ( server : mach_port_t;
161 ServerAuditToken audit_token : audit_token_t);
167 routine notifyadd ( server : mach_port_t;
172 routine notifyremove ( server : mach_port_t;
177 routine notifychanges ( server : mach_port_t;
178 out list : xmlDataOut, dealloc;
181 routine notifyviaport ( server : mach_port_t;
182 port : mach_port_move_send_t;
183 msgid : mach_msg_id_t; /* must be zero */
186 skip; /* was notifyviafd (passing UNIX domain socket filename) */
188 routine notifyviasignal ( server : mach_port_t;
189 task : task_t /*task_move_send_t*/;
193 routine notifycancel ( server : mach_port_t;
196 routine notifyset ( server : mach_port_t;
201 routine notifyviafd ( server : mach_port_t;
202 fileport : mach_port_move_send_t;
206 skip; /* reserved for future use */
207 skip; /* reserved for future use */
210 * Miscellaneous API's
213 routine snapshot ( server : mach_port_t;
215 ServerAuditToken audit_token : audit_token_t);