Skip to content
This repository was archived by the owner on Mar 22, 2024. It is now read-only.

Commit 1970cbc

Browse files
committed
Merge branch 'master' of https://github.com/JoeyJiao/AFL
2 parents 327eb39 + 75d6ee4 commit 1970cbc

File tree

4 files changed

+386
-2
lines changed

4 files changed

+386
-2
lines changed

Android.bp

Lines changed: 140 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,140 @@
1+
cc_defaults {
2+
name: "afl-defaults",
3+
4+
cflags: [
5+
"-funroll-loops",
6+
"-Wno-pointer-sign",
7+
"-Wno-pointer-arith",
8+
"-Wno-sign-compare",
9+
"-Wno-unused-parameter",
10+
"-Wno-unused-function",
11+
"-Wno-format",
12+
"-Wno-user-defined-warnings",
13+
"-DUSE_TRACE_PC=1",
14+
"-DBIN_PATH=\"out/host/linux-x86/bin\"",
15+
"-DDOC_PATH=\"out/host/linux-x86/shared/doc/afl\"",
16+
"-D__USE_GNU",
17+
],
18+
}
19+
20+
cc_binary {
21+
name: "afl-fuzz",
22+
static_executable: true,
23+
host_supported: true,
24+
25+
defaults: [
26+
"afl-defaults",
27+
],
28+
29+
srcs: [
30+
"afl-fuzz.c",
31+
],
32+
}
33+
34+
cc_binary {
35+
name: "afl-showmap",
36+
static_executable: true,
37+
host_supported: true,
38+
39+
defaults: [
40+
"afl-defaults",
41+
],
42+
43+
srcs: [
44+
"afl-showmap.c",
45+
],
46+
}
47+
48+
cc_binary {
49+
name: "afl-tmin",
50+
static_executable: true,
51+
host_supported: true,
52+
53+
defaults: [
54+
"afl-defaults",
55+
],
56+
57+
srcs: [
58+
"afl-tmin.c",
59+
],
60+
}
61+
62+
cc_binary {
63+
name: "afl-analyze",
64+
static_executable: true,
65+
host_supported: true,
66+
67+
defaults: [
68+
"afl-defaults",
69+
],
70+
71+
srcs: [
72+
"afl-analyze.c",
73+
],
74+
}
75+
76+
cc_binary {
77+
name: "afl-gotcpu",
78+
static_executable: true,
79+
host_supported: true,
80+
81+
defaults: [
82+
"afl-defaults",
83+
],
84+
85+
srcs: [
86+
"afl-gotcpu.c",
87+
],
88+
}
89+
90+
cc_binary_host {
91+
name: "afl-clang-fast",
92+
static_executable: true,
93+
94+
defaults: [
95+
"afl-defaults",
96+
],
97+
98+
cflags: [
99+
"-D__ANDROID__",
100+
"-DAFL_PATH=\"out/host/linux-x86/lib64\"",
101+
],
102+
103+
srcs: [
104+
"llvm_mode/afl-clang-fast.c",
105+
],
106+
}
107+
108+
cc_binary_host {
109+
name: "afl-clang-fast++",
110+
static_executable: true,
111+
112+
defaults: [
113+
"afl-defaults",
114+
],
115+
116+
cflags: [
117+
"-D__ANDROID__",
118+
"-DAFL_PATH=\"out/host/linux-x86/lib64\"",
119+
],
120+
121+
srcs: [
122+
"llvm_mode/afl-clang-fast.c",
123+
],
124+
}
125+
126+
cc_library_static {
127+
name: "afl-llvm-rt",
128+
compile_multilib: "both",
129+
vendor_available: true,
130+
host_supported: true,
131+
recovery_available: true,
132+
133+
defaults: [
134+
"afl-defaults",
135+
],
136+
137+
srcs: [
138+
"llvm_mode/afl-llvm-rt.o.c",
139+
],
140+
}

afl-gotcpu.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ int main(int argc, char** argv) {
157157

158158
if (util_perc < 110) {
159159

160-
SAYF(" Core #%u: " cLGN "AVAILABLE\n" cRST, i);
160+
SAYF(" Core #%u: " cLGN "AVAILABLE " cRST "(%u%%)\n", i, util_perc);
161161
exit(0);
162162

163163
} else if (util_perc < 250) {

dictionaries/regexp.dict

Lines changed: 238 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,238 @@
1+
#
2+
# AFL dictionary for JS regex
3+
# ---------------------------
4+
#
5+
# Contains various regular expressions.
6+
#
7+
# Created by Yang Guo <[email protected]>
8+
#
9+
"?"
10+
"abc"
11+
"()"
12+
"[]"
13+
"abc|def"
14+
"abc|def|ghi"
15+
"^xxx$"
16+
"ab\\b\\d\\bcd"
17+
"\\w|\\d"
18+
"a*?"
19+
"abc+"
20+
"abc+?"
21+
"xyz?"
22+
"xyz??"
23+
"xyz{0,1}"
24+
"xyz{0,1}?"
25+
"xyz{93}"
26+
"xyz{1,32}"
27+
"xyz{1,32}?"
28+
"xyz{1,}"
29+
"xyz{1,}?"
30+
"a\\fb\\nc\\rd\\te\\vf"
31+
"a\\nb\\bc"
32+
"(?:foo)"
33+
"(?: foo )"
34+
"foo|(bar|baz)|quux"
35+
"foo(?=bar)baz"
36+
"foo(?!bar)baz"
37+
"foo(?<=bar)baz"
38+
"foo(?<!bar)baz"
39+
"()"
40+
"(?=)"
41+
"[]"
42+
"[x]"
43+
"[xyz]"
44+
"[a-zA-Z0-9]"
45+
"[-123]"
46+
"[^123]"
47+
"]"
48+
"}"
49+
"[a-b-c]"
50+
"[x\\dz]"
51+
"[\\d-z]"
52+
"[\\d-\\d]"
53+
"[z-\\d]"
54+
"\\cj\\cJ\\ci\\cI\\ck\\cK"
55+
"\\c!"
56+
"\\c_"
57+
"\\c~"
58+
"[\\c!]"
59+
"[\\c_]"
60+
"[\\c~]"
61+
"[\\ca]"
62+
"[\\cz]"
63+
"[\\cA]"
64+
"[\\cZ]"
65+
"[\\c1]"
66+
"\\[\\]\\{\\}\\(\\)\\%\\^\\#\\ "
67+
"[\\[\\]\\{\\}\\(\\)\\%\\^\\#\\ ]"
68+
"\\8"
69+
"\\9"
70+
"\\11"
71+
"\\11a"
72+
"\\011"
73+
"\\118"
74+
"\\111"
75+
"\\1111"
76+
"(x)(x)(x)\\1"
77+
"(x)(x)(x)\\2"
78+
"(x)(x)(x)\\3"
79+
"(x)(x)(x)\\4"
80+
"(x)(x)(x)\\1*"
81+
"(x)(x)(x)\\3*"
82+
"(x)(x)(x)\\4*"
83+
"(x)(x)(x)(x)(x)(x)(x)(x)(x)(x)\\10"
84+
"(x)(x)(x)(x)(x)(x)(x)(x)(x)(x)\\11"
85+
"(a)\\1"
86+
"(a\\1)"
87+
"(\\1a)"
88+
"(\\2)(\\1)"
89+
"(?=a){0,10}a"
90+
"(?=a){1,10}a"
91+
"(?=a){9,10}a"
92+
"(?!a)?a"
93+
"\\1(a)"
94+
"(?!(a))\\1"
95+
"(?!\\1(a\\1)\\1)\\1"
96+
"\\1\\2(a(?:\\1(b\\1\\2))\\2)\\1"
97+
"[\\0]"
98+
"[\\11]"
99+
"[\\11a]"
100+
"[\\011]"
101+
"[\\00011]"
102+
"[\\118]"
103+
"[\\111]"
104+
"[\\1111]"
105+
"\\x60"
106+
"\\x3z"
107+
"\\c"
108+
"\\u0034"
109+
"\\u003z"
110+
"foo[z]*"
111+
"\\u{12345}"
112+
"\\u{12345}\\u{23456}"
113+
"\\u{12345}{3}"
114+
"\\u{12345}*"
115+
"\\ud808\\udf45*"
116+
"[\\ud808\\udf45-\\ud809\\udccc]"
117+
"a"
118+
"a|b"
119+
"a\\n"
120+
"a$"
121+
"a\\b!"
122+
"a\\Bb"
123+
"a*?"
124+
"a?"
125+
"a??"
126+
"a{0,1}?"
127+
"a{1,2}?"
128+
"a+?"
129+
"(a)"
130+
"(a)\\1"
131+
"(\\1a)"
132+
"\\1(a)"
133+
"a\\s"
134+
"a\\S"
135+
"a\\D"
136+
"a\\w"
137+
"a\\W"
138+
"a."
139+
"a\\q"
140+
"a[a]"
141+
"a[^a]"
142+
"a[a-z]"
143+
"a(?:b)"
144+
"a(?=b)"
145+
"a(?!b)"
146+
"\\x60"
147+
"\\u0060"
148+
"\\cA"
149+
"\\q"
150+
"\\1112"
151+
"(a)\\1"
152+
"(?!a)?a\\1"
153+
"(?:(?=a))a\\1"
154+
"a{}"
155+
"a{,}"
156+
"a{"
157+
"a{z}"
158+
"a{12z}"
159+
"a{12,"
160+
"a{12,3b"
161+
"{}"
162+
"{,}"
163+
"{"
164+
"{z}"
165+
"{1z}"
166+
"{12,"
167+
"{12,3b"
168+
"a"
169+
"abc"
170+
"a[bc]d"
171+
"a|bc"
172+
"ab|c"
173+
"a||bc"
174+
"(?:ab)"
175+
"(?:ab|cde)"
176+
"(?:ab)|cde"
177+
"(ab)"
178+
"(ab|cde)"
179+
"(ab)\\1"
180+
"(ab|cde)\\1"
181+
"(?:ab)?"
182+
"(?:ab)+"
183+
"a?"
184+
"a+"
185+
"a??"
186+
"a*?"
187+
"a+?"
188+
"(?:a?)?"
189+
"(?:a+)?"
190+
"(?:a?)+"
191+
"(?:a*)+"
192+
"(?:a+)+"
193+
"(?:a?)*"
194+
"(?:a*)*"
195+
"(?:a+)*"
196+
"a{0}"
197+
"(?:a+){0,0}"
198+
"a*b"
199+
"a+b"
200+
"a*b|c"
201+
"a+b|c"
202+
"(?:a{5,1000000}){3,1000000}"
203+
"(?:ab){4,7}"
204+
"a\\bc"
205+
"a\\sc"
206+
"a\\Sc"
207+
"a(?=b)c"
208+
"a(?=bbb|bb)c"
209+
"a(?!bbb|bb)c"
210+
"\xe2\x81\xa3"
211+
"[\xe2\x81\xa3]"
212+
"\xed\xb0\x80"
213+
"\xed\xa0\x80"
214+
"(\xed\xb0\x80)\x01"
215+
"((\xed\xa0\x80))\x02"
216+
"\xf0\x9f\x92\xa9"
217+
"\x01"
218+
"\x0f"
219+
"[-\xf0\x9f\x92\xa9]+"
220+
"[\xf0\x9f\x92\xa9-\xf4\x8f\xbf\xbf]"
221+
"(?<=)"
222+
"(?<=a)"
223+
"(?<!)"
224+
"(?<!a)"
225+
"(?<a>)"
226+
"(?<a>.)"
227+
"(?<a>.)\\k<a>"
228+
"\\p{Script=Greek}"
229+
"\\P{sc=Greek}"
230+
"\\p{Script_Extensions=Greek}"
231+
"\\P{scx=Greek}"
232+
"\\p{General_Category=Decimal_Number}"
233+
"\\P{gc=Decimal_Number}"
234+
"\\p{gc=Nd}"
235+
"\\P{Decimal_Number}"
236+
"\\p{Nd}"
237+
"\\P{Any}"
238+
"\\p{Changes_When_NFKC_Casefolded}"

0 commit comments

Comments
 (0)