URL: https://github.com/SSSD/sssd/pull/89
Title: #89: nss: rewrite nss responder so it uses cache_req

lslebodn commented:
"""
When I was testing crash caused by enumeration I also found different valgrind 
errors.
I double checked that these errors are not in master.
```
==18958== 1 errors in context 1 of 1:
==18958== Syscall param socketcall.sendto(msg) points to uninitialised byte(s)
==18958==    at 0x32BF20ED62: send (send.c:28)
==18958==    by 0x41607E: sss_packet_send (responder_packet.c:238)
==18958==    by 0x412B7A: client_fd_handler (responder_common.c:258)
==18958==    by 0x32C4E09F05: epoll_event_loop_once (tevent_epoll.c:728)
==18958==    by 0x32C4E08335: std_event_loop_once (tevent_standard.c:114)
==18958==    by 0x32C4E03C3C: _tevent_loop_once (tevent.c:533)
==18958==    by 0x32C4E03CBA: tevent_common_loop_wait (tevent.c:637)
==18958==    by 0x32C4E082A5: std_event_loop_wait (tevent_standard.c:140)
==18958==    by 0x32C564AEB2: server_loop (server.c:705)
==18958==    by 0x4066F7: main (nsssrv.c:559)
==18958==  Address 0x4da3148 is 120 bytes inside a block of size 608 alloc'd
==18958==    at 0x4A06A2E: malloc (vg_replace_malloc.c:270)
==18958==    by 0x32C0E03422: talloc_named_const (talloc.c:668)
==18958==    by 0x41627A: sss_packet_new (responder_packet.c:84)
==18958==    by 0x40982A: nss_protocol_reply (nss_protocol.c:84)
==18958==    by 0x406B13: nss_getby_done (nss_cmd.c:338)
==18958==    by 0x4198F9: cache_req_done (cache_req.c:690)
==18958==    by 0x41A595: cache_req_search_done (cache_req_search.c:409)
==18958==    by 0x415B6D: sss_dp_internal_get_done (responder_dp.c:813)
==18958==    by 0x32C320E619: complete_pending_call_and_unlock 
(dbus-connection.c:2234)
==18958==    by 0x32C321086E: dbus_connection_dispatch (dbus-connection.c:4397)
==18958==    by 0x32C5641D7C: sbus_dispatch (sssd_dbus_connection.c:96)
==18958==    by 0x32C4E08CC0: tevent_common_loop_timer_delay 
(tevent_timed.c:341)
``` 
and similar with realloc
`==7607== Syscall param socketcall.sendto(msg) points to uninitialised byte(s)
==7607==    at 0x32BF20ED62: send (send.c:28)
==7607==    by 0x41607E: sss_packet_send (responder_packet.c:238)
==7607==    by 0x412B7A: client_fd_handler (responder_common.c:258)
==7607==    by 0x32C4E09F05: epoll_event_loop_once (tevent_epoll.c:728)
==7607==    by 0x32C4E08335: std_event_loop_once (tevent_standard.c:114)
==7607==    by 0x32C4E03C3C: _tevent_loop_once (tevent.c:533)
==7607==    by 0x32C4E03CBA: tevent_common_loop_wait (tevent.c:637)
==7607==    by 0x32C4E082A5: std_event_loop_wait (tevent_standard.c:140)
==7607==    by 0x32C564AEB2: server_loop (server.c:705)
==7607==    by 0x4066F7: main (nsssrv.c:559)
==7607==  Address 0xe4c228c is 1,068 bytes inside a block of size 1,632 alloc'd
==7607==    at 0x4A06C20: realloc (vg_replace_malloc.c:662)
==7607==    by 0x32C0E099AA: _talloc_realloc (talloc.c:1880)
==7607==    by 0x4163B9: sss_packet_grow (responder_packet.c:127)
==7607==    by 0x40AF86: nss_protocol_fill_initgr (nss_protocol_grent.c:346)
==7607==    by 0x409873: nss_protocol_reply (nss_protocol.c:91)
==7607==    by 0x406B13: nss_getby_done (nss_cmd.c:338)
==7607==    by 0x4198F9: cache_req_done (cache_req.c:690)
==7607==    by 0x32C4E04867: tevent_common_loop_immediate 
(tevent_immediate.c:135)
==7607==    by 0x32C4E09CF5: epoll_event_loop_once (tevent_epoll.c:906)
==7607==    by 0x32C4E08335: std_event_loop_once (tevent_standard.c:114)
==7607==    by 0x32C4E03C3C: _tevent_loop_once (tevent.c:533)
==7607==    by 0x32C4E03CBA: tevent_common_loop_wait (tevent.c:637)``
```
"""

See the full comment at 
https://github.com/SSSD/sssd/pull/89#issuecomment-265215397
_______________________________________________
sssd-devel mailing list -- sssd-devel@lists.fedorahosted.org
To unsubscribe send an email to sssd-devel-le...@lists.fedorahosted.org

Reply via email to