forked from TheKingOfDuck/easyXssPayload
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathxss.py
More file actions
28 lines (27 loc) · 668 Bytes
/
Copy pathxss.py
File metadata and controls
28 lines (27 loc) · 668 Bytes
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
# -*- coding: utf-8 -*-
"""
-------------------------------------------------
File Name: xss
Description :
Author : CoolCat
date: 2019/4/27
-------------------------------------------------
Change Activity:
2019/4/27:
-------------------------------------------------
"""
__author__ = 'CoolCat'
import re
n = 0
for xss in open("xssPayload.txt"):
n += 1
try:
alert = re.findall(r"alert\((.+?)\)", xss)
print(alert[0])
xss = xss.replace(alert[0],str(n))
print(xss)
f = open("easyXssPayload.txt","a")
f.write(xss)
f.close()
except:
pass