angler-fishThe Vulnerability History Project

[Extensions] Don't allow gin::Define to be overridden

      Use DefineOwnProperty instead of Set in for gin, including gin::Define.
Replace Set in v8_helpers as well, to avoid the same problem.
Also update callsites from JS to CHECK expected arguments, rather
than DCHECK (since receiving unexpected arguments likely means
executing untrusted code).

BUG=549986

Review URL: https://codereview.chromium.org/1433293004

Cr-Commit-Position: refs/heads/master@{#359460}
    
commit 415b73b1a400a994a86e6f29709aa0271e895dd5
-26
-69
+4 -4
+5 -5
+9 -9
+2 -2
+10 -12
+1 -2
expand_less