-/*
+/*
Unix SMB/CIFS implementation.
Password and authentication handling
Copyright (C) Jeremy Allison 1996-2002
int i;
uchar raw_sid_data[12];
- ZERO_STRUCTP(sid);
+ *sid = (struct dom_sid) {
+ .sid_rev_num = 1,
+ .id_auth[5] = 5,
+ };
- sid->sid_rev_num = 1;
- sid->id_auth[5] = 5;
- sid->num_auths = 0;
sid->sub_auths[sid->num_auths++] = 21;
generate_random_buffer(raw_sid_data, 12);
}
return sam_sid;
-}
+}
/* return our global_sam_sid */
struct dom_sid *get_global_sam_sid(void)
* memory for global_sam_sid is allocated in
* pdb_generate_sam_sid() as needed
*
- * Note: this is garded by a transaction
+ * Note: this is guarded by a transaction
* to prevent races on startup which
* can happen with some dbwrap backends
*/
return global_sam_sid;
}
-/**
- * Force get_global_sam_sid to requery the backends
+/**
+ * Force get_global_sam_sid to requery the backends
*/
void reset_global_sam_sid(void)
{
/*****************************************************************
Check if the SID is our sam SID (S-1-5-21-x-y-z).
-*****************************************************************/
+*****************************************************************/
bool sid_check_is_our_sam(const struct dom_sid *sid)
{
/*****************************************************************
Check if the SID is our domain SID (S-1-5-21-x-y-z).
-*****************************************************************/
+*****************************************************************/
-bool sid_check_is_in_our_domain(const struct dom_sid *sid)
+bool sid_check_is_in_our_sam(const struct dom_sid *sid)
{
struct dom_sid dom_sid;