.exe folder detection

Hello all..
I will have to detect .exe folder in a drive for my Project .. what is the basic idea to do this ??
as i know.exe folder which we see is actually a file having folder icon ...
how can i check it ?

Advance thanks to all ...
What is a ".exe folder"?
If we have a folder named "A" then sometimes virus creates a file name A.exe having a folder icon
me saying that file exe folder
I'm sorry, I'm still not getting it. Are you trying to detect what directory this "virus" has placed itself in?
I think what he is trying to say is that sometimes viruses will name themselves something, but give themselves the "folder" icon so it looks like they are a folder (with show extensions turned off).
Oh, so you double click the folder (to open it) and it runs the virus? I see.

Well if you want to detect whether it's an executable file or not, you could try parsing the binary header. The windows executable format is called PE (portable executable).
http://en.wikipedia.org/wiki/Portable_Executable

You could try and find something about the structure of a windows PE file and parse the header, to check if it's an executable file. If it is, you can do whatever you want.


I'm an idiot. Parsing a binary file's header is about the most backwards and braindead idea I've had all day.

You just need the dirent library so you can check if it's a directory or not, not the other way round!

http://en.wikipedia.org/wiki/Dirent.h

Actually, does dirent work on windows?
MinGW provides an implementation of dirent.h
Topic archived. No new replies allowed.