blob: 4bf902a28da5893730c88b58206f23c39c592614 [file] [log] [blame]
MG Mud User88f12472016-06-24 23:31:02 +02001SYNOPSIS
2 #include <sys/driver_hooks.h>
3
4 set_driver_hook(H_CLONE_UIDS, value)
5
6 <value> being:
7
8 mixed <closure>(object blueprint, string objectname)
9
10DESCRIPTION
11 Mandatory hooks to determine the uid and euid of cloned
12 objects. Hook settings can be any closure.
13
14 When an object is cloned, the H_CLONE_UIDS hook is called with
15 the blueprint object as first and the clone's designated name
16 as second argument. The new object already exists, but has 0
17 uids.
18
19 For the result, the following possibilities exist (<num> is
20 a non-zero number, <no-string> is anything but a string):
21
22 "<uid>" -> uid = "<uid>", euid = "<uid>"
23 ({ "<uid>", "<euid>" }) -> uid = "<uid>", euid = "<euid>"
24 ({ "<uid>", <no-string> }) -> uid = "<uid>", euid = 0
25
26 If strict-euids is not active, the following results are
27 possible, too:
28
29 <num> -> uid = 0, euid = 0
30 ({ <num>, "<euid>" }) -> uid = 0, euid = "<euid>"
31 ({ <num>, <no-string> }) -> uid = 0, euid = 0
32
33HISTORY
34
35SEE ALSO
36 hooks(C), uids(C), load_uids(H)