1
0
mirror of https://github.com/golang/go synced 2024-10-05 01:21:21 -06:00
go/src
Brad Fitzpatrick 683448a304 runtime, syscall: only search for Windows DLLs in the System32 directory
Make sure that for any DLL that Go uses itself, we only look for the
DLL in the Windows System32 directory, guarding against DLL preloading
attacks.

(Unless the Windows version is ancient and LoadLibraryEx is
unavailable, in which case the user probably has bigger security
problems anyway.)

This does not change the behavior of syscall.LoadLibrary or NewLazyDLL
if the DLL name is something unused by Go itself.

This change also intentionally does not add any new API surface. Instead,
x/sys is updated with a LoadLibraryEx function and LazyDLL.Flags in:
    https://golang.org/cl/21388

Updates #14959

Change-Id: I8d29200559cc19edf8dcf41dbdd39a389cd6aeb9
Reviewed-on: https://go-review.googlesource.com/21140
Reviewed-by: Russ Cox <rsc@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2016-04-01 22:55:36 +00:00
..
archive all: delete dead test code 2016-03-21 07:10:08 +00:00
bufio all: delete dead test code 2016-03-21 07:10:08 +00:00
builtin
bytes all: delete dead test code 2016-03-21 07:10:08 +00:00
cmd runtime, syscall: only search for Windows DLLs in the System32 directory 2016-04-01 22:55:36 +00:00
compress all: use bytes.Equal, bytes.Contains and strings.Contains 2016-04-01 02:05:01 +00:00
container all: single space after period. 2016-03-02 00:13:47 +00:00
crypto all: use bytes.Equal, bytes.Contains and strings.Contains 2016-04-01 02:05:01 +00:00
database/sql all: delete dead non-test code 2016-03-25 06:28:13 +00:00
debug debug/elf: deflake file_test.go 2016-03-30 06:56:25 +00:00
encoding all: use bytes.Equal, bytes.Contains and strings.Contains 2016-04-01 02:05:01 +00:00
errors all: make copyright headers consistent with one space after period 2016-03-01 23:34:33 +00:00
expvar all: single space after period. 2016-03-02 00:13:47 +00:00
flag all: single space after period. 2016-03-02 00:13:47 +00:00
fmt fmt: fix padding for 0 precision 0 integer value formatting 2016-03-30 00:44:01 +00:00
go runtime, syscall: only search for Windows DLLs in the System32 directory 2016-04-01 22:55:36 +00:00
hash hash/crc64: Add tests for ECMA polynomial 2016-03-31 20:42:02 +00:00
html all: use bytes.Equal, bytes.Contains and strings.Contains 2016-04-01 02:05:01 +00:00
image image/jpeg: reconstruct progressive images even if incomplete. 2016-03-31 00:33:24 +00:00
index/suffixarray
internal runtime, syscall: only search for Windows DLLs in the System32 directory 2016-04-01 22:55:36 +00:00
io all: delete dead non-test code 2016-03-25 06:28:13 +00:00
log all: single space after period. 2016-03-02 00:13:47 +00:00
math math/big: much simplified and faster Float rounding 2016-03-22 17:07:34 +00:00
mime mime: fix maximum length of encoded-words 2016-03-29 11:19:31 +00:00
net net/http/httputil: deprecate Client+ServerConn harder, use Deprecated syntax 2016-04-01 00:53:26 +00:00
os os: skip TestStatStdin on Android 2016-03-24 19:07:11 +00:00
path path/filepath: use fsutil with TestEvalSymlinksCanonicalNames 2016-03-29 05:02:40 +00:00
reflect reflect: implement StructOf 2016-04-01 14:56:21 +00:00
regexp all: delete dead non-test code 2016-03-25 06:28:13 +00:00
runtime runtime, syscall: only search for Windows DLLs in the System32 directory 2016-04-01 22:55:36 +00:00
sort all: delete dead non-test code 2016-03-25 06:28:13 +00:00
strconv all: single space after period. 2016-03-02 00:13:47 +00:00
strings all: single space after period. 2016-03-02 00:13:47 +00:00
sync sync: don't assume b.N > 0 2016-03-18 16:37:39 +00:00
syscall runtime, syscall: only search for Windows DLLs in the System32 directory 2016-04-01 22:55:36 +00:00
testing cmd/go: fix proc-count accumulation in benchmark name 2016-03-26 16:44:01 +00:00
text all: delete dead non-test code 2016-03-25 06:28:13 +00:00
time all: delete dead non-test code 2016-03-25 06:28:13 +00:00
unicode all: single space after period. 2016-03-02 00:13:47 +00:00
unsafe all: single space after period. 2016-03-02 00:13:47 +00:00
vendor/golang.org/x/net/http2/hpack net/http: update bundled http2 2016-04-01 00:47:29 +00:00
all.bash
all.bat
all.rc
androidtest.bash
bootstrap.bash
buildall.bash build: use go tool dist list 2016-02-26 03:58:58 +00:00
clean.bash
clean.bat
clean.rc
iostest.bash
make.bash cmd/dist: redo flag-passing for bootstrap 2016-03-18 19:00:03 +00:00
make.bat cmd/go, go/build: add support for Fortran 2016-02-24 15:06:38 +00:00
Make.dist
make.rc
nacltest.bash
race.bash
race.bat
run.bash
run.bat
run.rc