Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > C/C++
You last visited: Today at 16:45

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Basic Dll Injection

Discussion on Basic Dll Injection within the C/C++ forum part of the Coders Den category.

Closed Thread
 
Old   #1
 
elite*gold: 0
Join Date: Feb 2013
Posts: 6
Received Thanks: 0
Basic Dll Injection

Hello .... even if i'm injecting this dll to any process, it just doesn't execute the main frunction


PHP Code:
#include <windows.h>
#include <stdio.h>
#include <stdlib.h>

void Hello ()
{
MessageBox (0"Hello from injected DLL!\n""Hi"MB_ICONINFORMATION);
}


BOOL APIENTRY DllMain (HINSTANCE hInst /* Library instance handle. */ ,
DWORD reason /* Reason this function is being called. */ ,
LPVOID reserved /* Not used. */ )
{
switch (
reason)
{
case 
DLL_PROCESS_ATTACH:
Hello();
break;

case 
DLL_PROCESS_DETACH:
Hello();
break;

case 
DLL_THREAD_ATTACH:
Hello();
break;

case 
DLL_THREAD_DETACH:
Hello();
break;
}

/* Returns TRUE on success, FALSE on failure */
return TRUE;

BeliveInNothing is offline  
Old 02/25/2013, 20:06   #2
 
C!rcle's Avatar
 
elite*gold: 0
Join Date: Sep 2012
Posts: 83
Received Thanks: 358
Code:
#include <windows.h>

void Hello()
{
	MessageBox (0, "Hello from injected DLL!\n", "Hi", MB_ICONINFORMATION);
}

DWORD WINAPI DllMain(HINSTANCE hInstance,DWORD dwReason,LPVOID lpReserved)
{
	switch(dwReason)
	{
		case DLL_PROCESS_ATTACH:
			Hello();
		break;
	}
	return 1;
}
That's just my way but it should work.
C!rcle is offline  
Thanks
1 User
Old 02/25/2013, 20:10   #3




 
bloodx's Avatar
 
elite*gold: 55
Join Date: Mar 2006
Posts: 4,582
Received Thanks: 1,539
Code:
#include <windows.h>

void Hello()
{
	MessageBox( 0 , L"Hello dude" , L"Hi!" , MB_OK );
}
unsigned long __stdcall DllMain( HMODULE , unsigned long  ul_reason_for_call, LPVOID )
{
	switch (ul_reason_for_call)
	{
	case DLL_PROCESS_ATTACH:
		Hello();
	case DLL_THREAD_ATTACH:
	case DLL_THREAD_DETACH:
	case DLL_PROCESS_DETACH:
		break;
	}

	return 1;
}
bloodx is offline  
Thanks
1 User
Old 02/25/2013, 20:56   #4
 
elite*gold: 0
Join Date: Feb 2013
Posts: 6
Received Thanks: 0
I still don't get the MsgBox... if anyone is able to gelp me, add me on skype: theshadowscall

Thanks
BeliveInNothing is offline  
Old 02/25/2013, 23:04   #5

 
Delinquenz's Avatar
 
elite*gold: 0
Join Date: Jan 2009
Posts: 1,160
Received Thanks: 232
Which injector do you use? Maybe you used the wrong injection way?
Delinquenz is offline  
Thanks
1 User
Old 02/25/2013, 23:13   #6
 
elite*gold: 0
Join Date: Feb 2013
Posts: 6
Received Thanks: 0
I'm using Kernel Detective to inject libraries to prcesses
BeliveInNothing is offline  
Old 02/25/2013, 23:32   #7

 
Delinquenz's Avatar
 
elite*gold: 0
Join Date: Jan 2009
Posts: 1,160
Received Thanks: 232
Maybe you try something like WinJect? (Also an injector)
Delinquenz is offline  
Old 02/25/2013, 23:48   #8
 
elite*gold: 0
Join Date: Feb 2013
Posts: 6
Received Thanks: 0
I tried many injectors... none work. If you have time, add me on skype " theshadowscall" and i could show you by team viewer...
BeliveInNothing is offline  
Old 02/28/2013, 00:53   #9
 
elite*gold: 0
Join Date: Feb 2013
Posts: 6
Received Thanks: 0
Nobody can help me??? I tried every code found on the internet, but when injectng NOTHING HAPPENS
BeliveInNothing is offline  
Old 02/28/2013, 01:22   #10

 
Delinquenz's Avatar
 
elite*gold: 0
Join Date: Jan 2009
Posts: 1,160
Received Thanks: 232
It should work guy. We can't understand your problem, sorry.
Delinquenz is offline  
Old 02/28/2013, 01:39   #11
 
elite*gold: 0
Join Date: Feb 2013
Posts: 6
Received Thanks: 0
Maybe is because of my computer?

Can anyone inject this to any process and tell me if "calc.exe" is executed?thanks
Attached Files
File Type: rar DllMain.rar (127.2 KB, 10 views)
BeliveInNothing is offline  
Old 03/01/2013, 13:55   #12
 
iCraziE's Avatar
 
elite*gold: 0
Join Date: Jan 2010
Posts: 456
Received Thanks: 218
Not sure if this is necessary I know in order to use MessageBox you need to make sure you add the windows form resource.
iCraziE is offline  
Closed Thread


Similar Threads Similar Threads
SQL Injection
07/31/2012 - DarkOrbit - 20 Replies
Hallo, ich habe glaube ich eine SQL Injection-Lücke gefunden. Ich wollte nun fragen ob mir dabei jemand helfen kann, diese auszunutzten. English: Hello, I believe I found a SQL Injection in DarkOrbit. Now I wanted to ask if someone can help me to use this.
S> BM 105 (5aps basic) + Sin 101 ( 4 aps basic and 5 sparked ) + seeker 93 + others
05/18/2012 - Perfect World - 0 Replies
Hello, for the first the account are from Archosaur server and i'm selling it , the accoutn has sin 101 that is 4 aps basic and 5 sparked and on the same account i have also a bm 105 that is 5 aps basic and others fews chars ( wiz 83 seeker 93 , sin 77 archer 77 barb ) http://imageshack.us/photo/my-images/37/selldn.jp g/ the gear info of the sin is: http://imageshack.us/photo/my-images/822/dibujoaz n.jpg/ i'm listening offers , for more info
tausche 2 pirox bot keys,1-basic,elite,arschi so wie 1 basic suche 25 euro PSC
06/19/2011 - World of Warcraft Trading - 0 Replies
Hallo leute tausche/vk hier mein Pirox key erstbesitzer und besitze alle daten incl persokopie pvpTool *Basic* Bought on 1. June 2011, 12:29 Expires on 1. June 2036, 12:29 pvpTool *Elite* Bought on 1. June 2011, 12:33 Expires on 1. June 2036, 12:33
Pvptool | Basic und Basic+Elite
02/10/2011 - World of Warcraft Trading - 4 Replies
Hey leute, verkaufe hier folgendes: Basic Lifetime für 12€ und Basic+Elite für 20€. Bezahlen könnt ihr mit Paypal, Moneybookers, oder auch mit psc wenn ihr nen asucasher für pp/mb habt. Lg Robin_-
help in sql injection
11/10/2007 - Kal Online - 24 Replies
hello m8's do any body in here know some things in sql injection he could share with us search gimme alot of shit .. waiting for answer thnx



All times are GMT +1. The time now is 16:45.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.