Skip to content

Commit cac4da0

Browse files
committed
deps: allow disabling V8 untrusted code mitigations
Add a GYP flag similar to the one defined in BUILD.gn. PR-URL: #19222 Reviewed-By: Fedor Indutny <fedor.indutny@gmail.com> Reviewed-By: Yang Guo <yangguo@chromium.org> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benedikt Meurer <benedikt.meurer@gmail.com> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
1 parent 54de79b commit cac4da0

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

common.gypi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727

2828
# Reset this number to 0 on major V8 upgrades.
2929
# Increment by one for each non-official patch applied to deps/v8.
30-
'v8_embedder_string': '-node.4',
30+
'v8_embedder_string': '-node.5',
3131

3232
# Enable disassembler for `--print-code` v8 options
3333
'v8_enable_disassembler': 1,

deps/v8/gypfiles/features.gypi

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,9 @@
8989

9090
# Controls the threshold for on-heap/off-heap Typed Arrays.
9191
'v8_typed_array_max_size_in_heap%': 64,
92+
93+
# Enable mitigations for executing untrusted code.
94+
'v8_untrusted_code_mitigations%': 'true',
9295
},
9396
'target_defaults': {
9497
'conditions': [
@@ -143,6 +146,9 @@
143146
['v8_enable_concurrent_marking==1', {
144147
'defines': ['V8_CONCURRENT_MARKING',],
145148
}],
149+
['v8_untrusted_code_mitigations=="false"', {
150+
'defines': ['DISABLE_UNTRUSTED_CODE_MITIGATIONS',],
151+
}],
146152
], # conditions
147153
'configurations': {
148154
'DebugBaseCommon': {

0 commit comments

Comments
 (0)