Monday, April 6, 2009

Playing Video in Notepad---)

Million Dollor Question:
Would anybody tell how to play video in notepad..????
i m trying to make universal notepad.. i want to add these new features in it ...
video plying,image processing ,,opening 
php file on notepad etc...

u can hack a mfc or win32 program.. only to extent of changing built in icons.. menu and windows controls resources.. file atributes, manifest etc.. to play a video in notepad u NEED source code of notepad.. hacking won't do.. for playing video.. 


Unless what you want to do is convert the video into simple text (a bunch of gibberish) , then I don't think playing a video in notepad.exe is possible.

OK.. so u r making ur own version of notepad also hav source code of it.. so need DON'T NEED to hack..

ur choice was correct that OLE/activex/.net component/java applet/silverlight/flash pluggable components can be used to place a video in notepad..

actually u r topic should be playing video in ASCII/UNICODE txt file.. right..

now to achieve such a functinality in notepad u should use.. kind of of tags and place it in txt file.. whenever u parse the file.. and it enconters tags it excecuites the video/image or anything.. (same way as web page java applet works)
BUT U R TXT file can be opened in u r notepad only.. if u open u r txt file in other notepads.. it would show  instead of video.. THUS U R TXT FILE WILL NOT BE UNIVERSAL BUT FULLY DEPENDENT ON UR NOTEPAD

not to overcome such a situation.. only thing u can do it make the txt file binary (like doc, docx etc) register u r extention (say .ntp) with MIME.. so that it become a universal format

thus what u really need to develop is microsft word like application with u r own native file format (.ntp like .doc) except text formating features (i.e only plain text would be allow to type in ur .ntp file)

u can call this as text processing instead of word processing

regarding hacking of Microsoft notepad i was taking about resource editor built into visual studio .net.. when u open any mfc or win32 exe or dll in through open file dialog.. it shows u contents of that..
of-course there are third party resources editors which do even more..
try opening notepad.exe.. u can see dialog boxes, icons etc that can be changed !!!!!!!!! even after compilation. also save u r changes in the complied exe or dll.. this technique is used to hack or patch the uxtheme.dll etc for xp, vista etc so that user defined themes can be loaded other than luna (e.g. os leopard theme)..
Transformation packs use this feature of a win32 or mfc dll to change the appearance of xp/vista and apply a skin or theme

if u want to reverse engineer the notepad.exe first u got to find out any NOP Slides in the (.text) region of the image where u will insert the code but that region must be large enough to hold the opcode's of program
well i found out some 0x00's padding in notepad it follows after the .rdata region (import address table) of notepad it RVA is 0x00008747
but one thing u gotta dd is change the AddressOfEntryPoint of images 
base + offset (address)
i found out the base of notepad in WINXP SP2 is 0x01000000 ( may be diffrent for other versions of windows so keep that in mind too )
so its 
0x01000000 + 0x00008747 = 0x01008747
i have done the reverse eng for u check the uploaded exe file here but it dosent actually pay a video that thing will take lot of time so just for the injection it will display a message 

Any Other Answers?????? Do Reply

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.