Ignore:
Timestamp:
Jun 25, 2011, 7:14:41 PM (14 years ago)
Author:
Herwig Bauernfeind
Message:

Update Samba 3.3 to 3.3.15 (security update)

Location:
branches/samba-3.3.x/source/winbindd
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/samba-3.3.x/source/winbindd/winbindd.c

    r342 r578  
    837837        listen_priv_sock = open_winbindd_priv_socket();
    838838
    839         if (listen_sock == -1 || listen_priv_sock == -1) {
     839        if (listen_sock < 0 || listen_sock >= FD_SETSIZE ||
     840                        listen_priv_sock < 0 || listen_priv_sock >= FD_SETSIZE) {
    840841                perror("open_winbind_socket");
    841842                exit(1);
     
    862863        FD_ZERO(&r_fds);
    863864        FD_ZERO(&w_fds);
     865
     866        /* We check the range for listen_sock and
     867           listen_priv_sock above. */
    864868        FD_SET(listen_sock, &r_fds);
    865869        FD_SET(listen_priv_sock, &r_fds);
     
    891895
    892896        for (ev = fd_events; ev; ev = ev->next) {
     897                if (ev->fd < 0 || ev->fd >= FD_SETSIZE) {
     898                        /* Ignore here - event_add_to_select_args
     899                           should make this impossible. */
     900                        continue;
     901                }
     902
    893903                if (ev->flags & EVENT_FD_READ) {
    894904                        FD_SET(ev->fd, &r_fds);
  • branches/samba-3.3.x/source/winbindd/winbindd_dual.c

    r221 r578  
    12511251        }
    12521252
     1253        if (fdpair[0] < 0 || fdpair[0] >= FD_SETSIZE) {
     1254                DEBUG(0, ("fork_domain_child: bad fd range (%d)\n", fdpair[0]));
     1255                errno = EBADF;
     1256                return False;
     1257        }
     1258
    12531259        ZERO_STRUCT(state);
    12541260        state.pid = sys_getpid();
     
    14061412
    14071413                FD_ZERO(&read_fds);
     1414                /* We check state.sock against FD_SETSIZE above. */
    14081415                FD_SET(state.sock, &read_fds);
    14091416
Note: See TracChangeset for help on using the changeset viewer.