WERROR (*create_subkey)(const char *key, const char *subkey);
WERROR (*delete_subkey)(const char *key, const char *subkey, bool lazy);
bool (*store_values)( const char *key, struct regval_ctr *val );
- bool (*reg_access_check)( const char *keyname, uint32 requested,
- uint32 *granted,
+ bool (*reg_access_check)( const char *keyname, uint32_t requested,
+ uint32_t *granted,
const struct security_token *token );
WERROR (*get_secdesc)(TALLOC_CTX *mem_ctx, const char *key,
struct security_descriptor **psecdesc);
/* structure to store the registry handles */
struct registry_key_handle {
- uint32 type;
+ uint32_t type;
char *name; /* full name of registry key */
- uint32 access_granted;
+ uint32_t access_granted;
struct registry_ops *ops;
};
fstring netbios_name;
fstring remote_machine;
fstring id_str;
- uint32 id_num;
+ uint32_t id_num;
struct server_id pid;
fstring ip_addr_str;
time_t connect_start;
struct registry_key *parent,
const char *name,
const struct security_token *token,
- uint32 access_desired,
+ uint32_t access_desired,
struct registry_key **pregkey)
{
WERROR result = WERR_OK;
}
WERROR reg_openhive(TALLOC_CTX *mem_ctx, const char *hive,
- uint32 desired_access,
+ uint32_t desired_access,
const struct security_token *token,
struct registry_key **pkey)
{
**********************************************************************/
WERROR reg_openkey(TALLOC_CTX *mem_ctx, struct registry_key *parent,
- const char *name, uint32 desired_access,
+ const char *name, uint32_t desired_access,
struct registry_key **pkey)
{
struct registry_key *direct_parent = parent;
}
WERROR reg_enumkey(TALLOC_CTX *mem_ctx, struct registry_key *key,
- uint32 idx, char **name, NTTIME *last_write_time)
+ uint32_t idx, char **name, NTTIME *last_write_time)
{
WERROR err;
}
WERROR reg_enumvalue(TALLOC_CTX *mem_ctx, struct registry_key *key,
- uint32 idx, char **pname, struct registry_value **pval)
+ uint32_t idx, char **pname, struct registry_value **pval)
{
struct registry_value *val;
struct regval_blob *blob;
static WERROR reg_enumvalue_nocachefill(TALLOC_CTX *mem_ctx,
struct registry_key *key,
- uint32 idx, char **pname,
+ uint32_t idx, char **pname,
struct registry_value **pval)
{
struct registry_value *val;
const char *name, struct registry_value **pval)
{
WERROR err;
- uint32 i;
+ uint32_t i;
if (!(key->key->access_granted & KEY_QUERY_VALUE)) {
return WERR_ACCESS_DENIED;
uint32_t *max_valbufsize, uint32_t *secdescsize,
NTTIME *last_changed_time)
{
- uint32 i, max_size;
+ uint32_t i, max_size;
size_t max_len;
TALLOC_CTX *mem_ctx;
WERROR err;
}
WERROR reg_createkey(TALLOC_CTX *ctx, struct registry_key *parent,
- const char *subkeypath, uint32 desired_access,
+ const char *subkeypath, uint32_t desired_access,
struct registry_key **pkey,
enum winreg_CreateAction *paction)
{
WERROR werr = WERR_OK;
struct registry_key *key;
char *subkey_name = NULL;
- uint32 i;
+ uint32_t i;
TALLOC_CTX *mem_ctx = talloc_stackframe();
DEBUG(5, ("reg_deletekey_recursive_internal: deleting '%s' from '%s'\n",
#define _REG_API_H
WERROR reg_openhive(TALLOC_CTX *mem_ctx, const char *hive,
- uint32 desired_access,
+ uint32_t desired_access,
const struct security_token *token,
struct registry_key **pkey);
WERROR reg_openkey(TALLOC_CTX *mem_ctx, struct registry_key *parent,
- const char *name, uint32 desired_access,
+ const char *name, uint32_t desired_access,
struct registry_key **pkey);
WERROR reg_enumkey(TALLOC_CTX *mem_ctx, struct registry_key *key,
- uint32 idx, char **name, NTTIME *last_write_time);
+ uint32_t idx, char **name, NTTIME *last_write_time);
WERROR reg_enumvalue(TALLOC_CTX *mem_ctx, struct registry_key *key,
- uint32 idx, char **pname, struct registry_value **pval);
+ uint32_t idx, char **pname, struct registry_value **pval);
WERROR reg_queryvalue(TALLOC_CTX *mem_ctx, struct registry_key *key,
const char *name, struct registry_value **pval);
WERROR reg_querymultiplevalues(TALLOC_CTX *mem_ctx,
uint32_t *max_valbufsize, uint32_t *secdescsize,
NTTIME *last_changed_time);
WERROR reg_createkey(TALLOC_CTX *ctx, struct registry_key *parent,
- const char *subkeypath, uint32 desired_access,
+ const char *subkeypath, uint32_t desired_access,
struct registry_key **pkey,
enum winreg_CreateAction *paction);
WERROR reg_deletekey(struct registry_key *parent, const char *path);
* Utility function to open a complete registry path including the hive prefix.
*/
WERROR reg_open_path(TALLOC_CTX *mem_ctx, const char *orig_path,
- uint32 desired_access, const struct security_token *token,
+ uint32_t desired_access, const struct security_token *token,
struct registry_key **pkey)
{
struct registry_key *hive, *key;
*/
WERROR reg_create_path(TALLOC_CTX *mem_ctx, const char *orig_path,
- uint32 desired_access,
+ uint32_t desired_access,
const struct security_token *token,
enum winreg_CreateAction *paction,
struct registry_key **pkey)
* Utility function to open a complete registry path including the hive prefix.
*/
WERROR reg_open_path(TALLOC_CTX *mem_ctx, const char *orig_path,
- uint32 desired_access, const struct security_token *token,
+ uint32_t desired_access, const struct security_token *token,
struct registry_key **pkey);
WERROR reg_create_path(TALLOC_CTX *mem_ctx, const char *orig_path,
- uint32 desired_access,
+ uint32_t desired_access,
const struct security_token *token,
enum winreg_CreateAction *paction,
struct registry_key **pkey);
struct builtin_regkey_value {
const char *path;
const char *valuename;
- uint32 type;
+ uint32_t type;
union {
const char *string;
- uint32 dw_value;
+ uint32_t dw_value;
} data;
};
case REG_DWORD:
regval_ctr_addvalue(ctr, value->valuename, REG_DWORD,
(uint8_t *)&value->data.dw_value,
- sizeof(uint32));
+ sizeof(uint32_t));
break;
case REG_SZ:
TDB_DATA dbuf;
uint8 *buffer = NULL;
int i = 0;
- uint32 len, buflen;
- uint32 num_subkeys = regsubkey_ctr_numkeys(ctr);
+ uint32_t len, buflen;
+ uint32_t num_subkeys = regsubkey_ctr_numkeys(ctr);
char *keyname = NULL;
TALLOC_CTX *ctx = talloc_stackframe();
WERROR werr;
WERROR werr;
uint32_t num_items;
uint8 *buf;
- uint32 buflen, len;
+ uint32_t buflen, len;
int i;
fstring subkeyname;
TALLOC_CTX *frame = talloc_stackframe();
static int regdb_unpack_values(struct regval_ctr *values, uint8 *buf, int buflen)
{
int len = 0;
- uint32 type;
+ uint32_t type;
fstring valuename;
- uint32 size;
+ uint32_t size;
uint8 *data_p;
- uint32 num_values = 0;
+ uint32_t num_values = 0;
int i;
/* loop and unpack the rest of the registry values */
static int hkpt_params_fetch_values(const char *key, struct regval_ctr *regvals)
{
- uint32 base_index;
- uint32 buffer_size;
+ uint32_t base_index;
+ uint32_t buffer_size;
char *buffer = NULL;
/* This is ALMOST the same as perflib_009_params, but HKPT has
static int netlogon_params_fetch_values(const char *key, struct regval_ctr *regvals)
{
- uint32 dwValue;
+ uint32_t dwValue;
if (!pdb_get_account_policy(PDB_POLICY_REFUSE_MACHINE_PW_CHANGE, &dwValue)) {
dwValue = 0;
return regdb_ops.store_values(key, val);
}
-static bool smbconf_reg_access_check(const char *keyname, uint32 requested,
- uint32 *granted,
+static bool smbconf_reg_access_check(const char *keyname, uint32_t requested,
+ uint32_t *granted,
const struct security_token *token)
{
if (!security_token_has_privilege(token, SEC_PRIV_DISK_OPERATOR)) {
underlying registry backend
***********************************************************************/
-bool regkey_access_check(struct registry_key_handle *key, uint32 requested,
- uint32 *granted,
+bool regkey_access_check(struct registry_key_handle *key, uint32_t requested,
+ uint32_t *granted,
const struct security_token *token )
{
struct security_descriptor *sec_desc;
int fetch_reg_keys(struct registry_key_handle *key,
struct regsubkey_ctr *subkey_ctr);
int fetch_reg_values(struct registry_key_handle *key, struct regval_ctr *val);
-bool regkey_access_check(struct registry_key_handle *key, uint32 requested,
- uint32 *granted,
+bool regkey_access_check(struct registry_key_handle *key, uint32_t requested,
+ uint32_t *granted,
const struct security_token *token);
WERROR regkey_get_secdesc(TALLOC_CTX *mem_ctx, struct registry_key_handle *key,
struct security_descriptor **psecdesc);
* @return False if allocation fails, otherwise True.
**/
-bool prs_init(prs_struct *ps, uint32 size, TALLOC_CTX *ctx, bool io)
+bool prs_init(prs_struct *ps, uint32_t size, TALLOC_CTX *ctx, bool io)
{
ZERO_STRUCTP(ps);
ps->io = io;
Also depends on the data stream mode (io).
********************************************************************/
-bool prs_grow(prs_struct *ps, uint32 extra_space)
+bool prs_grow(prs_struct *ps, uint32_t extra_space)
{
- uint32 new_size;
+ uint32_t new_size;
ps->grow_size = MAX(ps->grow_size, ps->data_offset + extra_space);
Get the current data size (external interface).
********************************************************************/
-uint32 prs_data_size(prs_struct *ps)
+uint32_t prs_data_size(prs_struct *ps)
{
return ps->buffer_size;
}
Fetch the current offset (external interface).
********************************************************************/
-uint32 prs_offset(prs_struct *ps)
+uint32_t prs_offset(prs_struct *ps)
{
return ps->data_offset;
}
Set the current offset (external interface).
********************************************************************/
-bool prs_set_offset(prs_struct *ps, uint32 offset)
+bool prs_set_offset(prs_struct *ps, uint32_t offset)
{
if ((offset > ps->data_offset)
&& !prs_grow(ps, offset - ps->data_offset)) {
Append the data from a buffer into a parse_struct.
********************************************************************/
-bool prs_copy_data_in(prs_struct *dst, const char *src, uint32 len)
+bool prs_copy_data_in(prs_struct *dst, const char *src, uint32_t len)
{
if (len == 0)
return True;
bool prs_align(prs_struct *ps)
{
- uint32 mod = ps->data_offset & (ps->align-1);
+ uint32_t mod = ps->data_offset & (ps->align-1);
if (ps->align != 0 && mod != 0) {
- uint32 extra_space = (ps->align - mod);
+ uint32_t extra_space = (ps->align - mod);
if(!prs_grow(ps, extra_space))
return False;
memset(&ps->data_p[ps->data_offset], '\0', (size_t)extra_space);
Ensure we can read/write to a given offset.
********************************************************************/
-char *prs_mem_get(prs_struct *ps, uint32 extra_size)
+char *prs_mem_get(prs_struct *ps, uint32_t extra_size)
{
if(UNMARSHALLING(ps)) {
/*
Stream a uint32.
********************************************************************/
-bool prs_uint32(const char *name, prs_struct *ps, int depth, uint32 *data32)
+bool prs_uint32(const char *name, prs_struct *ps, int depth, uint32_t *data32)
{
- char *q = prs_mem_get(ps, sizeof(uint32));
+ char *q = prs_mem_get(ps, sizeof(uint32_t));
if (q == NULL)
return False;
DEBUGADD(5,("%s%04x %s: %08x\n", tab_depth(5,depth), ps->data_offset, name, *data32));
- ps->data_offset += sizeof(uint32);
+ ps->data_offset += sizeof(uint32_t);
return True;
}
bool prs_uint64(const char *name, prs_struct *ps, int depth, uint64 *data64)
{
if (UNMARSHALLING(ps)) {
- uint32 high, low;
+ uint32_t high, low;
if (!prs_uint32(name, ps, depth+1, &low))
return False;
return True;
} else {
- uint32 high = (*data64) >> 32, low = (*data64) & 0xFFFFFFFF;
+ uint32_t high = (*data64) >> 32, low = (*data64) & 0xFFFFFFFF;
return prs_uint32(name, ps, depth+1, &low) &&
prs_uint32(name, ps, depth+1, &high);
}
bool bigendian_data;
uint8 align; /* data alignment */
bool is_dynamic; /* Do we own this memory or not ? */
- uint32 data_offset; /* Current working offset into data. */
- uint32 buffer_size; /* Current allocated size of the buffer. */
- uint32 grow_size; /* size requested via prs_grow() calls */
+ uint32_t data_offset; /* Current working offset into data. */
+ uint32_t buffer_size; /* Current allocated size of the buffer. */
+ uint32_t grow_size; /* size requested via prs_grow() calls */
/* The buffer itself. If "is_dynamic" is true this
* MUST BE TALLOC'ed off mem_ctx. */
char *data_p;
#define RPC_PARSE_ALIGN 4
void prs_debug(prs_struct *ps, int depth, const char *desc, const char *fn_name);
-bool prs_init(prs_struct *ps, uint32 size, TALLOC_CTX *ctx, bool io);
+bool prs_init(prs_struct *ps, uint32_t size, TALLOC_CTX *ctx, bool io);
void prs_mem_free(prs_struct *ps);
char *prs_alloc_mem_(prs_struct *ps, size_t size, unsigned int count);
char *prs_alloc_mem(prs_struct *ps, size_t size, unsigned int count);
TALLOC_CTX *prs_get_mem_context(prs_struct *ps);
-bool prs_grow(prs_struct *ps, uint32 extra_space);
+bool prs_grow(prs_struct *ps, uint32_t extra_space);
char *prs_data_p(prs_struct *ps);
-uint32 prs_data_size(prs_struct *ps);
-uint32 prs_offset(prs_struct *ps);
-bool prs_set_offset(prs_struct *ps, uint32 offset);
-bool prs_copy_data_in(prs_struct *dst, const char *src, uint32 len);
+uint32_t prs_data_size(prs_struct *ps);
+uint32_t prs_offset(prs_struct *ps);
+bool prs_set_offset(prs_struct *ps, uint32_t offset);
+bool prs_copy_data_in(prs_struct *dst, const char *src, uint32_t len);
bool prs_align(prs_struct *ps);
bool prs_align_uint64(prs_struct *ps);
-char *prs_mem_get(prs_struct *ps, uint32 extra_size);
+char *prs_mem_get(prs_struct *ps, uint32_t extra_size);
void prs_switch_type(prs_struct *ps, bool io);
bool prs_uint16(const char *name, prs_struct *ps, int depth, uint16 *data16);
-bool prs_uint32(const char *name, prs_struct *ps, int depth, uint32 *data32);
+bool prs_uint32(const char *name, prs_struct *ps, int depth, uint32_t *data32);
bool prs_uint64(const char *name, prs_struct *ps, int depth, uint64 *data64);
bool prs_uint8s(bool charmode, const char *name, prs_struct *ps, int depth, uint8 *data8s, int len);
/*********************************************************************
*********************************************************************/
-uint32 reg_perfcount_get_base_index(void)
+uint32_t reg_perfcount_get_base_index(void)
{
char *fname;
TDB_CONTEXT *names;
TDB_DATA kbuf, dbuf;
char key[] = "1";
- uint32 retval = 0;
+ uint32_t retval = 0;
char buf[PERFCOUNT_MAX_LEN];
fname = counters_directory(NAMES_DB);
TALLOC_FREE(fname);
memset(buf, 0, PERFCOUNT_MAX_LEN);
memcpy(buf, dbuf.dptr, dbuf.dsize);
- retval = (uint32)atoi(buf);
+ retval = (uint32_t)atoi(buf);
SAFE_FREE(dbuf.dptr);
return retval;
}
/*********************************************************************
*********************************************************************/
-uint32 reg_perfcount_get_last_counter(uint32 base_index)
+uint32_t reg_perfcount_get_last_counter(uint32_t base_index)
{
- uint32 retval;
+ uint32_t retval;
if(base_index == 0)
retval = 0;
/*********************************************************************
*********************************************************************/
-uint32 reg_perfcount_get_last_help(uint32 last_counter)
+uint32_t reg_perfcount_get_last_help(uint32_t last_counter)
{
- uint32 retval;
+ uint32_t retval;
if(last_counter == 0)
retval = 0;
/*********************************************************************
*********************************************************************/
-static uint32 _reg_perfcount_multi_sz_from_tdb(TDB_CONTEXT *tdb,
+static uint32_t _reg_perfcount_multi_sz_from_tdb(TDB_CONTEXT *tdb,
int keyval,
char **retbuf,
- uint32 buffer_size)
+ uint32_t buffer_size)
{
TDB_DATA kbuf, dbuf;
char temp[256];
char *buf1 = *retbuf;
- uint32 working_size = 0;
+ uint32_t working_size = 0;
DATA_BLOB name_index, name;
bool ok;
/*********************************************************************
*********************************************************************/
-uint32 reg_perfcount_get_counter_help(uint32 base_index, char **retbuf)
+uint32_t reg_perfcount_get_counter_help(uint32_t base_index, char **retbuf)
{
char *buf1 = NULL;
- uint32 buffer_size = 0;
+ uint32_t buffer_size = 0;
TDB_CONTEXT *names;
char *fname;
int i;
/*********************************************************************
*********************************************************************/
-uint32 reg_perfcount_get_counter_names(uint32 base_index, char **retbuf)
+uint32_t reg_perfcount_get_counter_names(uint32_t base_index, char **retbuf)
{
char *buf1 = NULL;
- uint32 buffer_size = 0;
+ uint32_t buffer_size = 0;
TDB_CONTEXT *names;
char *fname;
int i;
/*********************************************************************
*********************************************************************/
-static uint32 _reg_perfcount_get_numinst(int objInd, TDB_CONTEXT *names)
+static uint32_t _reg_perfcount_get_numinst(int objInd, TDB_CONTEXT *names)
{
TDB_DATA key, data;
char buf[PERFCOUNT_MAX_LEN];
data = tdb_fetch(names, key);
if(data.dptr == NULL)
- return (uint32)PERF_NO_INSTANCES;
+ return (uint32_t)PERF_NO_INSTANCES;
memset(buf, 0, PERFCOUNT_MAX_LEN);
memcpy(buf, data.dptr, data.dsize);
SAFE_FREE(data.dptr);
- return (uint32)atoi(buf);
+ return (uint32_t)atoi(buf);
}
/*********************************************************************
block->objects[block->NumObjectTypes].NumInstances = _reg_perfcount_get_numinst(num, names);
block->objects[block->NumObjectTypes].counters = NULL;
block->objects[block->NumObjectTypes].instances = NULL;
- block->objects[block->NumObjectTypes].counter_data.ByteLength = sizeof(uint32);
+ block->objects[block->NumObjectTypes].counter_data.ByteLength = sizeof(uint32_t);
block->objects[block->NumObjectTypes].counter_data.data = NULL;
block->objects[block->NumObjectTypes].DetailLevel = PERF_DETAIL_NOVICE;
block->NumObjectTypes+=1;
/*********************************************************************
*********************************************************************/
-static uint32 _reg_perfcount_get_size_field(uint32 CounterType)
+static uint32_t _reg_perfcount_get_size_field(uint32_t CounterType)
{
- uint32 retval;
+ uint32_t retval;
retval = CounterType;
/*********************************************************************
*********************************************************************/
-static uint32 _reg_perfcount_compute_scale(int64_t data)
+static uint32_t _reg_perfcount_compute_scale(int64_t data)
{
int scale = 0;
if(data == 0)
scale++;
}
- return (uint32)scale;
+ return (uint32_t)scale;
}
/*********************************************************************
size_t dsize, padding;
long int data32, dbuf[2];
int64_t data64;
- uint32 counter_size;
+ uint32_t counter_size;
obj->counters[obj->NumCounters].DefaultScale = 0;
dbuf[0] = dbuf[1] = 0;
obj->counter_data.data = talloc_realloc(mem_ctx,
obj->counter_data.data,
uint8,
- obj->counter_data.ByteLength - sizeof(uint32));
+ obj->counter_data.ByteLength - sizeof(uint32_t));
if(obj->counter_data.data == NULL)
return False;
if(dbuf[0] != 0 || dbuf[1] != 0)
{
memcpy((void *)(obj->counter_data.data +
- (obj->counter_data.ByteLength - (sizeof(uint32) + dsize))),
+ (obj->counter_data.ByteLength - (sizeof(uint32_t) + dsize))),
(const void *)dbuf, dsize);
}
else
{
/* Handling PERF_SIZE_VARIABLE_LEN */
memcpy((void *)(obj->counter_data.data +
- (obj->counter_data.ByteLength - (sizeof(uint32) + dsize))),
+ (obj->counter_data.ByteLength - (sizeof(uint32_t) + dsize))),
(const void *)buf, dsize);
}
obj->counters[obj->NumCounters].CounterOffset = obj->counter_data.ByteLength - dsize;
inst->ParentObjectTitleIndex = 0;
inst->ParentObjectTitlePointer = 0;
inst->UniqueID = PERF_NO_UNIQUE_ID;
- inst->NameOffset = 6 * sizeof(uint32);
+ inst->NameOffset = 6 * sizeof(uint32_t);
inst->ByteLength = inst->NameOffset + inst->NameLength;
/* Need to be aligned on a 64-bit boundary here for counter_data */
/*********************************************************************
*********************************************************************/
-static uint32 _reg_perfcount_perf_data_block_fixup(struct PERF_DATA_BLOCK *block, TALLOC_CTX *mem_ctx)
+static uint32_t _reg_perfcount_perf_data_block_fixup(struct PERF_DATA_BLOCK *block, TALLOC_CTX *mem_ctx)
{
int obj, cnt, inst, pad, i;
struct PERF_OBJECT_TYPE *object;
/*********************************************************************
*********************************************************************/
-static uint32 reg_perfcount_get_perf_data_block(uint32 base_index,
+static uint32_t reg_perfcount_get_perf_data_block(uint32_t base_index,
TALLOC_CTX *mem_ctx,
struct PERF_DATA_BLOCK *block,
const char *object_ids,
bool bigendian_data)
{
- uint32 buffer_size = 0;
+ uint32_t buffer_size = 0;
char *fname;
TDB_CONTEXT *names;
int retval = 0;
if(!prs_uint32("ByteLength", ps, depth, &counter_data.ByteLength))
return False;
- if(!prs_uint8s(False, "CounterData", ps, depth, counter_data.data, counter_data.ByteLength - sizeof(uint32)))
+ if(!prs_uint8s(False, "CounterData", ps, depth, counter_data.data, counter_data.ByteLength - sizeof(uint32_t)))
return False;
if(!prs_align_uint64(ps))
return False;
/*********************************************************************
*********************************************************************/
-WERROR reg_perfcount_get_hkpd(prs_struct *ps, uint32 max_buf_size, uint32 *outbuf_len, const char *object_ids)
+WERROR reg_perfcount_get_hkpd(prs_struct *ps, uint32_t max_buf_size, uint32_t *outbuf_len, const char *object_ids)
{
/*
* For a detailed description of the layout of this structure,
* http://msdn2.microsoft.com/en-us/library/aa373105.aspx -- vl
*/
struct PERF_DATA_BLOCK block;
- uint32 buffer_size, base_index;
+ uint32_t buffer_size, base_index;
buffer_size = 0;
base_index = reg_perfcount_get_base_index();
#include "reg_parse_prs.h"
-uint32 reg_perfcount_get_base_index(void);
-uint32 reg_perfcount_get_last_counter(uint32 base_index);
-uint32 reg_perfcount_get_last_help(uint32 last_counter);
-uint32 reg_perfcount_get_counter_help(uint32 base_index, char **retbuf);
-uint32 reg_perfcount_get_counter_names(uint32 base_index, char **retbuf);
-WERROR reg_perfcount_get_hkpd(prs_struct *ps, uint32 max_buf_size, uint32 *outbuf_len, const char *object_ids);
+uint32_t reg_perfcount_get_base_index(void);
+uint32_t reg_perfcount_get_last_counter(uint32_t base_index);
+uint32_t reg_perfcount_get_last_help(uint32_t last_counter);
+uint32_t reg_perfcount_get_counter_help(uint32_t base_index, char **retbuf);
+uint32_t reg_perfcount_get_counter_names(uint32_t base_index, char **retbuf);
+WERROR reg_perfcount_get_hkpd(prs_struct *ps, uint32_t max_buf_size, uint32_t *outbuf_len, const char *object_ids);
#endif /* _REG_PERFCOUNT_H */
static bool smb_io_time(const char *desc, NTTIME *nttime, prs_struct *ps, int depth)
{
- uint32 low, high;
+ uint32_t low, high;
if (nttime == NULL)
return False;
/*******************************************************************
*******************************************************************/
-static int write_block( REGF_FILE *file, prs_struct *ps, uint32 offset )
+static int write_block( REGF_FILE *file, prs_struct *ps, uint32_t offset )
{
int bytes_written, returned;
char *buffer = prs_data_p( ps );
- uint32 buffer_size = prs_data_size( ps );
+ uint32_t buffer_size = prs_data_size( ps );
SMB_STRUCT_STAT sbuf;
if ( file->fd == -1 )
/*******************************************************************
*******************************************************************/
-static int read_block( REGF_FILE *file, prs_struct *ps, uint32 file_offset, uint32 block_size )
+static int read_block( REGF_FILE *file, prs_struct *ps, uint32_t file_offset, uint32_t block_size )
{
int bytes_read, returned;
char *buffer;
/* write free space record if any is available */
if ( hbin->free_off != REGF_OFFSET_NONE ) {
- uint32 header = 0xffffffff;
+ uint32_t header = 0xffffffff;
- if ( !prs_set_offset( &hbin->ps, hbin->free_off-sizeof(uint32) ) )
+ if ( !prs_set_offset( &hbin->ps, hbin->free_off-sizeof(uint32_t) ) )
return False;
if ( !prs_uint32( "free_size", &hbin->ps, 0, &hbin->free_size ) )
return False;
static bool prs_hbin_block( const char *desc, prs_struct *ps, int depth, REGF_HBIN *hbin )
{
- uint32 block_size2;
+ uint32_t block_size2;
prs_debug(ps, depth, desc, "prs_regf_block");
depth++;
static bool prs_nk_rec( const char *desc, prs_struct *ps, int depth, REGF_NK_REC *nk )
{
uint16 class_length, name_length;
- uint32 start;
- uint32 data_size, start_off, end_off;
- uint32 unknown_off = REGF_OFFSET_NONE;
+ uint32_t start;
+ uint32_t data_size, start_off, end_off;
+ uint32_t unknown_off = REGF_OFFSET_NONE;
nk->hbin_off = prs_offset( ps );
start = nk->hbin_off;
/* back up and get the data_size */
- if ( !prs_set_offset( ps, prs_offset(ps)-sizeof(uint32)) )
+ if ( !prs_set_offset( ps, prs_offset(ps)-sizeof(uint32_t)) )
return False;
start_off = prs_offset( ps );
if ( !prs_uint32( "rec_size", ps, depth, &nk->rec_size ))
/*******************************************************************
*******************************************************************/
-static uint32 regf_block_checksum( prs_struct *ps )
+static uint32_t regf_block_checksum( prs_struct *ps )
{
char *buffer = prs_data_p( ps );
- uint32 checksum, x;
+ uint32_t checksum, x;
int i;
/* XOR of all bytes 0x0000 - 0x01FB */
static bool read_regf_block( REGF_FILE *file )
{
prs_struct ps;
- uint32 checksum;
+ uint32_t checksum;
/* grab the first block from the file */
static REGF_HBIN* read_hbin_block( REGF_FILE *file, off_t offset )
{
REGF_HBIN *hbin;
- uint32 record_size, curr_off, block_size, header;
+ uint32_t record_size, curr_off, block_size, header;
if ( !(hbin = talloc_zero(file->mem_ctx, REGF_HBIN)) )
return NULL;
/* remember that the record_size is in the 4 bytes preceeding the record itself */
- if ( !prs_set_offset( &hbin->ps, file->data_offset+HBIN_HDR_SIZE-sizeof(uint32) ) )
+ if ( !prs_set_offset( &hbin->ps, file->data_offset+HBIN_HDR_SIZE-sizeof(uint32_t) ) )
return NULL;
record_size = 0;
/* account for the fact that the curr_off is 4 bytes behind the actual
record header */
- hbin->free_off = curr_off + sizeof(uint32);
+ hbin->free_off = curr_off + sizeof(uint32_t);
hbin->free_size = record_size;
}
block for it
*******************************************************************/
-static bool hbin_contains_offset( REGF_HBIN *hbin, uint32 offset )
+static bool hbin_contains_offset( REGF_HBIN *hbin, uint32_t offset )
{
if ( !hbin )
return False;
block for it
*******************************************************************/
-static REGF_HBIN* lookup_hbin_block( REGF_FILE *file, uint32 offset )
+static REGF_HBIN* lookup_hbin_block( REGF_FILE *file, uint32_t offset )
{
REGF_HBIN *hbin = NULL;
- uint32 block_off;
+ uint32_t block_off;
/* start with the open list */
{
int i;
REGF_LF_REC *lf = &nk->subkeys;
- uint32 data_size, start_off, end_off;
+ uint32_t data_size, start_off, end_off;
prs_debug(&hbin->ps, depth, desc, "prs_lf_records");
depth++;
/* backup and get the data_size */
- if ( !prs_set_offset( &hbin->ps, prs_offset(&hbin->ps)-sizeof(uint32)) )
+ if ( !prs_set_offset( &hbin->ps, prs_offset(&hbin->ps)-sizeof(uint32_t)) )
return False;
start_off = prs_offset( &hbin->ps );
if ( !prs_uint32( "rec_size", &hbin->ps, depth, &lf->rec_size ))
{
prs_struct *ps = &hbin->ps;
uint16 tag = 0xFFFF;
- uint32 data_size, start_off, end_off;
+ uint32_t data_size, start_off, end_off;
prs_debug(ps, depth, desc, "hbin_prs_sk_rec");
/* backup and get the data_size */
- if ( !prs_set_offset( &hbin->ps, prs_offset(&hbin->ps)-sizeof(uint32)) )
+ if ( !prs_set_offset( &hbin->ps, prs_offset(&hbin->ps)-sizeof(uint32_t)) )
return False;
start_off = prs_offset( &hbin->ps );
if ( !prs_uint32( "rec_size", &hbin->ps, depth, &sk->rec_size ))
static bool hbin_prs_vk_rec( const char *desc, REGF_HBIN *hbin, int depth, REGF_VK_REC *vk, REGF_FILE *file )
{
- uint32 offset;
+ uint32_t offset;
uint16 name_length;
prs_struct *ps = &hbin->ps;
- uint32 data_size, start_off, end_off;
+ uint32_t data_size, start_off, end_off;
prs_debug(ps, depth, desc, "prs_vk_rec");
depth++;
/* backup and get the data_size */
- if ( !prs_set_offset( &hbin->ps, prs_offset(&hbin->ps)-sizeof(uint32)) )
+ if ( !prs_set_offset( &hbin->ps, prs_offset(&hbin->ps)-sizeof(uint32_t)) )
return False;
start_off = prs_offset( &hbin->ps );
if ( !prs_uint32( "rec_size", &hbin->ps, depth, &vk->rec_size ))
if ( !(vk->data_size & VK_DATA_IN_OFFSET) ) {
REGF_HBIN *hblock = hbin;
- uint32 data_rec_size;
+ uint32_t data_rec_size;
if ( UNMARSHALLING(&hbin->ps) ) {
if ( !(vk->data = PRS_ALLOC_MEM( ps, uint8, vk->data_size) ) )
if ( !(hblock = lookup_hbin_block( file, vk->data_off )) )
return False;
}
- if ( !(prs_set_offset( &hblock->ps, (vk->data_off+HBIN_HDR_SIZE-hblock->first_hbin_off)-sizeof(uint32) )) )
+ if ( !(prs_set_offset( &hblock->ps, (vk->data_off+HBIN_HDR_SIZE-hblock->first_hbin_off)-sizeof(uint32_t) )) )
return False;
if ( MARSHALLING(&hblock->ps) ) {
- data_rec_size = ( (vk->data_size+sizeof(uint32)) & 0xfffffff8 ) + 8;
+ data_rec_size = ( (vk->data_size+sizeof(uint32_t)) & 0xfffffff8 ) + 8;
data_rec_size = ( data_rec_size - 1 ) ^ 0xFFFFFFFF;
}
if ( !prs_uint32( "data_rec_size", &hblock->ps, depth, &data_rec_size ))
static bool hbin_prs_vk_records( const char *desc, REGF_HBIN *hbin, int depth, REGF_NK_REC *nk, REGF_FILE *file )
{
int i;
- uint32 record_size;
+ uint32_t record_size;
prs_debug(&hbin->ps, depth, desc, "prs_vk_records");
depth++;
/* convert the offset to something relative to this HBIN block */
- if ( !prs_set_offset( &hbin->ps, nk->values_off+HBIN_HDR_SIZE-hbin->first_hbin_off-sizeof(uint32)) )
+ if ( !prs_set_offset( &hbin->ps, nk->values_off+HBIN_HDR_SIZE-hbin->first_hbin_off-sizeof(uint32_t)) )
return False;
if ( MARSHALLING( &hbin->ps) ) {
- record_size = ( ( nk->num_values * sizeof(uint32) ) & 0xfffffff8 ) + 8;
+ record_size = ( ( nk->num_values * sizeof(uint32_t) ) & 0xfffffff8 ) + 8;
record_size = (record_size - 1) ^ 0xFFFFFFFF;
}
for ( i=0; i<nk->num_values; i++ ) {
REGF_HBIN *sub_hbin = hbin;
- uint32 new_offset;
+ uint32_t new_offset;
if ( !hbin_contains_offset( hbin, nk->values[i].rec_off ) ) {
sub_hbin = lookup_hbin_block( file, nk->values[i].rec_off );
/*******************************************************************
*******************************************************************/
-static REGF_SK_REC* find_sk_record_by_offset( REGF_FILE *file, uint32 offset )
+static REGF_SK_REC* find_sk_record_by_offset( REGF_FILE *file, uint32_t offset )
{
REGF_SK_REC *p_sk;
static bool next_record( REGF_HBIN *hbin, const char *hdr, bool *eob )
{
uint8 header[REC_HDR_SIZE];
- uint32 record_size;
- uint32 curr_off, block_size;
+ uint32_t record_size;
+ uint32_t curr_off, block_size;
bool found = False;
prs_struct *ps = &hbin->ps;
/* assume that the current offset is at the record header
and we need to backup to read the record size */
- curr_off -= sizeof(uint32);
+ curr_off -= sizeof(uint32_t);
block_size = prs_data_size( ps );
record_size = 0;
if ( memcmp( header, hdr, REC_HDR_SIZE ) == 0 ) {
found = True;
- curr_off += sizeof(uint32);
+ curr_off += sizeof(uint32_t);
}
}
{
REGF_NK_REC *nk;
REGF_HBIN *hbin;
- uint32 offset = REGF_BLOCKSIZE;
+ uint32_t offset = REGF_BLOCKSIZE;
bool found = False;
bool eob;
{
REGF_NK_REC *subkey;
REGF_HBIN *hbin;
- uint32 nk_offset;
+ uint32_t nk_offset;
/* see if there is anything left to report */
/*******************************************************************
*******************************************************************/
-static REGF_HBIN* regf_hbin_allocate( REGF_FILE *file, uint32 block_size )
+static REGF_HBIN* regf_hbin_allocate( REGF_FILE *file, uint32_t block_size )
{
REGF_HBIN *hbin;
SMB_STRUCT_STAT sbuf;
hbin->file_off = sbuf.st_ex_size;
hbin->free_off = HBIN_HEADER_REC_SIZE;
- hbin->free_size = block_size - hbin->free_off + sizeof(uint32);
+ hbin->free_size = block_size - hbin->free_off + sizeof(uint32_t);
hbin->block_size = block_size;
hbin->first_hbin_off = hbin->file_off - REGF_BLOCKSIZE;
/*******************************************************************
*******************************************************************/
-static void update_free_space( REGF_HBIN *hbin, uint32 size_used )
+static void update_free_space( REGF_HBIN *hbin, uint32_t size_used )
{
hbin->free_off += size_used;
hbin->free_size -= size_used;
/*******************************************************************
*******************************************************************/
-static REGF_HBIN* find_free_space( REGF_FILE *file, uint32 size )
+static REGF_HBIN* find_free_space( REGF_FILE *file, uint32_t size )
{
REGF_HBIN *hbin, *p_hbin;
- uint32 block_off;
+ uint32_t block_off;
bool cached;
/* check open block list */
/* no free space; allocate a new one */
if ( !hbin ) {
- uint32 alloc_size;
+ uint32_t alloc_size;
/* allocate in multiples of REGF_ALLOC_BLOCK; make sure (size + hbin_header) fits */
done:
/* set the offset to be ready to write */
- if ( !prs_set_offset( &hbin->ps, hbin->free_off-sizeof(uint32) ) )
+ if ( !prs_set_offset( &hbin->ps, hbin->free_off-sizeof(uint32_t) ) )
return NULL;
/* write the record size as a placeholder for now, it should be
/*******************************************************************
*******************************************************************/
-static uint32 sk_record_data_size( struct security_descriptor * sd )
+static uint32_t sk_record_data_size( struct security_descriptor * sd )
{
- uint32 size, size_mod8;
+ uint32_t size, size_mod8;
size_mod8 = 0;
/* the record size is sizeof(hdr) + name + static members + data_size_field */
- size = sizeof(uint32)*5 + ndr_size_security_descriptor(sd, 0) + sizeof(uint32);
+ size = sizeof(uint32_t)*5 + ndr_size_security_descriptor(sd, 0) + sizeof(uint32);
/* multiple of 8 */
size_mod8 = size & 0xfffffff8;
/*******************************************************************
*******************************************************************/
-static uint32 vk_record_data_size( REGF_VK_REC *vk )
+static uint32_t vk_record_data_size( REGF_VK_REC *vk )
{
- uint32 size, size_mod8;
+ uint32_t size, size_mod8;
size_mod8 = 0;
/* the record size is sizeof(hdr) + name + static members + data_size_field */
- size = REC_HDR_SIZE + (sizeof(uint16)*3) + (sizeof(uint32)*3) + sizeof(uint32);
+ size = REC_HDR_SIZE + (sizeof(uint16)*3) + (sizeof(uint32_t)*3) + sizeof(uint32);
if ( vk->valuename )
size += strlen(vk->valuename);
/*******************************************************************
*******************************************************************/
-static uint32 lf_record_data_size( uint32 num_keys )
+static uint32_t lf_record_data_size( uint32_t num_keys )
{
- uint32 size, size_mod8;
+ uint32_t size, size_mod8;
size_mod8 = 0;
- /* the record size is sizeof(hdr) + num_keys + sizeof of hash_array + data_size_uint32 */
+ /* the record size is sizeof(hdr) + num_keys + sizeof of hash_array + data_size_uint32_t */
- size = REC_HDR_SIZE + sizeof(uint16) + (sizeof(REGF_HASH_REC) * num_keys) + sizeof(uint32);
+ size = REC_HDR_SIZE + sizeof(uint16) + (sizeof(REGF_HASH_REC) * num_keys) + sizeof(uint32_t);
/* multiple of 8 */
size_mod8 = size & 0xfffffff8;
/*******************************************************************
*******************************************************************/
-static uint32 nk_record_data_size( REGF_NK_REC *nk )
+static uint32_t nk_record_data_size( REGF_NK_REC *nk )
{
- uint32 size, size_mod8;
+ uint32_t size, size_mod8;
size_mod8 = 0;
- /* the record size is static + length_of_keyname + length_of_classname + data_size_uint32 */
+ /* the record size is static + length_of_keyname + length_of_classname + data_size_uint32_t */
- size = 0x4c + strlen(nk->keyname) + sizeof(uint32);
+ size = 0x4c + strlen(nk->keyname) + sizeof(uint32_t);
if ( nk->classname )
size += strlen( nk->classname );
vk->data_size = regval_size( value );
vk->type = regval_type( value );
- if ( vk->data_size > sizeof(uint32) ) {
- uint32 data_size = ( (vk->data_size+sizeof(uint32)) & 0xfffffff8 ) + 8;
+ if ( vk->data_size > sizeof(uint32_t) ) {
+ uint32_t data_size = ( (vk->data_size+sizeof(uint32_t)) & 0xfffffff8 ) + 8;
vk->data = (uint8 *)talloc_memdup( file->mem_ctx,
regval_data_p(value),
{
REGF_NK_REC *nk;
REGF_HBIN *vlist_hbin = NULL;
- uint32 size;
+ uint32_t size;
if ( !(nk = talloc_zero( file->mem_ctx, REGF_NK_REC )) )
return NULL;
REGF_HASH_REC *hash = &parent->subkeys.hashes[parent->subkey_index];
hash->nk_off = prs_offset( &nk->hbin->ps ) + nk->hbin->first_hbin_off - HBIN_HDR_SIZE;
- memcpy(hash->keycheck, name, MIN(strlen(name),sizeof(uint32)));
+ memcpy(hash->keycheck, name, MIN(strlen(name),sizeof(uint32_t)));
hash->fullname = talloc_strdup( file->mem_ctx, name );
parent->subkey_index++;
nk->sk_off = REGF_OFFSET_NONE;
if ( sec_desc ) {
- uint32 sk_size = sk_record_data_size( sec_desc );
+ uint32_t sk_size = sk_record_data_size( sec_desc );
REGF_HBIN *sk_hbin;
/* search for it in the existing list of sd's */
/* size value must be self-inclusive */
nk->sec_desc->size = ndr_size_security_descriptor(sec_desc, 0)
- + sizeof(uint32);
+ + sizeof(uint32_t);
DLIST_ADD_END( file->sec_desc_list, nk->sec_desc, REGF_SK_REC *);
nk->subkeys_off = REGF_OFFSET_NONE;
if ( (nk->num_subkeys = regsubkey_ctr_numkeys( subkeys )) != 0 ) {
- uint32 lf_size = lf_record_data_size( nk->num_subkeys );
- uint32 namelen;
+ uint32_t lf_size = lf_record_data_size( nk->num_subkeys );
+ uint32_t namelen;
int i;
if (!(nk->subkeys.hbin = find_free_space( file, lf_size ))) {
nk->values_off = REGF_OFFSET_NONE;
if ( (nk->num_values = regval_ctr_numvals( values )) != 0 ) {
- uint32 vlist_size = ( ( nk->num_values * sizeof(uint32) ) & 0xfffffff8 ) + 8;
+ uint32_t vlist_size = ( ( nk->num_values * sizeof(uint32_t) ) & 0xfffffff8 ) + 8;
int i;
if (!(vlist_hbin = find_free_space( file, vlist_size ))) {
/* create the vk records */
for ( i=0; i<nk->num_values; i++ ) {
- uint32 vk_size, namelen, datalen;
+ uint32_t vk_size, namelen, datalen;
struct regval_blob *r;
r = regval_ctr_specific_value( values, i );
struct regf_hbin;
typedef struct regf_hbin {
struct regf_hbin *prev, *next;
- uint32 file_off; /* my offset in the registry file */
- uint32 free_off; /* offset to free space within the hbin record */
- uint32 free_size; /* amount of data left in the block */
+ uint32_t file_off; /* my offset in the registry file */
+ uint32_t free_off; /* offset to free space within the hbin record */
+ uint32_t free_size; /* amount of data left in the block */
int ref_count; /* how many active records are pointing to this block (not used currently) */
char header[HBIN_HDR_SIZE]; /* "hbin" */
- uint32 first_hbin_off; /* offset from first hbin block */
- uint32 block_size; /* block size of this blockually a multiple of 4096Kb) */
+ uint32_t first_hbin_off; /* offset from first hbin block */
+ uint32_t block_size; /* block size of this blockually a multiple of 4096Kb) */
prs_struct ps; /* data */
/* ??? List -- list of key offsets and hashed names for consistency */
typedef struct {
- uint32 nk_off;
- uint8 keycheck[sizeof(uint32)];
+ uint32_t nk_off;
+ uint8 keycheck[sizeof(uint32_t)];
char *fullname;
} REGF_HASH_REC;
typedef struct {
REGF_HBIN *hbin; /* pointer to HBIN record (in memory) containing this nk record */
- uint32 hbin_off; /* offset from beginning of this hbin block */
- uint32 rec_size; /* ((start_offset - end_offset) & 0xfffffff8) */
+ uint32_t hbin_off; /* offset from beginning of this hbin block */
+ uint32_t rec_size; /* ((start_offset - end_offset) & 0xfffffff8) */
char header[REC_HDR_SIZE];
uint16 num_keys;
typedef struct {
REGF_HBIN *hbin; /* pointer to HBIN record (in memory) containing this nk record */
- uint32 hbin_off; /* offset from beginning of this hbin block */
- uint32 rec_size; /* ((start_offset - end_offset) & 0xfffffff8) */
- uint32 rec_off; /* offset stored in the value list */
+ uint32_t hbin_off; /* offset from beginning of this hbin block */
+ uint32_t rec_size; /* ((start_offset - end_offset) & 0xfffffff8) */
+ uint32_t rec_off; /* offset stored in the value list */
char header[REC_HDR_SIZE];
char *valuename;
- uint32 data_size;
- uint32 data_off;
+ uint32_t data_size;
+ uint32_t data_off;
uint8 *data;
- uint32 type;
+ uint32_t type;
uint16 flag;
} REGF_VK_REC;
typedef struct _regf_sk_rec {
struct _regf_sk_rec *next, *prev;
REGF_HBIN *hbin; /* pointer to HBIN record (in memory) containing this nk record */
- uint32 hbin_off; /* offset from beginning of this hbin block */
- uint32 rec_size; /* ((start_offset - end_offset) & 0xfffffff8) */
+ uint32_t hbin_off; /* offset from beginning of this hbin block */
+ uint32_t rec_size; /* ((start_offset - end_offset) & 0xfffffff8) */
- uint32 sk_off; /* offset parsed from NK record used as a key
+ uint32_t sk_off; /* offset parsed from NK record used as a key
to lookup reference to this SK record */
char header[REC_HDR_SIZE];
- uint32 prev_sk_off;
- uint32 next_sk_off;
- uint32 ref_count;
- uint32 size;
+ uint32_t prev_sk_off;
+ uint32_t next_sk_off;
+ uint32_t ref_count;
+ uint32_t size;
struct security_descriptor *sec_desc;
} REGF_SK_REC;
typedef struct {
REGF_HBIN *hbin; /* pointer to HBIN record (in memory) containing this nk record */
- uint32 hbin_off; /* offset from beginning of this hbin block */
- uint32 subkey_index; /* index to next subkey record to return */
- uint32 rec_size; /* ((start_offset - end_offset) & 0xfffffff8) */
+ uint32_t hbin_off; /* offset from beginning of this hbin block */
+ uint32_t subkey_index; /* index to next subkey record to return */
+ uint32_t rec_size; /* ((start_offset - end_offset) & 0xfffffff8) */
/* header information */
char header[REC_HDR_SIZE];
uint16 key_type;
NTTIME mtime;
- uint32 parent_off; /* back pointer in registry hive */
- uint32 classname_off;
+ uint32_t parent_off; /* back pointer in registry hive */
+ uint32_t classname_off;
char *classname;
char *keyname;
/* max lengths */
- uint32 max_bytes_subkeyname; /* max subkey name * 2 */
- uint32 max_bytes_subkeyclassname; /* max subkey classname length (as if) */
- uint32 max_bytes_valuename; /* max valuename * 2 */
- uint32 max_bytes_value; /* max value data size */
+ uint32_t max_bytes_subkeyname; /* max subkey name * 2 */
+ uint32_t max_bytes_subkeyclassname; /* max subkey classname length (as if) */
+ uint32_t max_bytes_valuename; /* max valuename * 2 */
+ uint32_t max_bytes_value; /* max value data size */
/* unknowns */
- uint32 unk_index; /* nigel says run time index ? */
+ uint32_t unk_index; /* nigel says run time index ? */
/* children */
- uint32 num_subkeys;
- uint32 subkeys_off; /* hash records that point to NK records */
- uint32 num_values;
- uint32 values_off; /* value lists which point to VK records */
- uint32 sk_off; /* offset to SK record */
+ uint32_t num_subkeys;
+ uint32_t subkeys_off; /* hash records that point to NK records */
+ uint32_t num_values;
+ uint32_t values_off; /* value lists which point to VK records */
+ uint32_t sk_off; /* offset to SK record */
/* link in the other records here */
/* file format information */
char header[REGF_HDR_SIZE]; /* "regf" */
- uint32 data_offset; /* offset to record in the first (or any?) hbin block */
- uint32 last_block; /* offset to last hbin block in file */
- uint32 checksum; /* XOR of bytes 0x0000 - 0x01FB */
+ uint32_t data_offset; /* offset to record in the first (or any?) hbin block */
+ uint32_t last_block; /* offset to last hbin block in file */
+ uint32_t checksum; /* XOR of bytes 0x0000 - 0x01FB */
NTTIME mtime;
REGF_SK_REC *sec_desc_list; /* list of security descriptors referenced by NK records */
/* unknowns used to simply writing */
- uint32 unknown1;
- uint32 unknown2;
- uint32 unknown3;
- uint32 unknown4;
- uint32 unknown5;
- uint32 unknown6;
+ uint32_t unknown1;
+ uint32_t unknown2;
+ uint32_t unknown3;
+ uint32_t unknown4;
+ uint32_t unknown5;
+ uint32_t unknown6;
} REGF_FILE;