Jump to content
Sign in to follow this  
Crome_BAD

Firewall DLL

Recommended Posts

Crome_BAD

Hey guys, im starting to make a firewall dll, and i was wondering how to tell if its actually working, lol i dont seem to get errors.....but, ya never kno, lol

Heres The Dll:

http://www.autoitscript.com/fileman/users/public/Crome_BAD/fw.zip

Heres My Test Code:

#include <GUIConstants.AU3>

$MainGUI = GUICreate("Brian's Firewall", 400, 300, -1, -1)

$Input = GUICtrlCreateInput("", 250, 50, 100, 20, $WS_DISABLED)

$StartB = GUICtrlCreateButton("Start Firewall", 100, 10, 100, 20)


GUISetState()

While 1
   
   $msg = GUIGetMsg()
   
   If $msg = $GUI_EVENT_CLOSE Then
      ExitLoop
   EndIf
   
   If $msg = $StartB Then
      StartFW($Input)
   EndIf
   
WEnd

DllCall("fw.dll", "int", "FireWallEnable", "short", "AF_UNSPEC", "int", "FALSE", "int", "FALSE")

Func StartFW($Input)
   
   $FWCheck = DllCall("fw.dll", "int", "IsFireWallEnabled", "short", "AF_INET6")
   
   $FWStart = DllCall("fw.dll", "int", "FireWallEnable", "short", "AF_UNSPEC", "int", "TRUE", "int", "FALSE")
   
   MsgBox(4096, "FireWall Start", $FWStart)
   
   GUICtrlSetData($Input, "Running...")
   
EndFunc

@Larry

Please help me, my VERY first dll, and i love your AU3Xtra.dll file, thanks

Peace,

Crome_BAD

No ideas Guys?

Edited by Crome_BAD

Share this post


Link to post
Share on other sites
Crome_BAD

No ideas guys? Should i try and program the dll FIRST through visual basic or?

Please Post Back

Crome

Share this post


Link to post
Share on other sites
SlimShady

Why don't you test it with a P2P program?

Share this post


Link to post
Share on other sites
Crome_BAD

Like? Sorry new at DLL's, lol, i dont even think i compiled it right, when i was in MSDN it said it required FWAPI.H (Header file) and i couldnt find it....sooo.

Thanks for your response

Crome

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×