mirror of
https://github.com/RGBCube/serenity
synced 2025-07-08 02:27:35 +00:00

Fuzzilli is a JavaScript engine fuzzer made by googleprojectzero. https://github.com/googleprojectzero/fuzzilli/
44 lines
1.1 KiB
Diff
44 lines
1.1 KiB
Diff
diff --git a/Sources/FuzzilliCli/Profiles/Profile.swift b/Sources/FuzzilliCli/Profiles/Profile.swift
|
|
index 6d8a795..a506d41 100644
|
|
--- a/Sources/FuzzilliCli/Profiles/Profile.swift
|
|
+++ b/Sources/FuzzilliCli/Profiles/Profile.swift
|
|
@@ -32,6 +32,33 @@ struct Profile {
|
|
let additionalBuiltins: [String: Type]
|
|
}
|
|
|
|
+let serenityProfile = Profile(
|
|
+ processArguments: [""],
|
|
+
|
|
+ processEnv: ["UBSAN_OPTIONS":"handle_segv=0 handle_abrt=0"],
|
|
+
|
|
+ codePrefix: """
|
|
+ function main() {
|
|
+ """,
|
|
+
|
|
+ codeSuffix: """
|
|
+ }
|
|
+ main();
|
|
+ """,
|
|
+
|
|
+ ecmaVersion: ECMAScriptVersion.es6,
|
|
+
|
|
+ crashTests: ["fuzzilli('FUZZILLI_CRASH', 0)", "fuzzilli('FUZZILLI_CRASH', 1)"],
|
|
+
|
|
+ additionalCodeGenerators: WeightedList<CodeGenerator>([]),
|
|
+
|
|
+ disabledCodeGenerators: [],
|
|
+
|
|
+ additionalBuiltins: [
|
|
+ "gc" : .function([] => .undefined)
|
|
+ ]
|
|
+)
|
|
+
|
|
let profiles = [
|
|
"qjs": qjsProfile,
|
|
"jsc": jscProfile,
|
|
@@ -39,4 +66,5 @@ let profiles = [
|
|
"v8": v8Profile,
|
|
"duktape": duktapeProfile,
|
|
"jerryscript": jerryscriptProfile,
|
|
+ "serenity": serenityProfile,
|
|
]
|