Tuesday, July 28, 2009

Does anyone here know C++? I just need some really basic info please.?

Can C++ manipulate EVERY aspect of a computer? Also, I want to create a keylogger not to spy on anyone else, but to obtain information that is typed on my computer for my own personal reference. Can anyone give me the basic steps on how to create one?





P.S.: I have just purchased "C++ for Dummies" and am using Dev-C++, would this be enough to create a keylogger?





P.P.S.: I DO NOT WANT TO USE ANY COMPANY'S KEYLOGGER, I WANT TO MAKE ONE MYSELF.

Does anyone here know C++? I just need some really basic info please.?
%26gt; Can C++ manipulate EVERY aspect of a computer?


Well, not quite. You'll get the wrong idea if I give you a yes/no answer though. It isn't really possible to cease control over every part of the computer, as you still have to play the rules of the OS. You'll most likely gain your best level of control through assembly, or assembly with a combination of C or C++. C++ gets you quite a bit of low level control though.





%26gt; Also, I want to create a keylogger not to spy on anyone else, but to obtain information that is typed on my computer for my own personal reference.


Why don't you just download from one the internet and use that?





%26gt; Can anyone give me the basic steps on how to create one?


Not really. It isn't a five step process. You'll end up having to hook into the windows OS, to intercept all keyboard messages. A basic keylogger would do that. A more advanced keylogger would probably be a bit more effective in catching keystrokes, like those from an on screen keyboard or preventing attempts to "fool" keyloggers.





%26gt; P.S.: I have just purchased "C++ for Dummies" and am using Dev-C++, would this be enough to create a keylogger?


I consider C++ For Dummies to be a terrible book. If you're really interested in learning C++, Accelerated C++ or C++ Primer by Lippman are better choices.





Dev-C++ is an IDE that uses MinGW. MinGW is your compiler that changes code to something that can execute on your computer. Can it create a keylogger? Maybe. It does come with the Windows API, so you should be able to write the hooking code. And of course anything is else just standard C++. You may want to use Visual C++ Express though. Make sure you download the Windows Platform SDK. Visual C++ Express is Microsoft's compiler. Windows Platform SDK allows you to write Windows applications. Microsoft's compiler may be preferrable because you are trying to take control over an aspect of Windows.





Caution. You may have the tools to make a keylogger, but you are quite far from the knowledge of how to make one. There may some keyloggers with their code open for others to see, available on the internet. Feel free to search and look through some of that code. If you can't decipher any of that C/C++ code, you're definitely at a level where you can't write your own from scratch.





If you haven't ever programmed before, you have a bigger challenge of learning computer science first.
Reply:Well, assembly is the language that literally can manipulate every aspect of the computer, but C++ is pretty close.





C++ for dummies will not show you how to create a keylogger (I don't think, but I don't know that book).





You will also need the Windows SDK. You should be able to download this for free from Microsoft, unless it came with your compiler. I don't know Dev C++, but I would like to think it came with the SDK. At any rate, you need the SDK (Software Development Kit, which lets you make operating system calls, etc).





Assuming you are on Windows, you need three components:





1) How to write a basic Windows app. Your keylogger would likely not have a UI (interface) but if you want to experiment, it wouldn't matter. If you did want to hide it, you'd have to make an app and hide the window (or spin a thread, but I suspect you're not at that point yet).





2) Second, the ability to "log", which is to write a file. This would normally be part three, but as you're just learning... you'll have to look up how to write, or actually append, stuff to a file. Look up "fileio" and basic FILE * operations, like fopen, fwrite, fclose. There are other ways of doing it, but this should be enough for what you want. You'll want to open a designated file up for append, and then write the new stuff to it.





3) The key capture itself. In the "old days" you would snag an interrupt, mainly with a TSR (Terminate %26amp; Stay Resident) app, and this wasn't for the faint of heart to put together.





What you will want to do with Windows is establish a keyboard hook, so your function gets called every time the keyboard is used. Look up "SetWindowsHook" or "SetWindowsHookEx", if I recall correctly.





I will say that this is not beginner stuff. You might do well to find someone to work with who can help you noodle it out.





Good luck!
Reply:I just use a piece of common oak. When the computer irritates me, I BASH the keyboard with my key logger.


No comments:

Post a Comment