Support Forums
How to add EOF support to your crypter! - Printable Version

+- Support Forums (https://www.supportforums.net)
+-- Forum: Categories (https://www.supportforums.net/forumdisplay.php?fid=87)
+--- Forum: Coding Support Forums (https://www.supportforums.net/forumdisplay.php?fid=18)
+---- Forum: Visual Basic and the .NET Framework (https://www.supportforums.net/forumdisplay.php?fid=19)
+---- Thread: How to add EOF support to your crypter! (/showthread.php?tid=5562)



How to add EOF support to your crypter! - ♱ RedTube ♱ - 04-05-2010

Have you got a crypter, and want to add EOF?

Well, I'm gonna tell you how.

Add this code to your BUILDER:

Code:
Public Function ReadEOFData(ByRef FilePath As String) As String
        On Error GoTo Err_Renamed
        Dim sEOFBuf, sFileBuf, sChar As String
        Dim lPos2, lFF, lPos, lCount As Integer
        If Dir(FilePath) = "" Then GoTo Err_Renamed
        lFF = FreeFile()
        FileOpen(lFF, FilePath, OpenMode.Binary)
        sFileBuf = Space(LOF(lFF))
        FileGet(lFF, sFileBuf)
        FileClose(lFF)
        lPos = InStr(1, StrReverse(sFileBuf), GetNullBytes(30))
        sEOFBuf = (Mid(StrReverse(sFileBuf), 1, lPos - 1))
        ReadEOFData = StrReverse(sEOFBuf)
        If ReadEOFData = "" Then
        End If
        Exit Function
Err_Renamed:
        ReadEOFData = vbNullString
    End Function

    Sub WriteEOFData(ByRef FilePath As String, ByRef EOFData As String)
        Dim sFileBuf As String
        Dim lFF As Integer
        On Error Resume Next
        If Dir(FilePath) = "" Then Exit Sub
        lFF = FreeFile()
        FileOpen(lFF, FilePath, OpenMode.Binary)
        sFileBuf = Space(LOF(lFF))
        FileGet(lFF, sFileBuf)
        FileClose(lFF)
        Kill(FilePath)
        lFF = FreeFile()
        FileOpen(lFF, FilePath, OpenMode.Binary)
        FilePut(lFF, sFileBuf & EOFData)
        FileClose(lFF)
    End Sub

    Public Function GetNullBytes(ByRef lNum As Object) As String
        Dim sBuf As String
        Dim i As Short
        For i = 1 To lNum
            sBuf = sBuf & Chr(0)
        Next
        GetNullBytes = sBuf
    End Function

Add a new Textbox, and make it so it's not visible.
Add a Checkbox.

Now, add this after the FileClose(1).

You should change the TextBox4.Text to the TextBox ID you just added.
You should change the CheckBox1 to the CheckBox ID you just added.

NOTE: This code MUST go after the FileClose(1)

Code:
TextBox4.Text = ReadEOFData(TextFile.Text)

        If CheckBox1.Checked = True Then
            ReadEOFData(TextFile.Text)
            WriteEOFData(output, TextBox4.Text)
        End If

Credits: xKillerxPanther (For the EOF code)


RE: How to add EOF support to your crypter! - S1cKL3R - 04-05-2010

I haven't tried it, but I trust you're TUT works. Great job man!


RE: How to add EOF support to your crypter! - August - 04-05-2010

Very nice tut will come in handy for newbies who wanna make a cypter, thanks !! Big Grin


RE: How to add EOF support to your crypter! - ♱ RedTube ♱ - 04-05-2010

(04-05-2010, 06:50 PM)S1cKL3R Wrote: I haven't tried it, but I trust you're TUT works. Great job man!
Yes, it works.

I use it on my crypter. Smile

Thanks.


RE: How to add EOF support to your crypter! - «Ðartz™» - 04-05-2010

Hmm, thanks. I needed this for the crypter I plan on making, as I know some things don't crypt without EOF.

Thanks. Rep+'ed.


RE: How to add EOF support to your crypter! - ♱ RedTube ♱ - 04-05-2010

(04-05-2010, 06:51 PM)«Ðartz™» Wrote: Hmm, thanks. I needed this for the crypter I plan on making, as I know some things don't crypt without EOF.

Thanks. Rep+'ed.
You're welcome, and thanks. Smile


RE: How to add EOF support to your crypter! - Kaleb - 04-05-2010

Thank you, will most likely use.


RE: How to add EOF support to your crypter! - Jordan L. - 04-06-2010

This belongs on HF.