summaryrefslogtreecommitdiff
path: root/BUILD.gn
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2017-09-08 10:18:37 -0700
committerChromium commit bot <commit-bot@chromium.org>2017-09-08 17:37:10 +0000
commite8b3e0cdcea319abf82639edb5e074ff94c4d66c (patch)
treeef41a1e8955acd12d92d1635b5e35ff9914efb3d /BUILD.gn
parent808b52ac76bb5d9ee3e6a8371ddab25f62c8ed51 (diff)
downloadpdfium-e8b3e0cdcea319abf82639edb5e074ff94c4d66c.tar.xz
Fix one-second spin in fx_random.cpp
Take seed generation logic from base's address_space_randomization.cc. One small tweak is to avoid the bottom three bits of a stack address and invert, to make leaking ASLR more difficult along the lines of the freelist masking in base's partition allocator. Another tweak is to mix in some more time-based information. Another tweak is to add in the times called so that rapid successive calls return different results. Bug: pdfium:891 Change-Id: I14238da15cee9c8d4ca72d79e4f7fbb26997c619 Reviewed-on: https://pdfium-review.googlesource.com/13490 Reviewed-by: Henrique Nakashima <hnakashima@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'BUILD.gn')
-rw-r--r--BUILD.gn1
1 files changed, 1 insertions, 0 deletions
diff --git a/BUILD.gn b/BUILD.gn
index deaa706b8d..ca4c9ee1a5 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -1932,6 +1932,7 @@ test("pdfium_unittests") {
"core/fxcrt/fx_coordinates_unittest.cpp",
"core/fxcrt/fx_extension_unittest.cpp",
"core/fxcrt/fx_memory_unittest.cpp",
+ "core/fxcrt/fx_random_unittest.cpp",
"core/fxcrt/fx_string_unittest.cpp",
"core/fxcrt/fx_system_unittest.cpp",
"core/fxge/dib/cstretchengine_unittest.cpp",