Jump to content
Sign in to follow this  
Possessed

Need help with my script please.

Recommended Posts

Possessed

Ok so i am making this simple Email spoofer just for kicks but it seems to not get anything from the input boxes ;) you think you could help me anyone...? And yes i know my code is kinda all over the place :P

#include <GUIConstants.au3>
#include <INet.au3>

GUISetOnEvent($GUI_EVENT_CLOSE, "Special")
GUICreate("Email Spoofer  v1.0.0",256,480)
GUISetState (@SW_SHOW)
GUISetBkColor (0x000000)
GUICtrlCreatePic("logo-Emailspoofer.jpg",0,0,256,64)
;---------------Lablels--------
GUICtrlCreateLabel ("From:",145,60,100,)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("To:", 10,60,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("Subject:",10,105,100,)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("Message:",10,150,100,)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("SMTP Servers:",10,375,90,)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
;---------My ini stuff---------

$T_STR = ""
$ARRAY = IniReadSection("SMTP servers.ini", "SMTP")
If @error Then
    MsgBox(4096, "Error occured", ", Error reading : " & @ScriptDir & "\SMTP servers.ini file.")
    Exit
Else
    For $I = 1 To $ARRAY[0][0]
        If (StringLen($T_STR) == 0) Then
            $T_STR = $ARRAY[$I][1]
        Else
            $T_STR = $T_STR & "|" & $ARRAY[$I][1]
        EndIf
    Next
EndIf

;---------Button's-------------
$Button1 = GUICtrlCreateButton("Send", 9, 440, 240, 30, 0)
           GUICtrlSetFont(-1, 12, 400, 0, "Lucida Console")
           GUICtrlSetCursor ($Button1, 0)
           GUICtrlSetOnEvent(-1, "Emailspoof")   
    
;--------GUI Input-------
$To =   GUICtrlCreateInput  ("", 10,  75, 100, 20)
        GUICtrlSetTip(-1,"Put victim's Email here.")
$From = GUICtrlCreateInput ( "", 145,  75, 100, 20)
        GUICtrlSetTip(-1,"Put Spoof Email here.")
$Subject = GUICtrlCreateInput  ("", 10, 120, 100, 20)
        GUICtrlSetTip(-1,"Subject of Email goes here.")
        
$msg = GUICtrlCreateEdit ("", 10,165,235,200,$ES_AUTOVSCROLL+$WS_VSCROLL)

$SMTPList = GUICtrlCreateCombo ("", 10, 390,200,$CBS_DROPDOWNLIST )
GUICtrlSetData(-1, $T_STR, $ARRAY[1][1]); add other items

;Handling the GUI
While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE;Exit form GUI
            Exitloop
        Case $msg = $Button1
            Emailspoof()
        Case Else
       ; Something else
    EndSelect
Wend

Exit

;---------Func's---------------
func Special()
   
EndFunc


Func Emailspoof()
MsgBox(4096,"Working!",$SMTPList )
MsgBox(4096,"Working!",$From )
MsgBox(4096,"Working!",$To )
MsgBox(4096,"Working!",$Subject )
MsgBox(4096,"Working!",$msg )
;$s_SmtpServer = $SMTPList
;$s_FromName = $From
;$s_FromAddress = $From
;$s_ToAddress = $To
;$s_Subject = $Subject
;$as_Body = $msg

$Response = _INetSmtpMail ($s_SmtpServer, $s_FromName, $s_FromAddress, $s_ToAddress, $s_Subject, $as_Body)
    EndFunc

Share this post


Link to post
Share on other sites
Baloven

CODE
;---------------Lablels--------

GUICtrlCreateLabel ("From:",145,60,100,)

GUICtrlSetColor(-1,0x00FF33); LimeGreen

GUICtrlCreateLabel ("To:", 10,60,100)

GUICtrlSetColor(-1,0x00FF33); LimeGreen

GUICtrlCreateLabel ("Subject:",10,105,100,)

GUICtrlSetColor(-1,0x00FF33); LimeGreen

GUICtrlCreateLabel ("Message:",10,150,100,)

GUICtrlSetColor(-1,0x00FF33); LimeGreen

GUICtrlCreateLabel ("SMTP Servers:",10,375,90

;---------My ini stuff---------

It's works:

;---------------Lablels--------
GUICtrlCreateLabel ("From:",145,60,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("To:", 10,60,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("Subject:",10,105,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("Message:",10,150,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("SMTP Servers:",10,375,90)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
;---------My ini stuff---------
Edited by Baloven

Share this post


Link to post
Share on other sites
Possessed

This is not the part that has somthing wrong with it. it is getting the data from the gui input and combo to the Email stuff...

Func Emailspoof()
MsgBox(4096,"Working!",$SMTPList ) >-----This is all test code!
MsgBox(4096,"Working!",$From )    |
MsgBox(4096,"Working!",$To )          |
MsgBox(4096,"Working!",$Subject )   |
MsgBox(4096,"Working!",$msg )   - ^
;$s_SmtpServer = $SMTPList
;$s_FromName = $From
;$s_FromAddress = $From
;$s_ToAddress = $To
;$s_Subject = $Subject
;$as_Body = $msg

$Response = _INetSmtpMail ($s_SmtpServer, $s_FromName, $s_FromAddress, $s_ToAddress, $s_Subject, $as_Body)
    EndFunc

Share this post


Link to post
Share on other sites
Baloven

That in file SMTP servers.ini?

To receive value GUI use GUICtrlRead (controlID [, advanced]). For example

MsgBox (4096, " Working! ", GUICtrlRead ($SMTPList))
Edited by Baloven

Share this post


Link to post
Share on other sites
Possessed

ok am having still the same problem heres what i have now could someone look at the "Emailspoof" Func i really do think its not right some how. All i want it to do is send the Email when the right info is typed in the input boxes should not be this hard. :P

#include <GUIConstants.au3>
#include <INet.au3>

GUISetOnEvent($GUI_EVENT_CLOSE, "Special")
GUICreate("Email Spoofer  v1.0.0",256,480)
GUISetState (@SW_SHOW)
GUISetBkColor (0x000000)
GUICtrlCreatePic("logo-Emailspoofer.jpg",0,0,256,64)
;---------------Lablels--------
GUICtrlCreateLabel ("From:",145,60,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("To:", 10,60,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("Subject:",10,105,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("Message:",10,150,100)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
GUICtrlCreateLabel ("SMTP Servers:",10,375,90)
GUICtrlSetColor(-1,0x00FF33); LimeGreen
;---------My ini stuff---------

$T_STR = ""
$ARRAY = IniReadSection("SMTP servers.ini", "SMTP")
If @error Then
    MsgBox(4096, "Error occured", ", Error reading : " & @ScriptDir & "\SMTP servers.ini file.")
    Exit
Else
    For $I = 1 To $ARRAY[0][0]
        If (StringLen($T_STR) == 0) Then
            $T_STR = $ARRAY[$I][1]
        Else
            $T_STR = $T_STR & "|" & $ARRAY[$I][1]
        EndIf
    Next
EndIf

;---------Button's-------------
$Button1 = GUICtrlCreateButton("Send", 9, 440, 240, 30, 0)
           GUICtrlSetFont(-1, 12, 400, 0, "Lucida Console")
           GUICtrlSetCursor ($Button1, 0)
           GUICtrlSetOnEvent(-1, "Emailspoof")   
    
;--------GUI Input-------
$To =   GUICtrlCreateInput  ("", 10,  75, 100, 20)
        GUICtrlSetTip(-1,"Put victim's Email here.")
$From = GUICtrlCreateInput ( "", 145,  75, 100, 20)
        GUICtrlSetTip(-1,"Put Spoof Email here.")
$Subject = GUICtrlCreateInput  ("", 10, 120, 100, 20)
        GUICtrlSetTip(-1,"Subject of Email goes here.")
        
$msg = GUICtrlCreateEdit ("", 10,165,235,200,$ES_AUTOVSCROLL+$WS_VSCROLL)

$SMTPList = GUICtrlCreateCombo ("", 10, 390,200,$CBS_DROPDOWNLIST )
GUICtrlSetData(-1, $T_STR, $ARRAY[1][1]); add other items



;Handling the GUI
While 1
    $msg = GUIGetMsg()
    Select
        Case $msg = $GUI_EVENT_CLOSE;Exit form GUI
            Exitloop
        Case $msg = $Button1
            Emailspoof()
        Case Else
       ; Something else
    EndSelect
Wend

Exit

;---------Func's---------------
func Special()
   
EndFunc


Func Emailspoof()
$s_SmtpServer = GUICtrlRead($SMTPList)
$s_FromName = GUICtrlRead($From)
$s_FromAddress = GUICtrlRead($From)
$s_ToAddress = GUICtrlRead($To)
$s_Subject = GUICtrlRead($Subject)
$as_Body = GUICtrlRead($msg)

$Response = _INetSmtpMail ($s_SmtpServer, $s_FromName, $s_FromAddress, $s_ToAddress, $s_Subject, $as_Body)
    EndFunc

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  

×