diff options
author | Luke Leighton <lkcl@samba.org> | 1999-10-29 20:24:18 +0000 |
---|---|---|
committer | Luke Leighton <lkcl@samba.org> | 1999-10-29 20:24:18 +0000 |
commit | bcf1c3182670f20f4705cfe73e27d1e2e9f8eedf (patch) | |
tree | d1c0df72425384d1501a7dee97e1def26a86d708 /source3/include | |
parent | 243feaa08c43cc7dbca155cba5f085697e968c8d (diff) | |
download | samba-bcf1c3182670f20f4705cfe73e27d1e2e9f8eedf.tar.gz samba-bcf1c3182670f20f4705cfe73e27d1e2e9f8eedf.tar.bz2 samba-bcf1c3182670f20f4705cfe73e27d1e2e9f8eedf.zip |
rpcclient regenum key client code rewritten to use higher order functions.
(This used to be commit 6a759c57dcb851aa19d1d4156249a3df112aefd0)
Diffstat (limited to 'source3/include')
-rw-r--r-- | source3/include/ntdomain.h | 8 | ||||
-rw-r--r-- | source3/include/proto.h | 15 | ||||
-rw-r--r-- | source3/include/rpcclient.h | 4 |
3 files changed, 17 insertions, 10 deletions
diff --git a/source3/include/ntdomain.h b/source3/include/ntdomain.h index 3d8bdcba29..8d35d7aae3 100644 --- a/source3/include/ntdomain.h +++ b/source3/include/ntdomain.h @@ -154,9 +154,13 @@ struct acct_info #define GROUP_INFO_FN(fn) void (*fn)(char*, DOM_SID*, uint32, GROUP_INFO_CTR *) #define GROUP_MEM_FN(fn) void(*fn)(char*, DOM_SID*, uint32, char*, uint32, uint32*, char**, uint32*) -#define USER_FN(fn) void (*fn)(char*, DOM_SID*, uint32, char*) +#define USER_FN(fn) void (*fn)(char*, DOM_SID*, uint32, char*) #define USER_INFO_FN(fn) void (*fn)(char*, DOM_SID*, uint32, SAM_USER_INFO_21 *) -#define USER_MEM_FN(fn) void(*fn)(char*, DOM_SID*, uint32, char*, uint32, uint32*, char**, uint32*) +#define USER_MEM_FN(fn) void (*fn)(char*, DOM_SID*, uint32, char*, uint32, uint32*, char**, uint32*) + +#define REG_FN(fn) void (*fn)(int, const char *, int) +#define REG_KEY_FN(fn) void (*fn)(const char*, const char*, time_t) +#define REG_VAL_FN(fn) void (*fn)(const char *, const char*, uint32, BUFFER2 *) #endif /* _NT_DOMAIN_H */ diff --git a/source3/include/proto.h b/source3/include/proto.h index 7178bcde63..173464f5b9 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -483,7 +483,7 @@ int str_checksum(const char *s); void zero_free(void *p, size_t size); int set_maxfiles(int requested_max); void reg_get_subkey(char *full_keyname, char *key_name, char *subkey_name); -BOOL reg_split_key(char *full_keyname, uint32 *reg_type, char *key_name); +BOOL reg_split_key(const char *full_keyname, uint32 *reg_type, char *key_name); BOOL become_user_permanently(uid_t uid, gid_t gid); void free_char_array(uint32 num_entries, char **entries); @@ -1814,7 +1814,9 @@ void cli_nt_session_close(struct cli_state *cli, uint16 nt_pipe_fnum); /*The following definitions come from rpc_client/cli_reg.c */ -BOOL do_reg_connect(struct cli_state *cli, uint16 fnum, char *full_keyname, char *key_name, +BOOL do_reg_connect(struct cli_state *cli, uint16 fnum, + const char *full_keyname, + char *key_name, POLICY_HND *reg_hnd); BOOL do_reg_open_hkcr(struct cli_state *cli, uint16 fnum, uint16 unknown_0, uint32 level, POLICY_HND *hnd); @@ -3198,6 +3200,10 @@ void cmd_sam_sync(struct client_info *info); /*The following definitions come from rpcclient/cmd_reg.c */ +void msrpc_reg_enum_key(struct cli_state *cli, const char* full_keyname, + REG_FN(reg_fn), + REG_KEY_FN(reg_key_fn), + REG_VAL_FN(reg_val_fn)); void cmd_reg_enum(struct client_info *info); void cmd_reg_query_key(struct client_info *info); void cmd_reg_create_val(struct client_info *info); @@ -3362,9 +3368,10 @@ void display_sec_acl(FILE *out_hnd, enum action_type action, SEC_ACL *sec_acl); void display_sec_desc(FILE *out_hnd, enum action_type action, SEC_DESC *sec); char *get_reg_val_type_str(uint32 type); void display_reg_value_info(FILE *out_hnd, enum action_type action, - char *val_name, uint32 val_type, BUFFER2 *value); + const char *val_name, + uint32 val_type, BUFFER2 *value); void display_reg_key_info(FILE *out_hnd, enum action_type action, - char *key_name, time_t key_mod_time); + const char *key_name, time_t key_mod_time); char *get_svc_start_type_str(uint32 type); void display_query_svc_cfg(FILE *out_hnd, enum action_type action, QUERY_SERVICE_CONFIG *cfg); diff --git a/source3/include/rpcclient.h b/source3/include/rpcclient.h index 93712b55f3..e843d56010 100644 --- a/source3/include/rpcclient.h +++ b/source3/include/rpcclient.h @@ -59,10 +59,6 @@ struct nt_client_info NET_ID_INFO_CTR ctr; NET_USER_INFO_3 user_info3; - /************** \PIPE\winreg stuff ********************/ - - POLICY_HND reg_pol_connect; - /************** \PIPE\lsarpc stuff ********************/ POLICY_HND lsa_info_pol; |