2 Unix SMB/CIFS implementation.
4 Winbind daemon - sid related functions
6 Copyright (C) Tim Potter 2000
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 3 of the License, or
11 (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>.
26 #define DBGC_CLASS DBGC_WINBIND
28 static void set_hwm_recv(void *private_data, bool success)
30 struct winbindd_cli_state *state =
31 talloc_get_type_abort(private_data, struct winbindd_cli_state);
34 DEBUG(5, ("Could not set sid mapping\n"));
42 void winbindd_set_hwm(struct winbindd_cli_state *state)
46 DEBUG(3, ("[%5lu]: set hwm\n", (unsigned long)state->pid));
48 if ( ! state->privileged) {
49 DEBUG(0, ("Only root is allowed to set mappings!\n"));
54 xid.id = state->request->data.dual_idmapset.id;
55 xid.type = state->request->data.dual_idmapset.type;
57 winbindd_set_hwm_async(state->mem_ctx, &xid, set_hwm_recv, state);