Changeset 860 for vendor/current/nsswitch
- Timestamp:
- May 12, 2014, 8:58:38 PM (11 years ago)
- Location:
- vendor/current/nsswitch
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
vendor/current/nsswitch/libwbclient/wbc_sid.c
r740 r860 422 422 423 423 names[i].domain_index = strtoul(p, &q, 10); 424 if (names[i].domain_index < 0) { 425 goto wbc_err_invalid; 426 } 427 if (names[i].domain_index >= num_domains) { 428 goto wbc_err_invalid; 429 } 430 424 431 if (*q != ' ') { 425 432 goto wbc_err_invalid; -
vendor/current/nsswitch/pam_winbind.c
r746 r860 1185 1185 "to sid, please contact your administrator to see " 1186 1186 "if group %s is valid."), search_location, search_location); 1187 1188 /* If no valid groups were converted we should fail outright */ 1189 if (name_list != NULL && strlen(sid_list_buffer) == 0) { 1190 result = false; 1191 goto out; 1192 } 1187 1193 /* 1188 1194 * The lookup of the last name failed.. … … 2449 2455 } 2450 2456 2451 return talloc_asprintf(ctx, "%s \\%s", domain, name);2457 return talloc_asprintf(ctx, "%s%c%s", domain, sep, name); 2452 2458 } 2453 2459 … … 2736 2742 } 2737 2743 2738 _PAM_LOG_FUNCTION_LEAVE("pam_sm_authenticate", ctx, retval); 2739 2740 TALLOC_FREE(ctx); 2744 if (ctx != NULL) { 2745 _PAM_LOG_FUNCTION_LEAVE("pam_sm_authenticate", ctx, retval); 2746 TALLOC_FREE(ctx); 2747 } 2741 2748 2742 2749 return retval; -
vendor/current/nsswitch/wb_common.c
r740 r860 393 393 394 394 pfd.fd = winbindd_fd; 395 pfd.events = POLLIN|POLL HUP;396 397 ret = poll(&pfd, 1, 0);395 pfd.events = POLLIN|POLLOUT|POLLHUP; 396 397 ret = poll(&pfd, 1, -1); 398 398 if (ret == -1) { 399 399 winbind_close_sock(); -
vendor/current/nsswitch/wbinfo.c
r740 r860 1381 1381 1382 1382 for (i=0; i<num_sids; i++) { 1383 const char *domain = NULL; 1384 1383 1385 wbcSidToStringBuf(&sids[i], sidstr, sizeof(sidstr)); 1384 1386 1385 d_printf("%s -> %s\\%s %d\n", sidstr, 1386 domains[names[i].domain_index].short_name, 1387 names[i].name, names[i].type); 1387 if (names[i].domain_index >= num_domains) { 1388 domain = "<none>"; 1389 } else if (names[i].domain_index < 0) { 1390 domain = "<none>"; 1391 } else { 1392 domain = domains[names[i].domain_index].short_name; 1393 } 1394 1395 if (names[i].type == WBC_SID_NAME_DOMAIN) { 1396 d_printf("%s -> %s %d\n", sidstr, 1397 domain, 1398 names[i].type); 1399 } else { 1400 d_printf("%s -> %s%c%s %d\n", sidstr, 1401 domain, 1402 winbind_separator(), 1403 names[i].name, names[i].type); 1404 } 1388 1405 } 1389 1406 return true; … … 1729 1746 wbcErr wbc_status = WBC_ERR_UNKNOWN_FAILURE; 1730 1747 struct wbcLogonUserParams params; 1731 struct wbcAuthErrorInfo *error ;1748 struct wbcAuthErrorInfo *error = NULL; 1732 1749 char *s = NULL; 1733 1750 char *p = NULL; … … 1780 1797 WBC_ERROR_IS_OK(wbc_status) ? "succeeded" : "failed"); 1781 1798 1782 if (!WBC_ERROR_IS_OK(wbc_status) ) {1799 if (!WBC_ERROR_IS_OK(wbc_status) && (error != NULL)) { 1783 1800 d_fprintf(stderr, 1784 1801 "error code was %s (0x%x)\nerror message was: %s\n", … … 1787 1804 error->display_string); 1788 1805 wbcFreeMemory(error); 1789 return false; 1790 } 1791 return true; 1806 } 1807 return WBC_ERROR_IS_OK(wbc_status); 1792 1808 } 1793 1809
Note:
See TracChangeset
for help on using the changeset viewer.