データ構造 | |
struct | rid_name_map |
struct | sid_name_map_info |
関数 | |
BOOL | sid_check_is_wellknown_domain (const DOM_SID *sid, const char **name) |
BOOL | sid_check_is_in_wellknown_domain (const DOM_SID *sid) |
BOOL | lookup_wellknown_sid (TALLOC_CTX *mem_ctx, const DOM_SID *sid, const char **domain, const char **name) |
BOOL | lookup_wellknown_name (TALLOC_CTX *mem_ctx, const char *name, DOM_SID *sid, const char **domain) |
変数 | |
static struct rid_name_map | everyone_users [] |
static struct rid_name_map | creator_owner_users [] |
static struct rid_name_map | nt_authority_users [] |
static struct sid_name_map_info | special_domains [] |
util_wellknown.c の 73 行で定義されています。
参照先 sid_name_map_info::sid・sid_equal()・special_domains.
参照元 check_dom_sid_to_level()・lookup_as_domain()・lookup_rids()・sid_check_is_in_wellknown_domain().
00074 { 00075 int i; 00076 00077 for (i=0; special_domains[i].sid != NULL; i++) { 00078 if (sid_equal(sid, special_domains[i].sid)) { 00079 if (name != NULL) { 00080 *name = special_domains[i].name; 00081 } 00082 return True; 00083 } 00084 } 00085 return False; 00086 }
util_wellknown.c の 88 行で定義されています。
参照先 sid_name_map_info::sid・sid_check_is_wellknown_domain()・sid_copy()・sid_split_rid().
参照元 find_idmap_domain_from_sid()・idmap_can_map()・legacy_sid_to_gid().
00089 { 00090 DOM_SID dom_sid; 00091 uint32 rid; 00092 00093 sid_copy(&dom_sid, sid); 00094 sid_split_rid(&dom_sid, &rid); 00095 00096 return sid_check_is_wellknown_domain(&dom_sid, NULL); 00097 }
BOOL lookup_wellknown_sid | ( | TALLOC_CTX * | mem_ctx, | |
const DOM_SID * | sid, | |||
const char ** | domain, | |||
const char ** | name | |||
) |
util_wellknown.c の 103 行で定義されています。
参照先 sid_name_map_info::known_users・rid_name_map::name・sid_name_map_info::sid・sid_copy()・sid_equal()・sid_split_rid()・sid_string_static()・special_domains・talloc_strdup().
参照元 lookup_rids().
00105 { 00106 int i; 00107 DOM_SID dom_sid; 00108 uint32 rid; 00109 const struct rid_name_map *users = NULL; 00110 00111 sid_copy(&dom_sid, sid); 00112 if (!sid_split_rid(&dom_sid, &rid)) { 00113 DEBUG(2, ("Could not split rid from SID\n")); 00114 return False; 00115 } 00116 00117 for (i=0; special_domains[i].sid != NULL; i++) { 00118 if (sid_equal(&dom_sid, special_domains[i].sid)) { 00119 *domain = talloc_strdup(mem_ctx, 00120 special_domains[i].name); 00121 users = special_domains[i].known_users; 00122 break; 00123 } 00124 } 00125 00126 if (users == NULL) { 00127 DEBUG(10, ("SID %s is no special sid\n", 00128 sid_string_static(sid))); 00129 return False; 00130 } 00131 00132 for (i=0; users[i].name != NULL; i++) { 00133 if (rid == users[i].rid) { 00134 *name = talloc_strdup(mem_ctx, users[i].name); 00135 return True; 00136 } 00137 } 00138 00139 DEBUG(10, ("RID of special SID %s not found\n", 00140 sid_string_static(sid))); 00141 00142 return False; 00143 }
BOOL lookup_wellknown_name | ( | TALLOC_CTX * | mem_ctx, | |
const char * | name, | |||
DOM_SID * | sid, | |||
const char ** | domain | |||
) |
util_wellknown.c の 149 行で定義されています。
参照先 rid_name_map::rid・sid_name_map_info::sid・sid_append_rid()・sid_copy()・special_domains・strequal()・talloc_strdup().
参照元 lookup_name().
00151 { 00152 int i, j; 00153 00154 DEBUG(10,("map_name_to_wellknown_sid: looking up %s\n", name)); 00155 00156 for (i=0; special_domains[i].sid != NULL; i++) { 00157 const struct rid_name_map *users = 00158 special_domains[i].known_users; 00159 00160 if (users == NULL) 00161 continue; 00162 00163 for (j=0; users[j].name != NULL; j++) { 00164 if ( strequal(users[j].name, name) ) { 00165 sid_copy(sid, special_domains[i].sid); 00166 sid_append_rid(sid, users[j].rid); 00167 *domain = talloc_strdup( 00168 mem_ctx, special_domains[i].name); 00169 return True; 00170 } 00171 } 00172 } 00173 00174 return False; 00175 }
struct rid_name_map everyone_users[] [static] |
struct rid_name_map creator_owner_users[] [static] |
初期値:
{ { 0, "Creator Owner" }, { 1, "Creator Group" }, { 0, NULL}}
util_wellknown.c の 42 行で定義されています。
struct rid_name_map nt_authority_users[] [static] |
初期値:
{ { 1, "Dialup" }, { 2, "Network"}, { 3, "Batch"}, { 4, "Interactive"}, { 6, "Service"}, { 7, "AnonymousLogon"}, { 8, "Proxy"}, { 9, "ServerLogon"}, { 10, "Self"}, { 11, "Authenticated Users"}, { 12, "Restricted"}, { 13, "Terminal Server User"}, { 14, "Remote Interactive Logon"}, { 15, "This Organization"}, { 18, "SYSTEM"}, { 19, "Local Service"}, { 20, "Network Service"}, { 0, NULL}}
util_wellknown.c の 47 行で定義されています。
struct sid_name_map_info special_domains[] [static] |
初期値:
{ { &global_sid_World_Domain, "", everyone_users }, { &global_sid_Creator_Owner_Domain, "", creator_owner_users }, { &global_sid_NT_Authority, "NT Authority", nt_authority_users }, { NULL, NULL, NULL }}
util_wellknown.c の 67 行で定義されています。
参照元 lookup_wellknown_name()・lookup_wellknown_sid()・sid_check_is_wellknown_domain().