#include <sys/types.h>
#include <regex.h>
-/* The following definitions come from lib/access.c */
-
-bool client_match(const char *tok, const void *item);
-bool list_match(const char **list,const void *item,
- bool (*match_fn)(const char *, const void *));
-bool allow_access(const char **deny_list,
- const char **allow_list,
- const char *cname,
- const char *caddr);
+#include "lib/util/access.h"
/* The following definitions come from lib/adt_tree.c */
struct file_id vfs_file_id_from_sbuf(connection_struct *conn, const SMB_STRUCT_STAT *sbuf);
-/* The following definitions come from lib/gencache.c */
-
-bool gencache_set(const char *keystr, const char *value, time_t timeout);
-bool gencache_del(const char *keystr);
-bool gencache_get(const char *keystr, TALLOC_CTX *mem_ctx, char **value,
- time_t *ptimeout);
-bool gencache_parse(const char *keystr,
- void (*parser)(time_t timeout, DATA_BLOB blob,
- void *private_data),
- void *private_data);
-bool gencache_get_data_blob(const char *keystr, TALLOC_CTX *mem_ctx,
- DATA_BLOB *blob,
- time_t *timeout, bool *was_expired);
-bool gencache_stabilize(void);
-bool gencache_set_data_blob(const char *keystr, const DATA_BLOB *blob, time_t timeout);
-void gencache_iterate_blobs(void (*fn)(const char *key, DATA_BLOB value,
- time_t timeout, void *private_data),
- void *private_data, const char *pattern);
-void gencache_iterate(void (*fn)(const char* key, const char *value, time_t timeout, void* dptr),
- void* data, const char* keystr_pattern);
-
/* The following definitions come from lib/interface.c */
bool ismyaddr(const struct sockaddr *ip);
/* The following definitions come from lib/smbrun.c */
-int smbrun_no_sanitize(const char *cmd, int *outfd);
-int smbrun(const char *cmd, int *outfd);
+int smbrun_no_sanitize(const char *cmd, int *outfd, char * const *env);
+int smbrun(const char *cmd, int *outfd, char * const *env);
int smbrunsecret(const char *cmd, const char *secret);
-/* The following definitions come from lib/sock_exec.c */
-
-int sock_exec(const char *prog);
-
/* The following definitions come from lib/substitute.c */
void free_local_machine_name(void);
void kernel_flock(int fd, uint32_t share_mode, uint32_t access_mask);
DIR *sys_fdopendir(int fd);
int sys_mknod(const char *path, mode_t mode, SMB_DEV_T dev);
-int sys_waitpid(pid_t pid,int *status,int options);
char *sys_getwd(void);
void set_effective_capability(enum smbd_capability capability);
void drop_effective_capability(enum smbd_capability capability);
int groups_max(void);
int sys_getgroups(int setlen, gid_t *gidset);
int sys_setgroups(gid_t UNUSED(primary_gid), int setlen, gid_t *gidset);
-int sys_popen(const char *command);
-int sys_pclose(int fd);
-ssize_t sys_getxattr (const char *path, const char *name, void *value, size_t size);
-ssize_t sys_fgetxattr (int filedes, const char *name, void *value, size_t size);
-ssize_t sys_listxattr (const char *path, char *list, size_t size);
-ssize_t sys_flistxattr (int filedes, char *list, size_t size);
-int sys_removexattr (const char *path, const char *name);
-int sys_fremovexattr (int filedes, const char *name);
-int sys_setxattr (const char *path, const char *name, const void *value, size_t size, int flags);
-int sys_fsetxattr (int filedes, const char *name, const void *value, size_t size, int flags);
uint32_t unix_dev_major(SMB_DEV_T dev);
uint32_t unix_dev_minor(SMB_DEV_T dev);
+char *sys_realpath(const char *path);
#if 0
int sys_get_number_of_cores(void);
#endif
/* The following definitions come from lib/util_names.c */
const char *get_global_sam_name(void);
+const char *my_sam_name(void);
/* The following definitions come from lib/util.c */
enum protocol_types get_Protocol(void);
void set_Protocol(enum protocol_types p);
-bool all_zero(const uint8_t *ptr, size_t size);
void gfree_names(void);
void gfree_all( void );
const char *my_netbios_names(int i);
NTSTATUS init_before_fork(void);
NTSTATUS reinit_after_fork(struct messaging_context *msg_ctx,
struct tevent_context *ev_ctx,
- bool parent_longlived);
+ bool parent_longlived,
+ const char *comment);
NTSTATUS smbd_reinit_after_fork(struct messaging_context *msg_ctx,
struct tevent_context *ev_ctx,
- bool parent_longlived);
+ bool parent_longlived,
+ const char *comment);
void *malloc_(size_t size);
void *Realloc(void *p, size_t size, bool free_old_on_error);
void add_to_large_array(TALLOC_CTX *mem_ctx, size_t element_size,
char *automount_lookup(TALLOC_CTX *ctx, const char *user_name);
char *automount_lookup(TALLOC_CTX *ctx, const char *user_name);
bool process_exists(const struct server_id pid);
-bool processes_exist(const struct server_id *pids, int num_pids,
- bool *results);
const char *uidtoname(uid_t uid);
char *gidtoname(gid_t gid);
uid_t nametouid(const char *name);
gid_t nametogid(const char *name);
void smb_panic_s3(const char *why);
-void log_stack_trace(void);
const char *readdirname(DIR *p);
bool is_in_path(const char *name, name_compare_entry *namelist, bool case_sensitive);
void set_namearray(name_compare_entry **ppname_array, const char *namelist);
void free_namearray(name_compare_entry *name_array);
bool fcntl_lock(int fd, int op, off_t offset, off_t count, int type);
-bool fcntl_getlock(int fd, off_t *poffset, off_t *pcount, int *ptype, pid_t *ppid);
+bool fcntl_getlock(int fd, int op, off_t *poffset, off_t *pcount, int *ptype, pid_t *ppid);
+int map_process_lock_to_ofd_lock(int op);
bool is_myname(const char *s);
void ra_lanman_string( const char *native_lanman );
const char *get_remote_arch_str(void);
+enum remote_arch_types get_remote_arch_from_str(const char *remote_arch_string);
void set_remote_arch(enum remote_arch_types type);
enum remote_arch_types get_remote_arch(void);
+bool remote_arch_cache_update(const struct GUID *client_guid);
+bool remote_arch_cache_delete(const struct GUID *client_guid);
const char *tab_depth(int level, int depth);
int str_checksum(const char *s);
void zero_free(void *p, size_t size);
void *smb_xmalloc_array(size_t size, unsigned int count);
char *myhostname(void);
char *myhostname_upper(void);
-char *lock_path(const char *name);
-char *state_path(const char *name);
-char *cache_path(const char *name);
+#include "lib/util_path.h"
bool parent_dirname(TALLOC_CTX *mem_ctx, const char *dir, char **parent,
const char **name);
bool ms_has_wild(const char *s);
bool mask_match(const char *string, const char *pattern, bool is_case_sensitive);
bool mask_match_search(const char *string, const char *pattern, bool is_case_sensitive);
bool mask_match_list(const char *string, char **list, int listLen, bool is_case_sensitive);
-bool unix_wild_match(const char *pattern, const char *string);
+#include "lib/util/unix_match.h"
bool name_to_fqdn(fstring fqdn, const char *name);
-void *talloc_append_blob(TALLOC_CTX *mem_ctx, void *buf, DATA_BLOB blob);
uint32_t map_share_mode_to_deny_mode(uint32_t share_access, uint32_t private_options);
-pid_t procid_to_pid(const struct server_id *proc);
-void set_my_vnn(uint32_t vnn);
-uint32_t get_my_vnn(void);
-void set_my_unique_id(uint64_t unique_id);
-struct server_id pid_to_procid(pid_t pid);
-struct server_id procid_self(void);
+
+#include "lib/util_procid.h"
+
#define serverid_equal(p1, p2) server_id_equal(p1,p2)
-bool procid_is_me(const struct server_id *pid);
struct server_id interpret_pid(const char *pid_string);
-bool procid_valid(const struct server_id *pid);
-bool procid_is_local(const struct server_id *pid);
bool is_offset_safe(const char *buf_base, size_t buf_len, char *ptr, size_t off);
char *get_safe_ptr(const char *buf_base, size_t buf_len, char *ptr, size_t off);
char *get_safe_str_ptr(const char *buf_base, size_t buf_len, char *ptr, size_t off);
int get_safe_SVAL(const char *buf_base, size_t buf_len, char *ptr, size_t off, int failval);
int get_safe_IVAL(const char *buf_base, size_t buf_len, char *ptr, size_t off, int failval);
-void split_domain_user(TALLOC_CTX *mem_ctx,
+bool split_domain_user(TALLOC_CTX *mem_ctx,
const char *full_name,
char **domain,
char **user);
uint32_t *pcreate_options,
uint32_t *pprivate_flags);
struct security_unix_token *copy_unix_token(TALLOC_CTX *ctx, const struct security_unix_token *tok);
+struct security_unix_token *root_unix_token(TALLOC_CTX *mem_ctx);
bool dir_check_ftype(uint32_t mode, uint32_t dirtype);
-void init_modules(void);
/* The following definitions come from lib/util_builtin.c */
bool sid_check_is_in_builtin(const struct dom_sid *sid);
bool sid_check_is_wellknown_builtin(const struct dom_sid *sid);
-/* The following definitions come from lib/util_file.c */
-
-char **file_lines_pload(const char *syscmd, int *numlines);
-void file_lines_free(char **lines);
-
/* The following definitions come from lib/util_nscd.c */
void smb_nscd_flush_user_cache(void);
/* The following definitions come from lib/util_sid.c */
char *sid_to_fstring(fstring sidstr_out, const struct dom_sid *sid);
-char *sid_string_talloc(TALLOC_CTX *mem_ctx, const struct dom_sid *sid);
-char *sid_string_dbg(const struct dom_sid *sid);
-char *sid_string_tos(const struct dom_sid *sid);
-bool sid_linearize(char *outbuf, size_t len, const struct dom_sid *sid);
+bool sid_linearize(uint8_t *outbuf, size_t len, const struct dom_sid *sid);
bool non_mappable_sid(struct dom_sid *sid);
char *sid_binstring_hex_talloc(TALLOC_CTX *mem_ctx, const struct dom_sid *sid);
struct netr_SamInfo3;
int create_tcpip_socket(const struct sockaddr_storage *ifss, uint16_t *port);
const char *get_mydnsfullname(void);
bool is_myname_or_ipaddr(const char *s);
-struct tevent_req *getaddrinfo_send(TALLOC_CTX *mem_ctx,
- struct tevent_context *ev,
- struct fncall_context *ctx,
- const char *node,
- const char *service,
- const struct addrinfo *hints);
-int getaddrinfo_recv(struct tevent_req *req, struct addrinfo **res);
int poll_one_fd(int fd, int events, int timeout, int *revents);
int poll_intr_one_fd(int fd, int events, int timeout, int *revents);
-struct tstream_context;
-struct tevent_req *tstream_read_packet_send(TALLOC_CTX *mem_ctx,
- struct tevent_context *ev,
- struct tstream_context *stream,
- size_t initial,
- ssize_t (*more)(uint8_t *buf,
- size_t buflen,
- void *private_data),
- void *private_data);
-ssize_t tstream_read_packet_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
- uint8_t **pbuf, int *perrno);
/* The following definitions come from lib/util_str.c */
bool trim_char(char *s,char cfront,char cback);
bool strhasupper(const char *s);
bool strhaslower(const char *s);
-char *StrnCpy(char *dest,const char *src,size_t n);
bool in_list(const char *s, const char *list, bool casesensitive);
void fstring_sub(char *s,const char *pattern,const char *insert);
char *realloc_string_sub2(char *string,
void ipstr_list_free(char* ipstr_list);
uint64_t STR_TO_SMB_BIG_UINT(const char *nptr, const char **entptr);
uint64_t conv_str_size(const char * str);
-void sprintf_append(TALLOC_CTX *mem_ctx, char **string, ssize_t *len,
- size_t *bufsize, const char *fmt, ...);
-int asprintf_strupper_m(char **strp, const char *fmt, ...);
-char *talloc_asprintf_strupper_m(TALLOC_CTX *t, const char *fmt, ...);
-char *talloc_asprintf_strlower_m(TALLOC_CTX *t, const char *fmt, ...);
+int asprintf_strupper_m(char **strp, const char *fmt, ...)
+ PRINTF_ATTRIBUTE(2,3);
+char *talloc_asprintf_strupper_m(TALLOC_CTX *t, const char *fmt, ...)
+ PRINTF_ATTRIBUTE(2,3);
+char *talloc_asprintf_strlower_m(TALLOC_CTX *t, const char *fmt, ...)
+ PRINTF_ATTRIBUTE(2,3);
bool validate_net_name( const char *name,
const char *invalid_chars,
int max_len);
struct in_addr **pservers, int *pnum_servers);
unsigned wins_srv_count_tag(const char *tag);
-/* The following definitions come from libsmb/clispnego.c */
-
-DATA_BLOB spnego_gen_negTokenInit(TALLOC_CTX *ctx,
- const char *OIDs[],
- DATA_BLOB *psecblob,
- const char *principal);
-
#ifndef ASN1_MAX_OIDS
#define ASN1_MAX_OIDS 20
#endif
char **principal,
DATA_BLOB *secblob);
DATA_BLOB spnego_gen_krb5_wrap(TALLOC_CTX *ctx, const DATA_BLOB ticket, const uint8_t tok_id[2]);
-int spnego_gen_krb5_negTokenInit(TALLOC_CTX *ctx,
- const char *principal, int time_offset,
- DATA_BLOB *targ,
- DATA_BLOB *session_key_krb5, uint32_t extra_ap_opts,
- const char *ccname, time_t *expire_time);
-bool spnego_parse_challenge(TALLOC_CTX *ctx, const DATA_BLOB blob,
- DATA_BLOB *chal1, DATA_BLOB *chal2);
-DATA_BLOB spnego_gen_auth(TALLOC_CTX *ctx, DATA_BLOB blob);
-bool spnego_parse_auth_response(TALLOC_CTX *ctx,
- DATA_BLOB blob, NTSTATUS nt_status,
- const char *mechOID,
- DATA_BLOB *auth);
/* The following definitions come from libsmb/conncache.c */
void add_failed_connection_entry(const char *domain, const char *server, NTSTATUS result) ;
void flush_negative_conn_cache_for_domain(const char *domain);
-/* The following definitions come from libsmb/dsgetdcname.c */
-
-struct netr_DsRGetDCNameInfo;
-
-void debug_dsdcinfo_flags(int lvl, uint32_t flags);
-NTSTATUS dsgetdcname(TALLOC_CTX *mem_ctx,
- struct messaging_context *msg_ctx,
- const char *domain_name,
- const struct GUID *domain_guid,
- const char *site_name,
- uint32_t flags,
- struct netr_DsRGetDCNameInfo **info);
-
/* The following definitions come from libsmb/errormap.c */
NTSTATUS dos_to_ntstatus(uint8_t eclass, uint32_t ecode);
const struct sockaddr_storage *keyip,
char *srvname_out);
-/* The following definitions come from libsmb/namequery.c */
-
-bool saf_store( const char *domain, const char *servername );
-bool saf_join_store( const char *domain, const char *servername );
-bool saf_delete( const char *domain );
-char *saf_fetch(TALLOC_CTX *mem_ctx, const char *domain );
-struct tevent_req *node_status_query_send(TALLOC_CTX *mem_ctx,
- struct tevent_context *ev,
- struct nmb_name *name,
- const struct sockaddr_storage *addr);
-NTSTATUS node_status_query_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
- struct node_status **pnode_status,
- int *pnum_names,
- struct node_status_extra *extra);
-NTSTATUS node_status_query(TALLOC_CTX *mem_ctx, struct nmb_name *name,
- const struct sockaddr_storage *addr,
- struct node_status **pnode_status,
- int *pnum_names,
- struct node_status_extra *extra);
-bool name_status_find(const char *q_name,
- int q_type,
- int type,
- const struct sockaddr_storage *to_ss,
- fstring name);
-int remove_duplicate_addrs2(struct ip_service *iplist, int count );
-struct tevent_req *name_query_send(TALLOC_CTX *mem_ctx,
- struct tevent_context *ev,
- const char *name, int name_type,
- bool bcast, bool recurse,
- const struct sockaddr_storage *addr);
-NTSTATUS name_query_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
- struct sockaddr_storage **addrs, int *num_addrs,
- uint8_t *flags);
-NTSTATUS name_query(const char *name, int name_type,
- bool bcast, bool recurse,
- const struct sockaddr_storage *to_ss,
- TALLOC_CTX *mem_ctx,
- struct sockaddr_storage **addrs,
- int *num_addrs, uint8_t *flags);
-struct tevent_req *name_resolve_bcast_send(TALLOC_CTX *mem_ctx,
- struct tevent_context *ev,
- const char *name,
- int name_type);
-NTSTATUS name_resolve_bcast_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
- struct sockaddr_storage **addrs,
- int *num_addrs);
-NTSTATUS name_resolve_bcast(const char *name,
- int name_type,
- TALLOC_CTX *mem_ctx,
- struct sockaddr_storage **return_iplist,
- int *return_count);
-struct tevent_req *resolve_wins_send(TALLOC_CTX *mem_ctx,
- struct tevent_context *ev,
- const char *name,
- int name_type);
-NTSTATUS resolve_wins_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
- struct sockaddr_storage **addrs,
- int *num_addrs, uint8_t *flags);
-NTSTATUS resolve_wins(const char *name,
- int name_type,
- TALLOC_CTX *mem_ctx,
- struct sockaddr_storage **return_iplist,
- int *return_count);
-NTSTATUS internal_resolve_name(const char *name,
- int name_type,
- const char *sitename,
- struct ip_service **return_iplist,
- int *return_count,
- const char **resolve_order);
-bool resolve_name(const char *name,
- struct sockaddr_storage *return_ss,
- int name_type,
- bool prefer_ipv4);
-NTSTATUS resolve_name_list(TALLOC_CTX *ctx,
- const char *name,
- int name_type,
- struct sockaddr_storage **return_ss_arr,
- unsigned int *p_num_entries);
-bool find_master_ip(const char *group, struct sockaddr_storage *master_ss);
-bool get_pdc_ip(const char *domain, struct sockaddr_storage *pss);
-NTSTATUS get_sorted_dc_list( const char *domain,
- const char *sitename,
- struct ip_service **ip_list,
- int *count,
- bool ads_only );
-NTSTATUS get_kdc_list( const char *realm,
- const char *sitename,
- struct ip_service **ip_list,
- int *count);
-
/* The following definitions come from libsmb/namequery_dc.c */
bool get_dc_name(const char *domain,
fstring srv_name,
struct sockaddr_storage *ss_out);
-/* The following definitions come from libsmb/ntlmssp.c */
-struct ntlmssp_state;
-NTSTATUS ntlmssp_set_username(struct ntlmssp_state *ntlmssp_state, const char *user) ;
-NTSTATUS ntlmssp_set_password(struct ntlmssp_state *ntlmssp_state, const char *password) ;
-NTSTATUS ntlmssp_set_password_hash(struct ntlmssp_state *ntlmssp_state,
- const char *hash);
-NTSTATUS ntlmssp_set_domain(struct ntlmssp_state *ntlmssp_state, const char *domain) ;
-void ntlmssp_want_feature_list(struct ntlmssp_state *ntlmssp_state, char *feature_list);
-void ntlmssp_want_feature(struct ntlmssp_state *ntlmssp_state, uint32_t feature);
-NTSTATUS ntlmssp_update(struct ntlmssp_state *ntlmssp_state,
- const DATA_BLOB in, DATA_BLOB *out) ;
-bool ntlmssp_is_anonymous(struct ntlmssp_state *ntlmssp_state);
-NTSTATUS ntlmssp_server_start(TALLOC_CTX *mem_ctx,
- bool is_standalone,
- const char *netbios_name,
- const char *netbios_domain,
- const char *dns_name,
- const char *dns_domain,
- struct ntlmssp_state **ntlmssp_state);
-NTSTATUS ntlmssp_client_start(TALLOC_CTX *mem_ctx,
- const char *netbios_name,
- const char *netbios_domain,
- bool use_ntlmv2,
- struct ntlmssp_state **_ntlmssp_state);
-
-/* The following definitions come from libsmb/passchange.c */
-
-NTSTATUS remote_password_change(const char *remote_machine, const char *user_name,
- const char *old_passwd, const char *new_passwd,
- char **err_str);
-
-/* The following definitions come from libsmb/samlogon_cache.c */
-
-bool netsamlogon_cache_init(void);
-bool netsamlogon_cache_shutdown(void);
-void netsamlogon_clear_cached_user(const struct dom_sid *user_sid);
-bool netsamlogon_cache_store(const char *username, struct netr_SamInfo3 *info3);
-struct netr_SamInfo3 *netsamlogon_cache_get(TALLOC_CTX *mem_ctx, const struct dom_sid *user_sid);
-bool netsamlogon_cache_have(const struct dom_sid *user_sid);
-
/* The following definitions come from libsmb/smberr.c */
const char *smb_dos_err_name(uint8_t e_class, uint16_t num);
const char *smb_dos_err_class(uint8_t e_class);
WERROR map_werror_from_unix(int error);
-/* The following definitions come from libsmb/trustdom_cache.c */
-
-bool trustdom_cache_enable(void);
-bool trustdom_cache_shutdown(void);
-bool trustdom_cache_store(const char *name, const char *alt_name,
- const struct dom_sid *sid, time_t timeout);
-bool trustdom_cache_fetch(const char* name, struct dom_sid* sid);
-uint32_t trustdom_cache_fetch_timestamp( void );
-bool trustdom_cache_store_timestamp( uint32_t t, time_t timeout );
-void trustdom_cache_flush(void);
-void update_trustdom_cache( void );
-
/* The following definitions come from libsmb/trusts_util.c */
struct netlogon_creds_cli_context;
struct messaging_context;
struct dcerpc_binding_handle;
+char *trust_pw_new_value(TALLOC_CTX *mem_ctx,
+ enum netr_SchannelType sec_channel_type,
+ int security);
NTSTATUS trust_pw_change(struct netlogon_creds_cli_context *context,
struct messaging_context *msg_ctx,
struct dcerpc_binding_handle *b,
const char *domain,
+ const char *dcname,
bool force);
/* The following definitions come from param/loadparm.c */
const char *lp_idmap_default_backend (void);
int lp_security(void);
int lp_client_max_protocol(void);
-int lp_winbindd_max_protocol(void);
+int lp_client_ipc_min_protocol(void);
+int lp_client_ipc_max_protocol(void);
+int lp_client_ipc_signing(void);
int lp_smb2_max_credits(void);
int lp_cups_encrypt(void);
bool lp_widelinks(int );
+int lp_rpc_low_port(void);
+int lp_rpc_high_port(void);
+bool lp_lanman_auth(void);
int lp_wi_scan_global_parametrics(
const char *regex, size_t max_matches,
const char **lp_parm_string_list(int snum, const char *type, const char *option, const char **def);
int lp_parm_int(int snum, const char *type, const char *option, int def);
unsigned long lp_parm_ulong(int snum, const char *type, const char *option, unsigned long def);
+unsigned long long lp_parm_ulonglong(int snum, const char *type,
+ const char *option,
+ unsigned long long def);
bool lp_parm_bool(int snum, const char *type, const char *option, bool def);
struct enum_list;
int lp_parm_enum(int snum, const char *type, const char *option,
struct smb_signing_state;
bool lp_use_sendfile(int snum, struct smb_signing_state *signing_state);
void set_use_sendfile(int snum, bool val);
-void set_store_dos_attributes(int snum, bool val);
void lp_set_mangling_method(const char *new_method);
bool lp_posix_pathnames(void);
void lp_set_posix_pathnames(void);
char* get_string_param( const char* param );
/* The following definitions come from lib/server_contexts.c */
-struct tevent_context *server_event_context(void);
-void server_event_context_free(void);
-struct messaging_context *server_messaging_context(void);
-void server_messaging_context_free(void);
+struct tevent_context *global_event_context(void);
+void global_event_context_free(void);
+struct messaging_context *global_messaging_context(void);
+void global_messaging_context_free(void);
/* The following definitions come from lib/sessionid_tdb.c */
struct sessionid;
struct AvahiPoll *tevent_avahi_poll(TALLOC_CTX *mem_ctx,
struct tevent_context *ev);
-/* The following definitions come from lib/fncall.c */
-
-struct fncall_context *fncall_context_init(TALLOC_CTX *mem_ctx,
- int max_threads);
-struct tevent_req *fncall_send(TALLOC_CTX *mem_ctx, struct tevent_context *ev,
- struct fncall_context *ctx,
- void (*fn)(void *private_data),
- void *private_data);
-int fncall_recv(struct tevent_req *req, int *perr);
-
/* The following definitions come from libsmb/smbsock_connect.c */
struct tevent_req *smbsock_connect_send(TALLOC_CTX *mem_ctx,
bool lookup_wellknown_name(TALLOC_CTX *mem_ctx, const char *name,
struct dom_sid *sid, const char **domain);
-/* The following definitions come from lib/util_unixsids.c */
-
-bool sid_check_is_unix_users(const struct dom_sid *sid);
-bool sid_check_is_in_unix_users(const struct dom_sid *sid);
-void uid_to_unix_users_sid(uid_t uid, struct dom_sid *sid);
-void gid_to_unix_groups_sid(gid_t gid, struct dom_sid *sid);
-const char *unix_users_domain_name(void);
-bool lookup_unix_user_name(const char *name, struct dom_sid *sid);
-bool sid_check_is_unix_groups(const struct dom_sid *sid);
-bool sid_check_is_in_unix_groups(const struct dom_sid *sid);
-const char *unix_groups_domain_name(void);
-bool lookup_unix_group_name(const char *name, struct dom_sid *sid);
+/* The following definitions come from lib/util_specialsids.c */
+bool sid_check_is_asserted_identity(const struct dom_sid *sid);
+bool sid_check_is_in_asserted_identity(const struct dom_sid *sid);
+const char *asserted_identity_domain_name(void);
/* The following definitions come from lib/filename_util.c */
struct smb_filename *synthetic_smb_fname(TALLOC_CTX *mem_ctx,
const char *base_name,
const char *stream_name,
- const SMB_STRUCT_STAT *psbuf);
+ const SMB_STRUCT_STAT *psbuf,
+ uint32_t flags);
struct smb_filename *synthetic_smb_fname_split(TALLOC_CTX *ctx,
- const char *fname,
- const SMB_STRUCT_STAT *psbuf);
+ const char *fname,
+ bool posix_path);
const char *smb_fname_str_dbg(const struct smb_filename *smb_fname);
const char *fsp_str_dbg(const struct files_struct *fsp);
const char *fsp_fnum_dbg(const struct files_struct *fsp);
struct smb_filename *cp_smb_filename(TALLOC_CTX *mem_ctx,
const struct smb_filename *in);
+struct smb_filename *cp_smb_filename_nostream(TALLOC_CTX *mem_ctx,
+ const struct smb_filename *in);
bool is_ntfs_stream_smb_fname(const struct smb_filename *smb_fname);
bool is_ntfs_default_stream_smb_fname(const struct smb_filename *smb_fname);
bool is_invalid_windows_ea_name(const char *name);
bool ea_list_has_invalid_name(struct ea_list *ea_list);
+bool split_stream_filename(TALLOC_CTX *ctx,
+ const char *filename_in,
+ char **filename_out,
+ char **streamname_out);
/* The following definitions come from lib/dummyroot.c */
void contend_level2_oplocks_end(files_struct *fsp,
enum level2_contention_type type);
+/* The following definitions come from lib/per_thread_cwd.c */
+
+void per_thread_cwd_check(void);
+bool per_thread_cwd_supported(void);
+void per_thread_cwd_disable(void);
+void per_thread_cwd_activate(void);
+
#endif /* _PROTO_H_ */