Print this page
1575 untangle libmlrpc ... pre2:
Get rid of ndr_rpc_server_{info,os}
1575 untangle libmlrpc ... pre1:
Move srvsvc_timecheck where it belongs
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/lib/smbsrv/libmlsvc/common/srvsvc_clnt.c
+++ new/usr/src/lib/smbsrv/libmlsvc/common/srvsvc_clnt.c
1 1 /*
2 2 * CDDL HEADER START
3 3 *
4 4 * The contents of this file are subject to the terms of the
5 5 * Common Development and Distribution License (the "License").
6 6 * You may not use this file except in compliance with the License.
7 7 *
8 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 9 * or http://www.opensolaris.org/os/licensing.
10 10 * See the License for the specific language governing permissions
11 11 * and limitations under the License.
12 12 *
13 13 * When distributing Covered Code, include this CDDL HEADER in each
14 14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 15 * If applicable, add the following below this CDDL HEADER, with the
16 16 * fields enclosed by brackets "[]" replaced with your own identifying
17 17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 18 *
19 19 * CDDL HEADER END
20 20 */
21 21
22 22 /*
23 23 * Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
24 24 * Copyright 2015 Nexenta Systems, Inc. All rights reserved.
25 25 */
26 26
↓ open down ↓ |
26 lines elided |
↑ open up ↑ |
27 27 /*
28 28 * Server Service (srvsvc) client side RPC library interface. The
29 29 * srvsvc interface allows a client to query a server for information
30 30 * on shares, sessions, connections and files on the server. Some
31 31 * functions are available via anonymous IPC while others require
32 32 * administrator privilege. Also, some functions return NT status
33 33 * values while others return Win32 errors codes.
34 34 */
35 35
36 36 #include <sys/errno.h>
37 +#include <sys/tzfile.h>
37 38 #include <stdio.h>
38 39 #include <time.h>
39 40 #include <strings.h>
41 +#include <unistd.h>
40 42
41 43 #include <smbsrv/libsmb.h>
42 44 #include <smbsrv/libmlsvc.h>
43 45 #include <smbsrv/smbinfo.h>
44 46 #include <smbsrv/ndl/srvsvc.ndl>
45 47
46 48 /*
47 49 * Information level for NetShareGetInfo.
48 50 */
49 51 DWORD srvsvc_info_level = 1;
50 52
51 53 /*
52 54 * Bind to the the SRVSVC.
53 55 *
54 56 * If username argument is NULL, an anonymous connection will be established.
55 57 * Otherwise, an authenticated connection will be established.
56 58 */
57 59 static int
58 60 srvsvc_open(char *server, char *domain, char *username, mlsvc_handle_t *handle)
59 61 {
60 62 smb_domainex_t di;
61 63
62 64 if (server == NULL || domain == NULL) {
63 65 if (!smb_domain_getinfo(&di))
64 66 return (-1);
65 67
66 68 server = di.d_dci.dc_name;
67 69 domain = di.d_primary.di_nbname;
68 70 }
69 71
70 72 if (username == NULL)
71 73 username = MLSVC_ANON_USER;
72 74
73 75 if (ndr_rpc_bind(handle, server, domain, username, "SRVSVC") != 0)
74 76 return (-1);
75 77
76 78 return (0);
77 79 }
78 80
79 81 /*
80 82 * Unbind the SRVSVC connection.
81 83 */
82 84 static void
83 85 srvsvc_close(mlsvc_handle_t *handle)
84 86 {
85 87 ndr_rpc_unbind(handle);
86 88 }
87 89
88 90 /*
89 91 * This is a client side routine for NetShareGetInfo.
90 92 * Levels 0 and 1 work with an anonymous connection but
91 93 * level 2 requires administrator access.
92 94 */
93 95 int
94 96 srvsvc_net_share_get_info(char *server, char *domain, char *netname)
95 97 {
96 98 struct mlsm_NetShareGetInfo arg;
97 99 mlsvc_handle_t handle;
98 100 int rc;
99 101 int opnum;
100 102 struct mslm_NetShareInfo_0 *info0;
101 103 struct mslm_NetShareInfo_1 *info1;
102 104 struct mslm_NetShareInfo_2 *info2;
103 105 int len;
104 106 char user[SMB_USERNAME_MAXLEN];
105 107
106 108 if (netname == NULL)
107 109 return (-1);
108 110
109 111 if (srvsvc_info_level == 2)
110 112 smb_ipc_get_user(user, SMB_USERNAME_MAXLEN);
111 113
112 114 if (srvsvc_open(server, domain, user, &handle) != 0)
113 115 return (-1);
114 116
115 117 opnum = SRVSVC_OPNUM_NetShareGetInfo;
116 118 bzero(&arg, sizeof (struct mlsm_NetShareGetInfo));
117 119
118 120 len = strlen(server) + 4;
119 121 arg.servername = ndr_rpc_malloc(&handle, len);
120 122 if (arg.servername == NULL) {
121 123 srvsvc_close(&handle);
122 124 return (-1);
123 125 }
124 126
125 127 (void) snprintf((char *)arg.servername, len, "\\\\%s", server);
126 128 arg.netname = (LPTSTR)netname;
127 129 arg.level = srvsvc_info_level; /* share information level */
128 130
129 131 rc = ndr_rpc_call(&handle, opnum, &arg);
130 132 if ((rc != 0) || (arg.status != 0)) {
131 133 srvsvc_close(&handle);
132 134 return (-1);
133 135 }
134 136
135 137 switch (arg.result.switch_value) {
136 138 case 0:
137 139 info0 = arg.result.ru.info0;
138 140 smb_tracef("srvsvc shi0_netname=%s", info0->shi0_netname);
139 141 break;
140 142
141 143 case 1:
142 144 info1 = arg.result.ru.info1;
143 145 smb_tracef("srvsvc shi1_netname=%s", info1->shi1_netname);
144 146 smb_tracef("srvsvc shi1_type=%u", info1->shi1_type);
145 147
146 148 if (info1->shi1_comment)
147 149 smb_tracef("srvsvc shi1_comment=%s",
148 150 info1->shi1_comment);
149 151 break;
150 152
151 153 case 2:
152 154 info2 = arg.result.ru.info2;
153 155 smb_tracef("srvsvc shi2_netname=%s", info2->shi2_netname);
154 156 smb_tracef("srvsvc shi2_type=%u", info2->shi2_type);
155 157
156 158 if (info2->shi2_comment)
157 159 smb_tracef("srvsvc shi2_comment=%s",
158 160 info2->shi2_comment);
159 161
160 162 smb_tracef("srvsvc shi2_perms=%d", info2->shi2_permissions);
161 163 smb_tracef("srvsvc shi2_max_use=%d", info2->shi2_max_uses);
162 164 smb_tracef("srvsvc shi2_cur_use=%d", info2->shi2_current_uses);
163 165
164 166 if (info2->shi2_path)
165 167 smb_tracef("srvsvc shi2_path=%s", info2->shi2_path);
166 168
167 169 if (info2->shi2_passwd)
168 170 smb_tracef("srvsvc shi2_passwd=%s", info2->shi2_passwd);
169 171 break;
170 172
171 173 default:
172 174 smb_tracef("srvsvc: unknown level");
173 175 break;
174 176 }
175 177
176 178 srvsvc_close(&handle);
177 179 return (0);
178 180 }
179 181
180 182 /*
181 183 * This is a client side routine for NetSessionEnum.
182 184 * NetSessionEnum requires administrator rights.
183 185 */
184 186 int
185 187 srvsvc_net_session_enum(char *server, char *domain, char *netname)
186 188 {
187 189 struct mslm_NetSessionEnum arg;
188 190 mlsvc_handle_t handle;
189 191 int rc;
190 192 int opnum;
191 193 struct mslm_infonres infonres;
192 194 struct mslm_SESSION_INFO_1 *nsi1;
193 195 int len;
194 196 char user[SMB_USERNAME_MAXLEN];
195 197
196 198 if (netname == NULL)
197 199 return (-1);
198 200
199 201 smb_ipc_get_user(user, SMB_USERNAME_MAXLEN);
200 202
201 203 rc = srvsvc_open(server, domain, user, &handle);
202 204 if (rc != 0)
203 205 return (-1);
204 206
205 207 opnum = SRVSVC_OPNUM_NetSessionEnum;
206 208 bzero(&arg, sizeof (struct mslm_NetSessionEnum));
207 209
208 210 len = strlen(server) + 4;
209 211 arg.servername = ndr_rpc_malloc(&handle, len);
210 212 if (arg.servername == NULL) {
211 213 srvsvc_close(&handle);
212 214 return (-1);
213 215 }
214 216
215 217 (void) snprintf((char *)arg.servername, len, "\\\\%s", server);
216 218 infonres.entriesread = 0;
217 219 infonres.entries = 0;
218 220 arg.level = 1;
219 221 arg.result.level = 1;
220 222 arg.result.bufptr.p = &infonres;
221 223 arg.resume_handle = 0;
222 224 arg.pref_max_len = 0xFFFFFFFF;
223 225
224 226 rc = ndr_rpc_call(&handle, opnum, &arg);
225 227 if ((rc != 0) || (arg.status != 0)) {
226 228 srvsvc_close(&handle);
227 229 return (-1);
228 230 }
229 231
230 232 /* Only the first session info is dereferenced. */
231 233 nsi1 = ((struct mslm_infonres *)arg.result.bufptr.p)->entries;
232 234
233 235 smb_tracef("srvsvc switch_value=%d", arg.level);
234 236 smb_tracef("srvsvc sesi1_cname=%s", nsi1->sesi1_cname);
235 237 smb_tracef("srvsvc sesi1_uname=%s", nsi1->sesi1_uname);
236 238 smb_tracef("srvsvc sesi1_nopens=%u", nsi1->sesi1_nopens);
237 239 smb_tracef("srvsvc sesi1_time=%u", nsi1->sesi1_time);
238 240 smb_tracef("srvsvc sesi1_itime=%u", nsi1->sesi1_itime);
239 241 smb_tracef("srvsvc sesi1_uflags=%u", nsi1->sesi1_uflags);
240 242
241 243 srvsvc_close(&handle);
242 244 return (0);
243 245 }
244 246
245 247 /*
246 248 * This is a client side routine for NetConnectEnum.
247 249 * NetConnectEnum requires administrator rights.
248 250 * Level 0 and level 1 requests are supported.
249 251 */
250 252 int
251 253 srvsvc_net_connect_enum(char *server, char *domain, char *netname, int level)
252 254 {
253 255 struct mslm_NetConnectEnum arg;
254 256 mlsvc_handle_t handle;
255 257 int rc;
256 258 int opnum;
257 259 struct mslm_NetConnectInfo1 info1;
258 260 struct mslm_NetConnectInfo0 info0;
259 261 struct mslm_NetConnectInfoBuf1 *cib1;
260 262 int len;
261 263 char user[SMB_USERNAME_MAXLEN];
262 264
263 265 if (netname == NULL)
264 266 return (-1);
265 267
266 268 smb_ipc_get_user(user, SMB_USERNAME_MAXLEN);
267 269
268 270 rc = srvsvc_open(server, domain, user, &handle);
269 271 if (rc != 0)
270 272 return (-1);
271 273
272 274 opnum = SRVSVC_OPNUM_NetConnectEnum;
273 275 bzero(&arg, sizeof (struct mslm_NetConnectEnum));
274 276
275 277 len = strlen(server) + 4;
276 278 arg.servername = ndr_rpc_malloc(&handle, len);
277 279 if (arg.servername == NULL) {
278 280 srvsvc_close(&handle);
279 281 return (-1);
280 282 }
281 283
282 284 (void) snprintf((char *)arg.servername, len, "\\\\%s", server);
283 285 arg.qualifier = (LPTSTR)netname;
284 286
285 287 switch (level) {
286 288 case 0:
287 289 arg.info.level = 0;
288 290 arg.info.switch_value = 0;
289 291 arg.info.ru.info0 = &info0;
290 292 info0.entries_read = 0;
291 293 info0.ci0 = 0;
292 294 break;
293 295 case 1:
294 296 arg.info.level = 1;
295 297 arg.info.switch_value = 1;
296 298 arg.info.ru.info1 = &info1;
297 299 info1.entries_read = 0;
298 300 info1.ci1 = 0;
299 301 break;
300 302 default:
301 303 srvsvc_close(&handle);
302 304 return (-1);
303 305 }
304 306
305 307 arg.resume_handle = 0;
306 308 arg.pref_max_len = 0xFFFFFFFF;
307 309
308 310 rc = ndr_rpc_call(&handle, opnum, &arg);
309 311 if ((rc != 0) || (arg.status != 0)) {
310 312 srvsvc_close(&handle);
311 313 return (-1);
312 314 }
313 315
314 316 smb_tracef("srvsvc switch_value=%d", arg.info.switch_value);
315 317
316 318 switch (level) {
317 319 case 0:
318 320 if (arg.info.ru.info0 && arg.info.ru.info0->ci0) {
319 321 smb_tracef("srvsvc coni0_id=%x",
320 322 arg.info.ru.info0->ci0->coni0_id);
321 323 }
322 324 break;
323 325 case 1:
324 326 if (arg.info.ru.info1 && arg.info.ru.info1->ci1) {
325 327 cib1 = arg.info.ru.info1->ci1;
326 328
327 329 smb_tracef("srvsvc coni_uname=%s",
328 330 cib1->coni1_username ?
329 331 (char *)cib1->coni1_username : "(null)");
330 332 smb_tracef("srvsvc coni1_netname=%s",
331 333 cib1->coni1_netname ?
332 334 (char *)cib1->coni1_netname : "(null)");
333 335 smb_tracef("srvsvc coni1_nopens=%u",
334 336 cib1->coni1_num_opens);
335 337 smb_tracef("srvsvc coni1_time=%u", cib1->coni1_time);
336 338 smb_tracef("srvsvc coni1_num_users=%u",
337 339 cib1->coni1_num_users);
338 340 }
339 341 break;
340 342
↓ open down ↓ |
291 lines elided |
↑ open up ↑ |
341 343 default:
342 344 smb_tracef("srvsvc: unknown level");
343 345 break;
344 346 }
345 347
346 348 srvsvc_close(&handle);
347 349 return (0);
348 350 }
349 351
350 352 /*
351 - * Windows 95+ and Windows NT4.0 both report the version as 4.0.
352 - * Windows 2000+ reports the version as 5.x.
353 + * Compare the time here with the remote time on the server
354 + * and report clock skew.
353 355 */
354 -int
355 -srvsvc_net_server_getinfo(char *server, char *domain,
356 - srvsvc_server_info_t *svinfo)
356 +void
357 +srvsvc_timecheck(char *server, char *domain)
357 358 {
358 - mlsvc_handle_t handle;
359 - struct mslm_NetServerGetInfo arg;
360 - struct mslm_SERVER_INFO_101 *sv101;
361 - int len, opnum, rc;
362 - char user[SMB_USERNAME_MAXLEN];
359 + char hostname[MAXHOSTNAMELEN];
360 + struct timeval dc_tv;
361 + struct tm dc_tm;
362 + struct tm *tm;
363 + time_t tnow;
364 + time_t tdiff;
365 + int priority;
363 366
364 - smb_ipc_get_user(user, SMB_USERNAME_MAXLEN);
367 + if (srvsvc_net_remote_tod(server, domain, &dc_tv, &dc_tm) < 0) {
368 + syslog(LOG_DEBUG, "srvsvc_net_remote_tod failed");
369 + return;
370 + }
365 371
366 - if (srvsvc_open(server, domain, user, &handle) != 0)
367 - return (-1);
372 + tnow = time(NULL);
368 373
369 - opnum = SRVSVC_OPNUM_NetServerGetInfo;
370 - bzero(&arg, sizeof (arg));
374 + if (tnow > dc_tv.tv_sec)
375 + tdiff = (tnow - dc_tv.tv_sec) / SECSPERMIN;
376 + else
377 + tdiff = (dc_tv.tv_sec - tnow) / SECSPERMIN;
371 378
372 - len = strlen(server) + 4;
373 - arg.servername = ndr_rpc_malloc(&handle, len);
374 - if (arg.servername == NULL)
375 - return (-1);
379 + if (tdiff != 0) {
380 + (void) strlcpy(hostname, "localhost", MAXHOSTNAMELEN);
381 + (void) gethostname(hostname, MAXHOSTNAMELEN);
376 382
377 - (void) snprintf((char *)arg.servername, len, "\\\\%s", server);
378 - arg.level = 101;
383 + priority = (tdiff > 2) ? LOG_NOTICE : LOG_DEBUG;
384 + syslog(priority, "DC [%s] clock skew detected: %u minutes",
385 + server, tdiff);
379 386
380 - rc = ndr_rpc_call(&handle, opnum, &arg);
381 - if ((rc != 0) || (arg.status != 0)) {
382 - srvsvc_close(&handle);
383 - return (-1);
387 + tm = gmtime(&dc_tv.tv_sec);
388 + syslog(priority, "%-8s UTC: %s", server, asctime(tm));
389 + tm = gmtime(&tnow);
390 + syslog(priority, "%-8s UTC: %s", hostname, asctime(tm));
384 391 }
385 -
386 - sv101 = arg.result.bufptr.bufptr101;
387 -
388 - bzero(svinfo, sizeof (srvsvc_server_info_t));
389 - svinfo->sv_platform_id = sv101->sv101_platform_id;
390 - svinfo->sv_version_major = sv101->sv101_version_major;
391 - svinfo->sv_version_minor = sv101->sv101_version_minor;
392 - svinfo->sv_type = sv101->sv101_type;
393 - if (sv101->sv101_name)
394 - svinfo->sv_name = strdup((char *)sv101->sv101_name);
395 - if (sv101->sv101_comment)
396 - svinfo->sv_comment = strdup((char *)sv101->sv101_comment);
397 -
398 - if (svinfo->sv_type & SV_TYPE_WFW)
399 - svinfo->sv_os = NATIVE_OS_WIN95;
400 - if (svinfo->sv_type & SV_TYPE_WINDOWS)
401 - svinfo->sv_os = NATIVE_OS_WIN95;
402 - if ((svinfo->sv_type & SV_TYPE_NT) ||
403 - (svinfo->sv_type & SV_TYPE_SERVER_NT))
404 - svinfo->sv_os = NATIVE_OS_WINNT;
405 - if (svinfo->sv_version_major > 4)
406 - svinfo->sv_os = NATIVE_OS_WIN2000;
407 -
408 - srvsvc_close(&handle);
409 - return (0);
410 392 }
411 393
412 394 /*
413 395 * Synchronize the local system clock with the domain controller.
414 396 */
415 397 void
416 398 srvsvc_timesync(void)
417 399 {
418 400 smb_domainex_t di;
419 401 struct timeval tv;
420 402 struct tm tm;
421 403 time_t tsecs;
422 404
423 405 if (!smb_domain_getinfo(&di))
424 406 return;
425 407
426 408 if (srvsvc_net_remote_tod(di.d_dci.dc_name, di.d_primary.di_nbname,
427 409 &tv, &tm) != 0)
428 410 return;
429 411
430 412 if (settimeofday(&tv, 0))
431 413 smb_tracef("unable to set system time");
432 414
433 415 tsecs = time(0);
434 416 (void) localtime_r(&tsecs, &tm);
435 417 smb_tracef("SrvsvcTimeSync %s", ctime((time_t *)&tv.tv_sec));
436 418 }
437 419
438 420 /*
439 421 * NetRemoteTOD to get the current GMT time from a Windows NT server.
440 422 */
441 423 int
442 424 srvsvc_gettime(unsigned long *t)
443 425 {
444 426 smb_domainex_t di;
445 427 struct timeval tv;
446 428 struct tm tm;
447 429
448 430 if (!smb_domain_getinfo(&di))
449 431 return (-1);
450 432
451 433 if (srvsvc_net_remote_tod(di.d_dci.dc_name, di.d_primary.di_nbname,
452 434 &tv, &tm) != 0)
453 435 return (-1);
454 436
455 437 *t = tv.tv_sec;
456 438 return (0);
457 439 }
458 440
459 441 /*
460 442 * This is a client side routine for NetRemoteTOD, which gets the time
461 443 * and date from a remote system. The time information is returned in
462 444 * the timeval and tm.
463 445 *
464 446 * typedef struct _TIME_OF_DAY_INFO {
465 447 * DWORD tod_elapsedt; // seconds since 00:00:00 January 1 1970 GMT
466 448 * DWORD tod_msecs; // arbitrary milliseconds (since reset)
467 449 * DWORD tod_hours; // current hour [0-23]
468 450 * DWORD tod_mins; // current minute [0-59]
469 451 * DWORD tod_secs; // current second [0-59]
470 452 * DWORD tod_hunds; // current hundredth (0.01) second [0-99]
471 453 * LONG tod_timezone; // time zone of the server
472 454 * DWORD tod_tinterval; // clock tick time interval
473 455 * DWORD tod_day; // day of the month [1-31]
474 456 * DWORD tod_month; // month of the year [1-12]
475 457 * DWORD tod_year; // current year
476 458 * DWORD tod_weekday; // day of the week since sunday [0-6]
477 459 * } TIME_OF_DAY_INFO;
478 460 *
479 461 * The time zone of the server is calculated in minutes from Greenwich
480 462 * Mean Time (GMT). For time zones west of Greenwich, the value is
481 463 * positive; for time zones east of Greenwich, the value is negative.
482 464 * A value of -1 indicates that the time zone is undefined.
483 465 *
484 466 * The clock tick value represents a resolution of one ten-thousandth
485 467 * (0.0001) second.
486 468 */
487 469 int
488 470 srvsvc_net_remote_tod(char *server, char *domain, struct timeval *tv,
489 471 struct tm *tm)
490 472 {
491 473 struct mslm_NetRemoteTOD arg;
492 474 struct mslm_TIME_OF_DAY_INFO *tod;
493 475 mlsvc_handle_t handle;
494 476 int rc;
495 477 int opnum;
496 478 int len;
497 479 char user[SMB_USERNAME_MAXLEN];
498 480
499 481 smb_ipc_get_user(user, SMB_USERNAME_MAXLEN);
500 482
501 483 rc = srvsvc_open(server, domain, user, &handle);
502 484 if (rc != 0)
503 485 return (-1);
504 486
505 487 opnum = SRVSVC_OPNUM_NetRemoteTOD;
506 488 bzero(&arg, sizeof (struct mslm_NetRemoteTOD));
507 489
508 490 len = strlen(server) + 4;
509 491 arg.servername = ndr_rpc_malloc(&handle, len);
510 492 if (arg.servername == NULL) {
511 493 srvsvc_close(&handle);
512 494 return (-1);
513 495 }
514 496
515 497 (void) snprintf((char *)arg.servername, len, "\\\\%s", server);
516 498
517 499 rc = ndr_rpc_call(&handle, opnum, &arg);
518 500 if ((rc != 0) || (arg.status != 0)) {
519 501 srvsvc_close(&handle);
520 502 return (-1);
521 503 }
522 504
523 505 /*
524 506 * We're assigning milliseconds to microseconds
525 507 * here but the value's not really relevant.
526 508 */
527 509 tod = arg.bufptr;
528 510
529 511 if (tv) {
530 512 tv->tv_sec = tod->tod_elapsedt;
531 513 tv->tv_usec = tod->tod_msecs;
532 514 }
533 515
534 516 if (tm) {
535 517 tm->tm_sec = tod->tod_secs;
↓ open down ↓ |
116 lines elided |
↑ open up ↑ |
536 518 tm->tm_min = tod->tod_mins;
537 519 tm->tm_hour = tod->tod_hours;
538 520 tm->tm_mday = tod->tod_day;
539 521 tm->tm_mon = tod->tod_month - 1;
540 522 tm->tm_year = tod->tod_year - 1900;
541 523 tm->tm_wday = tod->tod_weekday;
542 524 }
543 525
544 526 srvsvc_close(&handle);
545 527 return (0);
546 -}
547 -
548 -void
549 -srvsvc_net_test(char *server, char *domain, char *netname)
550 -{
551 - smb_domainex_t di;
552 - srvsvc_server_info_t svinfo;
553 -
554 - (void) smb_tracef("%s %s %s", server, domain, netname);
555 -
556 - if (smb_domain_getinfo(&di)) {
557 - server = di.d_dci.dc_name;
558 - domain = di.d_primary.di_nbname;
559 - }
560 -
561 - if (srvsvc_net_server_getinfo(server, domain, &svinfo) == 0) {
562 - smb_tracef("NetServerGetInfo: %s %s (%d.%d) id=%d type=0x%08x",
563 - svinfo.sv_name ? svinfo.sv_name : "NULL",
564 - svinfo.sv_comment ? svinfo.sv_comment : "NULL",
565 - svinfo.sv_version_major, svinfo.sv_version_minor,
566 - svinfo.sv_platform_id, svinfo.sv_type);
567 -
568 - free(svinfo.sv_name);
569 - free(svinfo.sv_comment);
570 - }
571 -
572 - (void) srvsvc_net_share_get_info(server, domain, netname);
573 -#if 0
574 - /*
575 - * The NetSessionEnum server-side definition was updated.
576 - * Disabled until the client-side has been updated.
577 - */
578 - (void) srvsvc_net_session_enum(server, domain, netname);
579 -#endif
580 - (void) srvsvc_net_connect_enum(server, domain, netname, 0);
581 - (void) srvsvc_net_connect_enum(server, domain, netname, 1);
582 528 }
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX