tcpdump mailing list archives
clean exit from tcpdump with asan
From: enh via tcpdump-workers <tcpdump-workers () lists tcpdump org>
Date: Wed, 14 Oct 2020 14:28:09 -0700
--- Begin Message --- From: enh <enh () google com>
Date: Wed, 14 Oct 2020 14:28:09 -0700
i haven't reproduced it myself yet (though i'll try shortly) but we got an automated crash report from tcpdump on Android via [gwp-asan](https://developer.android.com/ndk/guides/gwp-asan). the bug is a use-after-free, specifically when pcap_breakloop() tries to write to the already-freed struct pcap_t. this happens if a signal is received during tcpdump shutdown (which is presumably why we haven't hit this more often on ASan/HWASan builds). i assume the fix is to disable the signal handlers before calling pcap_close() to free the struct pcap_t, but i thought i'd bring this up on the list before i (a) look at reproducing this locally and (b) send a patch...
--- End Message ---
_______________________________________________ tcpdump-workers mailing list tcpdump-workers () lists tcpdump org https://lists.sandelman.ca/mailman/listinfo/tcpdump-workers
Current thread:
- clean exit from tcpdump with asan enh via tcpdump-workers (Oct 14)
- <Possible follow-ups>
- Re: clean exit from tcpdump with asan enh via tcpdump-workers (Oct 19)
- Message not available
- Re: clean exit from tcpdump with asan enh via tcpdump-workers (Oct 27)
- Message not available
