home *** CD-ROM | disk | FTP | other *** search
/ Big Green CD 8 / BGCD_8_Dev.iso / NEXTSTEP / Networking / SambaManager / samba-1.9.17p4 / source / proto.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-03-30  |  37.6 KB  |  1,024 lines

  1. /* This file is automatically generated with "make proto". DO NOT EDIT */
  2.  
  3.  
  4. /*The following definitions come from  access.c  */
  5.  
  6. BOOL check_access(int snum);
  7. BOOL allow_access(char *deny_list,char *allow_list,char *cname,char *caddr);
  8.  
  9. /*The following definitions come from  charcnv.c  */
  10.  
  11. char *unix2dos_format(char *str,BOOL overwrite);
  12. char *dos2unix_format(char *str, BOOL overwrite);
  13. int interpret_character_set(char *str, int def);
  14.  
  15. /*The following definitions come from  charset.c  */
  16.  
  17. void charset_initialise();
  18. void codepage_initialise(int client_codepage);
  19. void add_char_string(char *s);
  20.  
  21. /*The following definitions come from  chgpasswd.c  */
  22.  
  23. BOOL chat_with_program(char *passwordprogram,char *name,char *chatsequence);
  24. BOOL chgpasswd(char *name,char *oldpass,char *newpass);
  25. BOOL chgpasswd(char *name,char *oldpass,char *newpass);
  26.  
  27. /*The following definitions come from  client.c  */
  28.  
  29. void setup_pkt(char *outbuf);
  30. void do_dir(char *inbuf,char *outbuf,char *Mask,int attribute,void (*fn)(),BOOL recurse_dir);
  31. void cmd_help(void);
  32. BOOL reopen_connection(char *inbuf,char *outbuf);
  33. char *smb_errstr(char *inbuf);
  34.  
  35. /*The following definitions come from  clientgen.c  */
  36.  
  37. BOOL cli_NetWkstaUserLogon(struct cli_state *cli,char *user, char *workstation);
  38. BOOL cli_session_setup(struct cli_state *cli, 
  39.                char *user, 
  40.                char *pass, int passlen,
  41.                char *ntpass, int ntpasslen,
  42.                char *workgroup);
  43. BOOL cli_send_tconX(struct cli_state *cli, 
  44.             char *share, char *dev, char *pword, int passlen);
  45. BOOL cli_tdis(struct cli_state *cli);
  46. BOOL cli_negprot(struct cli_state *cli);
  47. BOOL cli_session_request(struct cli_state *cli, char *host, int name_type,
  48.              char *myname);
  49. BOOL cli_connect(struct cli_state *cli, char *host, struct in_addr *ip);
  50. BOOL cli_initialise(struct cli_state *cli);
  51. void cli_shutdown(struct cli_state *cli);
  52.  
  53. /*The following definitions come from  clientutil.c  */
  54.  
  55. BOOL cli_send_login(char *inbuf, char *outbuf, BOOL start_session, BOOL use_setup);
  56. void cli_send_logout(void);
  57. BOOL cli_call_api(int prcnt,int drcnt,int mprcnt,int mdrcnt,int *rprcnt,
  58.           int *rdrcnt, char *param,char *data, 
  59.           char **rparam, char **rdata);
  60. BOOL cli_open_sockets(int port);
  61. BOOL cli_reopen_connection(char *inbuf,char *outbuf);
  62. char *smb_errstr(char *inbuf);
  63.  
  64. /*The following definitions come from  clitar.c  */
  65.  
  66. int padit(char *buf, int bufsize, int padsize);
  67. void cmd_block(void);
  68. void cmd_tarmode(void);
  69. void cmd_setmode(void);
  70. void cmd_tar(char *inbuf, char *outbuf);
  71. int process_tar(char *inbuf, char *outbuf);
  72. int clipfind(char **aret, int ret, char *tok);
  73. int tar_parseargs(int argc, char *argv[], char *Optarg, int Optind);
  74.  
  75. /*The following definitions come from  dir.c  */
  76.  
  77. void init_dptrs(void);
  78. char *dptr_path(int key);
  79. char *dptr_wcard(int key);
  80. BOOL dptr_set_wcard(int key, char *wcard);
  81. BOOL dptr_set_attr(int key, uint16 attr);
  82. uint16 dptr_attr(int key);
  83. void dptr_close(int key);
  84. void dptr_closecnum(int cnum);
  85. void dptr_idlecnum(int cnum);
  86. void dptr_closepath(char *path,int pid);
  87. int dptr_create(int cnum,char *path, BOOL expect_close,int pid);
  88. BOOL dptr_fill(char *buf1,unsigned int key);
  89. BOOL dptr_zero(char *buf);
  90. void *dptr_fetch(char *buf,int *num);
  91. void *dptr_fetch_lanman2(char *params,int dptr_num);
  92. BOOL dir_check_ftype(int cnum,int mode,struct stat *st,int dirtype);
  93. BOOL get_dir_entry(int cnum,char *mask,int dirtype,char *fname,int *size,int *mode,time_t *date,BOOL check_descend);
  94. void *OpenDir(int cnum, char *name, BOOL use_veto);
  95. void CloseDir(void *p);
  96. char *ReadDirName(void *p);
  97. BOOL SeekDir(void *p,int pos);
  98. int TellDir(void *p);
  99. void DirCacheAdd(char *path,char *name,char *dname,int snum);
  100. char *DirCacheCheck(char *path,char *name,int snum);
  101. void DirCacheFlush(int snum);
  102.  
  103. /*The following definitions come from  fault.c  */
  104.  
  105. void fault_setup(void (*fn)());
  106.  
  107. /*The following definitions come from  getsmbpass.c  */
  108.  
  109. char *getsmbpass(char *prompt)    ;
  110.  
  111. /*The following definitions come from  interface.c  */
  112.  
  113. void load_interfaces(void);
  114. void iface_set_default(char *ip,char *bcast,char *nmask);
  115. BOOL ismyip(struct in_addr ip);
  116. BOOL ismybcast(struct in_addr bcast);
  117. int iface_count(void);
  118. struct in_addr *iface_n_ip(int n);
  119. struct in_addr *iface_bcast(struct in_addr ip);
  120. struct in_addr *iface_nmask(struct in_addr ip);
  121. struct in_addr *iface_ip(struct in_addr ip);
  122.  
  123. /*The following definitions come from  ipc.c  */
  124.  
  125. int reply_trans(char *inbuf,char *outbuf);
  126.  
  127. /*The following definitions come from  kanji.c  */
  128.  
  129. int interpret_coding_system(char *str, int def);
  130.  
  131. /*The following definitions come from  loadparm.c  */
  132.  
  133. char *lp_string(char *s);
  134. char *lp_logfile(void);
  135. char *lp_smbrun(void);
  136. char *lp_configfile(void);
  137. char *lp_smb_passwd_file(void);
  138. char *lp_serverstring(void);
  139. char *lp_printcapname(void);
  140. char *lp_lockdir(void);
  141. char *lp_rootdir(void);
  142. char *lp_defaultservice(void);
  143. char *lp_msg_command(void);
  144. char *lp_dfree_command(void);
  145. char *lp_hosts_equiv(void);
  146. char *lp_auto_services(void);
  147. char *lp_passwd_program(void);
  148. char *lp_passwd_chat(void);
  149. char *lp_passwordserver(void);
  150. char *lp_workgroup(void);
  151. char *lp_domain_controller(void);
  152. char *lp_username_map(void);
  153. char *lp_character_set(void);
  154. char *lp_logon_script(void);
  155. char *lp_logon_path(void);
  156. char *lp_remote_announce(void);
  157. char *lp_wins_server(void);
  158. char *lp_interfaces(void);
  159. char *lp_socket_address(void);
  160. char *lp_nis_home_map_name(void);
  161. char *lp_announce_version(void);
  162. char *lp_netbios_aliases(void);
  163. BOOL lp_dns_proxy(void);
  164. BOOL lp_wins_support(void);
  165. BOOL lp_wins_proxy(void);
  166. BOOL lp_local_master(void);
  167. BOOL lp_domain_master(void);
  168. BOOL lp_domain_logons(void);
  169. BOOL lp_preferred_master(void);
  170. BOOL lp_load_printers(void);
  171. BOOL lp_use_rhosts(void);
  172. BOOL lp_getwdcache(void);
  173. BOOL lp_readprediction(void);
  174. BOOL lp_readbmpx(void);
  175. BOOL lp_readraw(void);
  176. BOOL lp_writeraw(void);
  177. BOOL lp_null_passwords(void);
  178. BOOL lp_strip_dot(void);
  179. BOOL lp_encrypted_passwords(void);
  180. BOOL lp_syslog_only(void);
  181. BOOL lp_browse_list(void);
  182. BOOL lp_unix_realname(void);
  183. BOOL lp_nis_home_map(void);
  184. BOOL lp_time_server(void);
  185. int lp_os_level(void);
  186. int lp_max_ttl(void);
  187. int lp_max_log_size(void);
  188. int lp_mangledstack(void);
  189. int lp_maxxmit(void);
  190. int lp_maxmux(void);
  191. int lp_maxpacket(void);
  192. int lp_keepalive(void);
  193. int lp_passwordlevel(void);
  194. int lp_readsize(void);
  195. int lp_shmem_size(void);
  196. int lp_shmem_hash_size(void);
  197. int lp_deadtime(void);
  198. int lp_maxprotocol(void);
  199. int lp_security(void);
  200. int lp_printing(void);
  201. int lp_maxdisksize(void);
  202. int lp_lpqcachetime(void);
  203. int lp_syslog(void);
  204. int lp_client_code_page(void);
  205. int lp_announce_as(void);
  206. char *lp_preexec(int );
  207. char *lp_postexec(int );
  208. char *lp_rootpreexec(int );
  209. char *lp_rootpostexec(int );
  210. char *lp_servicename(int );
  211. char *lp_pathname(int );
  212. char *lp_dontdescend(int );
  213. char *lp_username(int );
  214. char *lp_guestaccount(int );
  215. char *lp_invalid_users(int );
  216. char *lp_valid_users(int );
  217. char *lp_admin_users(int );
  218. char *lp_printcommand(int );
  219. char *lp_lpqcommand(int );
  220. char *lp_lprmcommand(int );
  221. char *lp_lppausecommand(int );
  222. char *lp_lpresumecommand(int );
  223. char *lp_printername(int );
  224. char *lp_printerdriver(int );
  225. char *lp_hostsallow(int );
  226. char *lp_hostsdeny(int );
  227. char *lp_magicscript(int );
  228. char *lp_magicoutput(int );
  229. char *lp_comment(int );
  230. char *lp_force_user(int );
  231. char *lp_force_group(int );
  232. char *lp_readlist(int );
  233. char *lp_writelist(int );
  234. char *lp_volume(int );
  235. char *lp_mangled_map(int );
  236. char *lp_veto_files(int );
  237. char *lp_hide_files(int );
  238. BOOL lp_alternate_permissions(int );
  239. BOOL lp_revalidate(int );
  240. BOOL lp_casesensitive(int );
  241. BOOL lp_preservecase(int );
  242. BOOL lp_shortpreservecase(int );
  243. BOOL lp_casemangle(int );
  244. BOOL lp_status(int );
  245. BOOL lp_hide_dot_files(int );
  246. BOOL lp_browseable(int );
  247. BOOL lp_readonly(int );
  248. BOOL lp_no_set_dir(int );
  249. BOOL lp_guest_ok(int );
  250. BOOL lp_guest_only(int );
  251. BOOL lp_print_ok(int );
  252. BOOL lp_postscript(int );
  253. BOOL lp_map_hidden(int );
  254. BOOL lp_map_archive(int );
  255. BOOL lp_locking(int );
  256. BOOL lp_strict_locking(int );
  257. BOOL lp_share_modes(int );
  258. BOOL lp_onlyuser(int );
  259. BOOL lp_manglednames(int );
  260. BOOL lp_widelinks(int );
  261. BOOL lp_symlinks(int );
  262. BOOL lp_syncalways(int );
  263. BOOL lp_map_system(int );
  264. BOOL lp_delete_readonly(int );
  265. BOOL lp_fake_oplocks(int );
  266. BOOL lp_dos_filetimes(int );
  267. int lp_create_mode(int );
  268. int lp_force_create_mode(int );
  269. int lp_dir_mode(int );
  270. int lp_force_dir_mode(int );
  271. int lp_max_connections(int );
  272. int lp_defaultcase(int );
  273. int lp_minprintspace(int );
  274. char lp_magicchar(int );
  275. BOOL lp_add_home(char *pszHomename, int iDefaultService, char *pszHomedir);
  276. int lp_add_service(char *pszService, int iDefaultService);
  277. BOOL lp_add_printer(char *pszPrintername, int iDefaultService);
  278. BOOL lp_file_list_changed(void);
  279. BOOL lp_snum_ok(int iService);
  280. BOOL lp_loaded(void);
  281. void lp_killunused(BOOL (*snumused)(int ));
  282. BOOL lp_load(char *pszFname,BOOL global_only);
  283. int lp_numservices(void);
  284. void lp_dump(void);
  285. int lp_servicenumber(char *pszServiceName);
  286. char *volume_label(int snum);
  287. int lp_default_server_announce(void);
  288. int lp_major_announce_version(void);
  289. int lp_minor_announce_version(void);
  290.  
  291. /*The following definitions come from  locking.c  */
  292.  
  293. BOOL is_locked(int fnum,int cnum,uint32 count,uint32 offset);
  294. BOOL do_lock(int fnum,int cnum,uint32 count,uint32 offset,int *eclass,uint32 *ecode);
  295. BOOL do_unlock(int fnum,int cnum,uint32 count,uint32 offset,int *eclass,uint32 *ecode);
  296. BOOL start_share_mode_mgmt(void);
  297. BOOL stop_share_mode_mgmt(void);
  298. BOOL lock_share_entry(int cnum, uint32 dev, uint32 inode, share_lock_token *ptok);
  299. BOOL unlock_share_entry(int cnum, uint32 dev, uint32 inode, share_lock_token token);
  300. int get_share_modes(int cnum, share_lock_token token, uint32 dev, uint32 inode, 
  301.                     min_share_mode_entry **old_shares);
  302. void del_share_mode(share_lock_token token, int fnum);
  303. BOOL set_share_mode(share_lock_token token, int fnum);
  304. BOOL lock_share_entry(int cnum, uint32 dev, uint32 inode, share_lock_token *ptok);
  305. BOOL unlock_share_entry(int cnum, uint32 dev, uint32 inode, share_lock_token token);
  306. int get_share_modes(int cnum, share_lock_token token, uint32 dev, uint32 inode, 
  307.                     min_share_mode_entry **old_shares);
  308. void del_share_mode(share_lock_token token, int fnum);
  309. BOOL set_share_mode(share_lock_token token,int fnum);
  310.  
  311. /*The following definitions come from  mangle.c  */
  312.  
  313. int str_checksum(char *s);
  314. BOOL is_8_3(char *fname, BOOL check_case);
  315. void create_mangled_stack(int size);
  316. BOOL check_mangled_stack(char *s);
  317. BOOL is_mangled(char *s);
  318. void mangle_name_83(char *s);
  319. BOOL name_map_mangle(char *OutName,BOOL need83,int snum);
  320.  
  321. /*The following definitions come from  md4.c  */
  322.  
  323.  
  324. /*The following definitions come from  message.c  */
  325.  
  326. int reply_sends(char *inbuf,char *outbuf);
  327. int reply_sendstrt(char *inbuf,char *outbuf);
  328. int reply_sendtxt(char *inbuf,char *outbuf);
  329. int reply_sendend(char *inbuf,char *outbuf);
  330.  
  331. /*The following definitions come from  nameannounce.c  */
  332.  
  333. void announce_request(struct work_record *work, struct in_addr ip);
  334. void do_announce_request(char *info, char *to_name, int announce_type, 
  335.              int from,
  336.              int to, struct in_addr dest_ip);
  337. void sync_server(enum state_type state, char *serv_name, char *work_name, 
  338.          int name_type,
  339.                  struct subnet_record *d,
  340.          struct in_addr ip);
  341. void do_announce_host(int command,
  342.         char *from_name, int from_type, struct in_addr from_ip,
  343.         char *to_name  , int to_type  , struct in_addr to_ip,
  344.         time_t announce_interval,
  345.         char *server_name, int server_type, char *server_comment);
  346. void announce_my_servers_removed(void);
  347. void announce_server(struct subnet_record *d, struct work_record *work,
  348.              char *name, char *comment, time_t ttl, int server_type);
  349. void announce_host(time_t t);
  350. void reset_announce_timer();
  351. void announce_master(time_t t);
  352. void announce_remote(time_t t);
  353.  
  354. /*The following definitions come from  namebrowse.c  */
  355.  
  356. void expire_browse_cache(time_t t);
  357. struct browse_cache_record *add_browser_entry(char *name, int type, char *wg,
  358.                           time_t ttl, struct subnet_record *d,
  359.                                               struct in_addr ip, BOOL local);
  360. void do_browser_lists(time_t t);
  361.  
  362. /*The following definitions come from  nameconf.c  */
  363.  
  364. int get_num_workgroups(void);
  365. int conf_workgroup_name_to_token(char *workgroup_name,char *default_name);
  366. char *conf_workgroup_name(int token);
  367. int conf_should_workgroup_member(int token);
  368. int conf_should_local_master(int token);
  369. int conf_should_domain_master(int token);
  370. char *conf_browsing_alias(int token);
  371. char *conf_browsing_alias_comment(int token);
  372. char *conf_alias_to_workgroup(char *alias);
  373. int conf_alias_to_token(char *alias);
  374. void read_smbbrowse_conf(char *default_name);
  375.  
  376. /*The following definitions come from  namedbname.c  */
  377.  
  378. void set_samba_nb_type(void);
  379. BOOL name_equal(struct nmb_name *n1,struct nmb_name *n2);
  380. BOOL ms_browser_name(char *name, int type);
  381. void remove_name(struct subnet_record *d, struct name_record *n);
  382. struct name_record *find_name(struct name_record *n,
  383.             struct nmb_name *name, int search);
  384. struct name_record *find_name_search(struct subnet_record **d,
  385.             struct nmb_name *name,
  386.             int search, struct in_addr ip);
  387. void dump_names(void);
  388. void load_netbios_names(void);
  389. void remove_netbios_name(struct subnet_record *d,
  390.             char *name,int type, enum name_source source,
  391.              struct in_addr ip);
  392. struct name_record *add_netbios_entry(struct subnet_record *d,
  393.         char *name, int type, int nb_flags, 
  394.         int ttl, enum name_source source, struct in_addr ip,
  395.         BOOL new_only,BOOL wins);
  396. void expire_names(time_t t);
  397. struct name_record *dns_name_search(struct nmb_name *question, int Time);
  398.  
  399. /*The following definitions come from  namedbresp.c  */
  400.  
  401. void add_response_record(struct subnet_record *d,
  402.                 struct response_record *n);
  403. void remove_response_record(struct subnet_record *d,
  404.                 struct response_record *n);
  405. struct response_record *make_response_queue_record(enum state_type state,
  406.                 int id,uint16 fd,
  407.                 int quest_type, char *name,int type, int nb_flags, time_t ttl,
  408.                 int server_type, char *my_name, char *my_comment,
  409.                 BOOL bcast,BOOL recurse,
  410.                 struct in_addr send_ip, struct in_addr reply_to_ip,
  411.                 int reply_id);
  412. struct response_record *find_response_record(struct subnet_record **d,
  413.                 uint16 id);
  414.  
  415. /*The following definitions come from  namedbserver.c  */
  416.  
  417. void remove_old_servers(struct work_record *work, time_t t,
  418.                     BOOL remove_all);
  419. struct server_record *find_server(struct work_record *work, char *name);
  420. struct server_record *add_server_entry(struct subnet_record *d, 
  421.                        struct work_record *work,
  422.                        char *name,int servertype, 
  423.                        int ttl,char *comment,
  424.                        BOOL replace);
  425. void expire_servers(time_t t);
  426.  
  427. /*The following definitions come from  namedbsubnet.c  */
  428.  
  429. struct subnet_record *find_subnet(struct in_addr bcast_ip);
  430. struct subnet_record *find_req_subnet(struct in_addr ip, BOOL bcast);
  431. struct subnet_record *find_subnet_all(struct in_addr bcast_ip);
  432. void add_workgroup_to_subnet( struct subnet_record *d, char *group);
  433. void add_my_subnets(char *group);
  434. void write_browse_list(time_t t);
  435.  
  436. /*The following definitions come from  namedbwork.c  */
  437.  
  438. struct work_record *remove_workgroup(struct subnet_record *d, 
  439.                      struct work_record *work,
  440.                      BOOL remove_all_servers);
  441. struct work_record *find_workgroupstruct(struct subnet_record *d, 
  442.                      fstring name, BOOL add);
  443. void dump_workgroups(void);
  444.  
  445. /*The following definitions come from  nameelect.c  */
  446.  
  447. void check_master_browser(time_t t);
  448. void browser_gone(char *work_name, struct in_addr ip);
  449. void send_election(struct subnet_record *d, char *group,uint32 criterion,
  450.            int timeup,char *name);
  451. void name_unregister_work(struct subnet_record *d, char *name, int name_type);
  452. void name_register_work(struct subnet_record *d, char *name, int name_type,
  453.                 int nb_flags, time_t ttl, struct in_addr ip, BOOL bcast);
  454. void become_local_master(struct subnet_record *d, struct work_record *work);
  455. void become_domain_master(struct subnet_record *d, struct work_record *work);
  456. void become_logon_server(struct subnet_record *d, struct work_record *work);
  457. void unbecome_local_master(struct subnet_record *d, struct work_record *work,
  458.                 int remove_type);
  459. void unbecome_domain_master(struct subnet_record *d, struct work_record *work,
  460.                 int remove_type);
  461. void unbecome_logon_server(struct subnet_record *d, struct work_record *work,
  462.                 int remove_type);
  463. void run_elections(time_t t);
  464. void process_election(struct packet_struct *p,char *buf);
  465. BOOL check_elections(void);
  466.  
  467. /*The following definitions come from  namelogon.c  */
  468.  
  469. void process_logon_packet(struct packet_struct *p,char *buf,int len);
  470.  
  471. /*The following definitions come from  namepacket.c  */
  472.  
  473. void debug_browse_data(char *outbuf, int len);
  474. void initiate_netbios_packet(uint16 *id,
  475.                  int fd,int quest_type,char *name,int name_type,
  476.                  int nb_flags,BOOL bcast,BOOL recurse,
  477.                  struct in_addr to_ip);
  478. void reply_netbios_packet(struct packet_struct *p1,int trn_id,
  479.                 int rcode, int rcv_code, int opcode,
  480.                 BOOL recursion_available,
  481.                 BOOL recursion_desired,
  482.                 struct nmb_name *rr_name,int rr_type,int rr_class,int ttl,
  483.                 char *data,int len);
  484. void queue_packet(struct packet_struct *packet);
  485. void run_packet_queue();
  486. void listen_for_packets(BOOL run_election);
  487. BOOL send_mailslot_reply(BOOL unique, char *mailslot,int fd,char *buf,int len,char *srcname,
  488.              char *dstname,int src_type,int dest_type,
  489.              struct in_addr dest_ip,struct in_addr src_ip);
  490.  
  491. /*The following definitions come from  namequery.c  */
  492.  
  493. BOOL name_status(int fd,char *name,int name_type,BOOL recurse,
  494.          struct in_addr to_ip,char *master,char *rname,
  495.          void (*fn)());
  496. BOOL name_query(int fd,char *name,int name_type, 
  497.         BOOL bcast,BOOL recurse,
  498.         struct in_addr to_ip, struct in_addr *ip,void (*fn)());
  499.  
  500. /*The following definitions come from  nameresp.c  */
  501.  
  502. void expire_netbios_response_entries(time_t t);
  503. struct response_record *queue_netbios_pkt_wins(
  504.                 int fd,int quest_type,enum state_type state,
  505.                 char *name,int name_type,int nb_flags, time_t ttl,
  506.                 int server_type, char *my_name, char *my_comment,
  507.                 struct in_addr send_ip, struct in_addr reply_to_ip);
  508. struct response_record *queue_netbios_packet(struct subnet_record *d,
  509.             int fd,int quest_type,enum state_type state,char *name,
  510.             int name_type,int nb_flags, time_t ttl,
  511.             int server_type, char *my_name, char *my_comment,
  512.             BOOL bcast,BOOL recurse,
  513.             struct in_addr send_ip, struct in_addr reply_to_ip,
  514.             int reply_id);
  515.  
  516. /*The following definitions come from  nameserv.c  */
  517.  
  518. void remove_name_entry(struct subnet_record *d, char *name,int type);
  519. void add_my_name_entry(struct subnet_record *d,char *name,int type,int nb_flags);
  520. void add_domain_logon_names(void);
  521. void add_domain_master_bcast(void);
  522. void add_domain_master_wins(void);
  523. void add_domain_names(time_t t);
  524. void add_my_names(void);
  525. void remove_my_names();
  526. void refresh_my_names(time_t t);
  527. void query_refresh_names(time_t t);
  528.  
  529. /*The following definitions come from  nameservreply.c  */
  530.  
  531. void add_name_respond(struct subnet_record *d, int fd, struct in_addr from_ip,
  532.                 uint16 response_id,
  533.                 struct nmb_name *name,
  534.                 int nb_flags, int ttl, struct in_addr register_ip,
  535.                 BOOL new_owner, struct in_addr reply_to_ip);
  536. void reply_name_release(struct packet_struct *p);
  537. void reply_name_reg(struct packet_struct *p);
  538. void reply_name_status(struct packet_struct *p);
  539. void reply_name_query(struct packet_struct *p);
  540.  
  541. /*The following definitions come from  nameservresp.c  */
  542.  
  543. void debug_state_type(int state);
  544. void response_netbios_packet(struct packet_struct *p);
  545.  
  546. /*The following definitions come from  namework.c  */
  547.  
  548. void reset_server(char *name, int state, struct in_addr ip);
  549. void tell_become_backup(void);
  550. BOOL same_context(struct dgram_packet *dgram);
  551. void process_browse_packet(struct packet_struct *p,char *buf,int len);
  552.  
  553. /*The following definitions come from  nmbd.c  */
  554.  
  555. BOOL reload_services(BOOL test);
  556.  
  557. /*The following definitions come from  nmblib.c  */
  558.  
  559. void debug_nmb_packet(struct packet_struct *p);
  560. char *namestr(struct nmb_name *n);
  561. void free_nmb_packet(struct nmb_packet *nmb);
  562. void free_packet(struct packet_struct *packet);
  563. struct packet_struct *read_packet(int fd,enum packet_type packet_type);
  564. void make_nmb_name(struct nmb_name *n,char *name,int type,char *this_scope);
  565. BOOL send_packet(struct packet_struct *p);
  566. struct packet_struct *receive_packet(int fd,enum packet_type type,int t);
  567.  
  568. /*The following definitions come from  nmblookup.c  */
  569.  
  570. int main(int argc,char *argv[]);
  571.  
  572. /*The following definitions come from  nmbsync.c  */
  573.  
  574. char *getsmbpass(char *pass);
  575. void sync_browse_lists(struct subnet_record *d, struct work_record *work,
  576.         char *name, int nm_type, struct in_addr ip, BOOL local);
  577.  
  578. /*The following definitions come from  params.c  */
  579.  
  580. BOOL pm_process(char *pszFileName,BOOL (*sfunc)(char *),BOOL (*pfunc)(char *,char *));
  581.  
  582. /*The following definitions come from  password.c  */
  583.  
  584. void generate_next_challenge(char *challenge);
  585. BOOL set_challenge(char *challenge);
  586. BOOL last_challenge(char *challenge);
  587. user_struct *get_valid_user_struct(uint16 vuid);
  588. void invalidate_vuid(uint16 vuid);
  589. char *validated_username(uint16 vuid);
  590. uint16 register_vuid(int uid,int gid, char *name,BOOL guest);
  591. void add_session_user(char *user);
  592. void dfs_unlogin(void);
  593. BOOL password_check(char *password);
  594. BOOL smb_password_check(char *password, unsigned char *part_passwd, unsigned char *c8);
  595. BOOL password_ok(char *user,char *password, int pwlen, struct passwd *pwd);
  596. BOOL user_ok(char *user,int snum);
  597. BOOL authorise_login(int snum,char *user,char *password, int pwlen, 
  598.              BOOL *guest,BOOL *force,uint16 vuid);
  599. BOOL check_hosts_equiv(char *user);
  600. struct cli_state *server_client(void);
  601. struct cli_state *server_cryptkey(void);
  602. BOOL server_validate(char *user, char *domain, 
  603.              char *pass, int passlen,
  604.              char *ntpass, int ntpasslen);
  605.  
  606. /*The following definitions come from  pcap.c  */
  607.  
  608. BOOL pcap_printername_ok(char *pszPrintername, char *pszPrintcapname);
  609. void pcap_printer_fn(void (*fn)());
  610.  
  611. /*The following definitions come from  pipes.c  */
  612.  
  613. int reply_open_pipe_and_X(char *inbuf,char *outbuf,int length,int bufsize);
  614. BOOL api_LsarpcSNPHS(int cnum,int uid, char *param,char *data,
  615.              int mdrcnt,int mprcnt,
  616.              char **rdata,char **rparam,
  617.              int *rdata_len,int *rparam_len);
  618. BOOL api_LsarpcTNP(int cnum,int uid, char *param,char *data,
  619.              int mdrcnt,int mprcnt,
  620.              char **rdata,char **rparam,
  621.              int *rdata_len,int *rparam_len);
  622.  
  623. /*The following definitions come from  predict.c  */
  624.  
  625. int read_predict(int fd,int offset,char *buf,char **ptr,int num);
  626. void do_read_prediction();
  627. void invalidate_read_prediction(int fd);
  628.  
  629. /*The following definitions come from  printing.c  */
  630.  
  631. void lpq_reset(int snum);
  632. void print_file(int fnum);
  633. int get_printqueue(int snum,int cnum,print_queue_struct **queue,
  634.            print_status_struct *status);
  635. void del_printqueue(int cnum,int snum,int jobid);
  636. void status_printjob(int cnum,int snum,int jobid,int status);
  637. int printjob_encode(int snum, int job);
  638. void printjob_decode(int jobid, int *snum, int *job);
  639.  
  640. /*The following definitions come from  quotas.c  */
  641.  
  642. BOOL disk_quotas(char *path, int *bsize, int *dfree, int *dsize);
  643. BOOL disk_quotas(char *path, int *bsize, int *dfree, int *dsize);
  644. BOOL disk_quotas(char *path, int *bsize, int *dfree, int *dsize);
  645. BOOL disk_quotas(char *path, int *bsize, int *dfree, int *dsize);
  646. BOOL disk_quotas(char *path, int *bsize, int *dfree, int *dsize);
  647.  
  648. /*The following definitions come from  replace.c  */
  649.  
  650. char *Strstr(char *s, char *p);
  651. time_t Mktime(struct tm      *t);
  652. int InNetGr(char *group,char *host,char *user,char *dom);
  653. void *malloc_wrapped(int size,char *file,int line);
  654. void *realloc_wrapped(void *ptr,int size,char *file,int line);
  655. void free_wrapped(void *ptr,char *file,int line);
  656. void *memcpy_wrapped(void *d,void *s,int l,char *fname,int line);
  657.  
  658. /*The following definitions come from  reply.c  */
  659.  
  660. int reply_special(char *inbuf,char *outbuf);
  661. int reply_tcon(char *inbuf,char *outbuf);
  662. int reply_tcon_and_X(char *inbuf,char *outbuf,int length,int bufsize);
  663. int reply_unknown(char *inbuf,char *outbuf);
  664. int reply_ioctl(char *inbuf,char *outbuf);
  665. int reply_sesssetup_and_X(char *inbuf,char *outbuf,int length,int bufsize);
  666. int reply_chkpth(char *inbuf,char *outbuf);
  667. int reply_getatr(char *inbuf,char *outbuf);
  668. int reply_setatr(char *inbuf,char *outbuf);
  669. int reply_dskattr(char *inbuf,char *outbuf);
  670. int reply_search(char *inbuf,char *outbuf);
  671. int reply_fclose(char *inbuf,char *outbuf);
  672. int reply_open(char *inbuf,char *outbuf);
  673. int reply_open_and_X(char *inbuf,char *outbuf,int length,int bufsize);
  674. int reply_ulogoffX(char *inbuf,char *outbuf,int length,int bufsize);
  675. int reply_mknew(char *inbuf,char *outbuf);
  676. int reply_ctemp(char *inbuf,char *outbuf);
  677. int reply_unlink(char *inbuf,char *outbuf);
  678. int reply_readbraw(char *inbuf, char *outbuf);
  679. int reply_lockread(char *inbuf,char *outbuf);
  680. int reply_read(char *inbuf,char *outbuf);
  681. int reply_read_and_X(char *inbuf,char *outbuf,int length,int bufsize);
  682. int reply_writebraw(char *inbuf,char *outbuf);
  683. int reply_writeunlock(char *inbuf,char *outbuf);
  684. int reply_write(char *inbuf,char *outbuf,int dum1,int dum2);
  685. int reply_write_and_X(char *inbuf,char *outbuf,int length,int bufsize);
  686. int reply_lseek(char *inbuf,char *outbuf);
  687. int reply_flush(char *inbuf,char *outbuf);
  688. int reply_exit(char *inbuf,char *outbuf);
  689. int reply_close(char *inbuf,char *outbuf);
  690. int reply_writeclose(char *inbuf,char *outbuf);
  691. int reply_lock(char *inbuf,char *outbuf);
  692. int reply_unlock(char *inbuf,char *outbuf);
  693. int reply_tdis(char *inbuf,char *outbuf);
  694. int reply_echo(char *inbuf,char *outbuf);
  695. int reply_printopen(char *inbuf,char *outbuf);
  696. int reply_printclose(char *inbuf,char *outbuf);
  697. int reply_printqueue(char *inbuf,char *outbuf);
  698. int reply_printwrite(char *inbuf,char *outbuf);
  699. int reply_mkdir(char *inbuf,char *outbuf);
  700. int reply_rmdir(char *inbuf,char *outbuf);
  701. int reply_mv(char *inbuf,char *outbuf);
  702. int reply_copy(char *inbuf,char *outbuf);
  703. int reply_setdir(char *inbuf,char *outbuf);
  704. int reply_lockingX(char *inbuf,char *outbuf,int length,int bufsize);
  705. int reply_readbmpx(char *inbuf,char *outbuf,int length,int bufsize);
  706. int reply_writebmpx(char *inbuf,char *outbuf);
  707. int reply_writebs(char *inbuf,char *outbuf);
  708. int reply_setattrE(char *inbuf,char *outbuf);
  709. int reply_getattrE(char *inbuf,char *outbuf);
  710.  
  711. /*The following definitions come from  server.c  */
  712.  
  713. void  *dflt_sig(void);
  714. void  killkids(void);
  715. mode_t unix_mode(int cnum,int dosmode);
  716. int dos_mode(int cnum,char *path,struct stat *sbuf);
  717. int dos_chmod(int cnum,char *fname,int dosmode,struct stat *st);
  718. int file_utime(int cnum, char *fname, struct utimbuf *times);
  719. BOOL set_filetime(int cnum, char *fname, time_t mtime);
  720. BOOL unix_convert(char *name,int cnum,pstring saved_last_component, BOOL *bad_path);
  721. int disk_free(char *path,int *bsize,int *dfree,int *dsize);
  722. int sys_disk_free(char *path,int *bsize,int *dfree,int *dsize);
  723. BOOL check_name(char *name,int cnum);
  724. int fd_attempt_open(char *fname, int flags, int mode);
  725. void fd_attempt_reopen(char *fname, int mode, file_fd_struct *fd_ptr);
  726. int fd_attempt_close(file_fd_struct *fd_ptr);
  727. void sync_file(int fnum);
  728. void close_file(int fnum, int normal_close);
  729. BOOL check_file_sharing(int cnum,char *fname);
  730. void open_file_shared(int fnum,int cnum,char *fname,int share_mode,int ofun,
  731.               int mode,int *Access,int *action);
  732. int seek_file(int fnum,uint32 pos);
  733. int read_file(int fnum,char *data,uint32 pos,int n);
  734. int write_file(int fnum,char *data,int n);
  735. BOOL become_service(int cnum,BOOL do_chdir);
  736. int find_service(char *service);
  737. int cached_error_packet(char *inbuf,char *outbuf,int fnum,int line);
  738. int unix_error_packet(char *inbuf,char *outbuf,int def_class,uint32 def_code,int line);
  739. int error_packet(char *inbuf,char *outbuf,int error_class,uint32 error_code,int line);
  740. BOOL snum_used(int snum);
  741. BOOL reload_services(BOOL test);
  742. int setup_groups(char *user, int uid, int gid, int *p_ngroups, 
  743.          int **p_igroups, gid_t **p_groups);
  744. int make_connection(char *service,char *user,char *password, int pwlen, char *dev,uint16 vuid);
  745. int find_free_file(void );
  746. int reply_corep(char *outbuf);
  747. int reply_coreplus(char *outbuf);
  748. int reply_lanman1(char *outbuf);
  749. int reply_lanman2(char *outbuf);
  750. int reply_nt1(char *outbuf);
  751. void close_cnum(int cnum, uint16 vuid);
  752. BOOL yield_connection(int cnum,char *name,int max_connections);
  753. BOOL claim_connection(int cnum,char *name,int max_connections,BOOL Clear);
  754. void exit_server(char *reason);
  755. void standard_sub(int cnum,char *str);
  756. char *smb_fn_name(int type);
  757. int chain_reply(char *inbuf,char *outbuf,int size,int bufsize);
  758. int construct_reply(char *inbuf,char *outbuf,int size,int bufsize);
  759.  
  760. /*The following definitions come from  shmem.c  */
  761.  
  762. BOOL smb_shm_create_hash_table( unsigned int size );
  763. BOOL smb_shm_open( char *file_name, int size);
  764. BOOL smb_shm_close( void );
  765. smb_shm_offset_t smb_shm_alloc(int size);
  766. BOOL smb_shm_free(smb_shm_offset_t offset);
  767. smb_shm_offset_t smb_shm_get_userdef_off(void);
  768. BOOL smb_shm_set_userdef_off(smb_shm_offset_t userdef_off);
  769. void * smb_shm_offset2addr(smb_shm_offset_t offset);
  770. smb_shm_offset_t smb_shm_addr2offset(void *addr);
  771. BOOL smb_shm_lock_hash_entry( unsigned int entry);
  772. BOOL smb_shm_unlock_hash_entry( unsigned int entry );
  773. BOOL smb_shm_get_usage(int *bytes_free,
  774.            int *bytes_used,
  775.            int *bytes_overhead);
  776.  
  777. /*The following definitions come from  smbencrypt.c  */
  778.  
  779. void str_to_key(uchar *str,uchar *key);
  780. void D1(uchar *k, uchar *d, uchar *out);
  781. void E1(uchar *k, uchar *d, uchar *out);
  782. void E_P16(uchar *p14,uchar *p16);
  783. void E_P24(uchar *p21, uchar *c8, uchar *p24);
  784. void SMBencrypt(uchar *passwd, uchar *c8, uchar *p24);
  785. void E_md4hash(uchar *passwd, uchar *p16);
  786. void SMBNTencrypt(uchar *passwd, uchar *c8, uchar *p24);
  787.  
  788. /*The following definitions come from  smbpass.c  */
  789.  
  790. int pw_file_lock(char *name, int type, int secs);
  791. int pw_file_unlock(int fd);
  792. struct smb_passwd *get_smbpwnam(char *name);
  793.  
  794. /*The following definitions come from  smbpasswd.c  */
  795.  
  796.  
  797. /*The following definitions come from  smbrun.c  */
  798.  
  799.  
  800. /*The following definitions come from  status.c  */
  801.  
  802. void Ucrit_addUsername(pstring username);
  803. unsigned int Ucrit_checkUsername(pstring username);
  804. void Ucrit_addPid(int pid);
  805. unsigned int   Ucrit_checkPid(int pid);
  806.  
  807. /*The following definitions come from  system.c  */
  808.  
  809. int sys_select(fd_set *fds,struct timeval *tval);
  810. int sys_select(fd_set *fds,struct timeval *tval);
  811. int sys_unlink(char *fname);
  812. int sys_open(char *fname,int flags,int mode);
  813. DIR *sys_opendir(char *dname);
  814. int sys_stat(char *fname,struct stat *sbuf);
  815. int sys_waitpid(pid_t pid, SYS_WAIT_TYPE *status,int options);
  816. int sys_lstat(char *fname,struct stat *sbuf);
  817. int sys_mkdir(char *dname,int mode);
  818. int sys_rmdir(char *dname);
  819. int sys_chdir(char *dname);
  820. int sys_utime(char *fname,struct utimbuf *times);
  821. int sys_rename(char *from, char *to);
  822. int sys_chmod(char *fname,int mode);
  823. char *sys_getwd(char *s);
  824. int sys_chown(char *fname,int uid,int gid);
  825. int sys_chroot(char *dname);
  826. struct hostent *sys_gethostbyname(char *name);
  827.  
  828. /*The following definitions come from  testparm.c  */
  829.  
  830.  
  831. /*The following definitions come from  testprns.c  */
  832.  
  833. int main(int argc, char *argv[]);
  834.  
  835. /*The following definitions come from  time.c  */
  836.  
  837. void GetTimeOfDay(struct timeval *tval);
  838. void TimeInit(void);
  839. int TimeDiff(time_t t);
  840. struct tm *LocalTime(time_t *t);
  841. time_t interpret_long_date(char *p);
  842. void put_long_date(char *p,time_t t);
  843. BOOL null_mtime(time_t mtime);
  844. void put_dos_date(char *buf,int offset,time_t unixdate);
  845. void put_dos_date2(char *buf,int offset,time_t unixdate);
  846. void put_dos_date3(char *buf,int offset,time_t unixdate);
  847. time_t make_unix_date(void *date_ptr);
  848. time_t make_unix_date2(void *date_ptr);
  849. time_t make_unix_date3(void *date_ptr);
  850. char *timestring(void );
  851.  
  852. /*The following definitions come from  trans2.c  */
  853.  
  854. int reply_findclose(char *inbuf,char *outbuf,int length,int bufsize);
  855. int reply_findnclose(char *inbuf,char *outbuf,int length,int bufsize);
  856. int reply_transs2(char *inbuf,char *outbuf,int length,int bufsize);
  857. int reply_trans2(char *inbuf,char *outbuf,int length,int bufsize);
  858.  
  859. /*The following definitions come from  ufc.c  */
  860.  
  861. char *ufc_crypt(char *key,char *salt);
  862.  
  863. /*The following definitions come from  uid.c  */
  864.  
  865. void init_uid(void);
  866. BOOL become_guest(void);
  867. BOOL become_user(int cnum, uint16 vuid);
  868. BOOL unbecome_user(void );
  869. int smbrun(char *cmd,char *outfile,BOOL shared);
  870. void become_root(int save_dir) ;
  871. void unbecome_root(int restore_dir);
  872.  
  873. /*The following definitions come from  username.c  */
  874.  
  875. char *get_home_dir(char *user);
  876. void map_username(char *user);
  877. struct passwd *Get_Pwnam(char *user,BOOL allow_change);
  878. BOOL user_in_list(char *user,char *list);
  879.  
  880. /*The following definitions come from  util.c  */
  881.  
  882. void setup_logging(char *pname,BOOL interactive);
  883. void reopen_logs(void);
  884. char *tmpdir(void);
  885. BOOL is_a_socket(int fd);
  886. BOOL next_token(char **ptr,char *buff,char *sep);
  887. char **toktocliplist(int *ctok, char *sep);
  888. void *MemMove(void *dest,void *src,int size);
  889. void array_promote(char *array,int elsize,int element);
  890. void set_socket_options(int fd, char *options);
  891. void close_sockets(void );
  892. BOOL in_group(gid_t group, int current_gid, int ngroups, int *groups);
  893. char *StrCpy(char *dest,char *src);
  894. char *StrnCpy(char *dest,char *src,int n);
  895. void putip(void *dest,void *src);
  896. int name_mangle(char *In,char *Out,char name_type);
  897. BOOL file_exist(char *fname,struct stat *sbuf);
  898. time_t file_modtime(char *fname);
  899. BOOL directory_exist(char *dname,struct stat *st);
  900. uint32 file_size(char *file_name);
  901. char *attrib_string(int mode);
  902. int StrCaseCmp(const char *s, const char *t);
  903. int StrnCaseCmp(const char *s, const char *t, int n);
  904. BOOL strequal(const char *s1, const char *s2);
  905. BOOL strnequal(const char *s1,const char *s2,int n);
  906. BOOL strcsequal(char *s1,char *s2);
  907. void strlower(char *s);
  908. void strupper(char *s);
  909. void strnorm(char *s);
  910. BOOL strisnormal(char *s);
  911. void string_replace(char *s,char oldc,char newc);
  912. void unix_format(char *fname);
  913. void dos_format(char *fname);
  914. void show_msg(char *buf);
  915. int smb_len(char *buf);
  916. void _smb_setlen(char *buf,int len);
  917. void smb_setlen(char *buf,int len);
  918. int set_message(char *buf,int num_words,int num_bytes,BOOL zero);
  919. int smb_numwords(char *buf);
  920. int smb_buflen(char *buf);
  921. int smb_buf_ofs(char *buf);
  922. char *smb_buf(char *buf);
  923. int smb_offset(char *p,char *buf);
  924. char *skip_string(char *buf,int n);
  925. BOOL trim_string(char *s,char *front,char *back);
  926. void dos_clean_name(char *s);
  927. void unix_clean_name(char *s);
  928. int ChDir(char *path);
  929. char *GetWd(char *str);
  930. BOOL reduce_name(char *s,char *dir,BOOL widelinks);
  931. void expand_mask(char *Mask,BOOL doext);
  932. BOOL strhasupper(char *s);
  933. BOOL strhaslower(char *s);
  934. int count_chars(char *s,char c);
  935. void make_dir_struct(char *buf,char *mask,char *fname,unsigned int size,int mode,time_t date);
  936. void close_low_fds(void);
  937. int set_blocking(int fd, BOOL set);
  938. int write_socket(int fd,char *buf,int len);
  939. int read_udp_socket(int fd,char *buf,int len);
  940. int read_with_timeout(int fd,char *buf,int mincnt,int maxcnt,long time_out);
  941. int read_max_udp(int fd,char *buffer,int bufsize,int maxtime);
  942. int TvalDiff(struct timeval *tvalold,struct timeval *tvalnew);
  943. BOOL send_keepalive(int client);
  944. int read_data(int fd,char *buffer,int N);
  945. int write_data(int fd,char *buffer,int N);
  946. int transfer_file(int infd,int outfd,int n,char *header,int headlen,int align);
  947. int read_smb_length(int fd,char *inbuf,int timeout);
  948. BOOL receive_smb(int fd,char *buffer,int timeout);
  949. BOOL send_smb(int fd,char *buffer);
  950. char *name_ptr(char *buf,int ofs);
  951. int name_extract(char *buf,int ofs,char *name);
  952. int name_len(char *s);
  953. BOOL send_one_packet(char *buf,int len,struct in_addr ip,int port,int type);
  954. void msleep(int t);
  955. BOOL in_list(char *s,char *list,BOOL casesensitive);
  956. BOOL string_init(char **dest,char *src);
  957. void string_free(char **s);
  958. BOOL string_set(char **dest,char *src);
  959. BOOL string_sub(char *s,char *pattern,char *insert);
  960. BOOL do_match(char *str, char *regexp, int case_sig);
  961. BOOL mask_match(char *str, char *regexp, int case_sig,BOOL trans2);
  962. void become_daemon(void);
  963. BOOL yesno(char *p);
  964. char *fgets_slash(char *s2,int maxlen,FILE *f);
  965. int set_filelen(int fd, long len);
  966. int byte_checksum(char *buf,int len);
  967. char *dirname_dos(char *path,char *buf);
  968. void *Realloc(void *p,int size);
  969. void Abort(void );
  970. BOOL get_myname(char *my_name,struct in_addr *ip);
  971. BOOL ip_equal(struct in_addr ip1,struct in_addr ip2);
  972. int open_socket_in(int type, int port, int dlevel,uint32 socket_addr);
  973. int open_socket_out(int type, struct in_addr *addr, int port ,int timeout);
  974. int interpret_protocol(char *str,int def);
  975. int interpret_security(char *str,int def);
  976. uint32 interpret_addr(char *str);
  977. struct in_addr *interpret_addr2(char *str);
  978. BOOL zero_ip(struct in_addr ip);
  979. void reset_globals_after_fork();
  980. char *client_name(void);
  981. char *client_addr(void);
  982. void standard_sub_basic(char *str);
  983. BOOL same_net(struct in_addr ip1,struct in_addr ip2,struct in_addr mask);
  984. int PutUniCode(char *dst,char *src);
  985. struct hostent *Get_Hostbyname(char *name);
  986. BOOL process_exists(int pid);
  987. char *uidtoname(int uid);
  988. char *gidtoname(int gid);
  989. void BlockSignals(BOOL block,int signum);
  990. void ajt_panic(void);
  991. char *readdirname(void *p);
  992. BOOL is_in_path(char *name, name_compare_entry *namelist);
  993. void set_namearray(name_compare_entry **ppname_array, char *namelist);
  994. void free_namearray(name_compare_entry *name_array);
  995. BOOL fcntl_lock(int fd,int op,uint32 offset,uint32 count,int type);
  996. int file_lock(char *name,int timeout);
  997. void file_unlock(int fd);
  998. BOOL is_myname(const char *s);
  999. void set_remote_arch(enum remote_arch_types type);
  1000. enum remote_arch_types get_remote_arch();
  1001. void fstrcpy(char *dest, char *src);
  1002. void pstrcpy(char *dest, char *src);
  1003.  
  1004. /*The following definitions come from  vt_mode.c  */
  1005.  
  1006. int    VT_Check(char    *buffer);
  1007. int VT_Start_utmp(void);
  1008. int VT_Stop_utmp(void);
  1009. void    VT_AtExit(void);
  1010. void    VT_SigCLD(int    sig);
  1011. void    VT_SigEXIT(int    sig);
  1012. int    VT_Start(void);
  1013. int    VT_Output(char    *Buffer);
  1014. int    VT_Input(char    *Buffer,int        Size);
  1015. void VT_Process(void);
  1016.  
  1017. #ifdef USE_NETINFO
  1018. /* The following definitions are used when NetInfo is enabled: */
  1019. ni_status ni_search_for_dir(char *dir, char *baseDomain, void **handle, ni_id *id, int timeout, int willwrite, int freeold);
  1020. char *ni_get_netbios_name(char *unixname);
  1021. BOOL pm_file_process(char *pszFileName,BOOL (*sfunc)(char *),BOOL (*pfunc)(char *,char *));
  1022.  
  1023. #endif
  1024.