Use socketpair on all Unix platforms
authorEugene Zemtsov <ezemtsov@google.com>
Mon, 25 Sep 2017 17:41:16 +0000 (17:41 +0000)
committerEugene Zemtsov <ezemtsov@google.com>
Mon, 25 Sep 2017 17:41:16 +0000 (17:41 +0000)
commit3015341d45d80663db6b38f238c435418dd98343
tree4cb2507a2071b24463e86c6d6e6342f5a367be26
parent761f0b660dd72addf67e1eb1e82f62abaafc9112
Use socketpair on all Unix platforms

Using TCP sockets is insecure against local attackers, and possibly
against remote attackers too (some vulnerabilities may allow tricking a
browser to make a request to localhost). Use socketpair (which is immune
to such attacks) on all Unix platforms.

Patch by Demi Marie Obenour < demiobenour@gmail.com >

Differential Revision: https://reviews.llvm.org/D33213

llvm-svn: 314127
lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
lldb/tools/lldb-server/lldb-gdbserver.cpp