[PROGRAM] 0123 Encoder/Decoder - blow_fly98 - 10-01-2009
OK, so you want to change the copyright info in 2.0???
Don't get how the 0123 encoding/decoding works???
I made a program to help you.
>>Download here<<
NOT LIKELY TO BE UPDATED!!!
Credits to Silva for the table of characters!!!
Declarations:
VBNET-Code:
Shared Table() As Char = New Char() {" "c, "!"c, """"c, "#"c, "$"c, "%"c, "&"c, "'"c, "("c, ")"c, "*"c, "+"c, ","c, "-"c, "."c, "/"c, "0"c, "1"c, "2"c, "3"c, "4"c, "5"c, "6"c, "7"c, "8"c, "9"c, ":"c, ";"c, "<"c, "="c, ">"c, "?"c, "@"c, "A"c, "B"c, "C"c, "D"c, "E"c, "F"c, "G"c, "H"c, "I"c, "J"c, "K"c, "L"c, "M"c, "N"c, "O"c, "P"c, "Q"c, "R"c, "S"c, "T"c, "U"c, "V"c, "W"c, "X"c, "Y"c, "Z"c, "["c, "\"c, "]"c, "^"c, "_"c, "`"c, "a"c, "b"c, "c"c, "d"c, "e"c, "f"c, "g"c, "h"c, "i"c, "j"c, "k"c, "l"c, "m"c, "n"c, "o"c, "p"c, "q"c, "r"c, "s"c, "t"c, "u"c, "v"c, "w"c, "x"c, "y"c, "z"c, "{"c, "|"c, "}"c, "~"}
Shared Trim() As String = New String() {Environment.NewLine, vbCrLf, vbCr, vbLf}
|
Encoding:
VBNET-Code:
Shared Function Encode0123(ByVal Contents As String) As String
Dim Result As String = ""
Dim NewLineCount As Integer = -1
Dim Lines() As String = Contents.Split(Environment.NewLine)
Try
For i2 As Integer = 0 To Lines.Length - 1
NewLineCount += 1
If NewLineCount > 0 Then
Result &= Environment.NewLine
End If
Dim LineBuffer As String = Lines(i2)
For Each s As String In Trim
LineBuffer = LineBuffer.Trim(s)
Next
For i3 As Integer = 0 To LineBuffer.Length - 1
Dim c As Char = LineBuffer(i3)
If (Not c = Environment.NewLine) AndAlso (Array.IndexOf(Table, c) >= 0) Then
Dim i As Integer = Array.IndexOf(Table, c)
i = (i + (i3 Mod 4)) Mod (Table.Length)
Result &= Table(i)
End If
Next
Next
Catch ex As Exception
MessageBox.Show("Invalid decrypted string!!!", "Invalid String", MessageBoxButtons.OK)
End Try
Return Result
End Function
|
Decoding:
VBNET-Code:
Shared Function Decode0123(ByVal Contents As String) As String
Dim Result As String = ""
Dim NewLineCount As Integer = -1
Dim Lines() As String = Contents.Split(Environment.NewLine)
Try
For i2 As Integer = 0 To Lines.Length - 1
NewLineCount += 1
If NewLineCount > 0 Then
Result &= Environment.NewLine
End If
Dim LineBuffer As String = Lines(i2)
For Each s As String In Trim
LineBuffer = LineBuffer.Trim(s)
Next
For i3 As Integer = 0 To LineBuffer.Length - 1
Dim c As Char = LineBuffer(i3)
If (Not c = Environment.NewLine) AndAlso (Array.IndexOf(Table, c) >= 0) Then
Dim i As Integer = Array.IndexOf(Table, c)
Dim k As Integer = i3 Mod 4
i -= k
i = i Mod (Table.Length)
Do While i < 0
i += (Table.Length)
Loop
Result &= Table(i)
End If
Next
Next
Catch ex As Exception
MessageBox.Show("Invalid encrypted string!!!", "Invalid String", MessageBoxButtons.OK)
End Try
Return Result
End Function
|
RE: [PROGRAM] 0123 Encoder/Decoder - Yinseko - 10-01-2009
good program)
before i use LF2 ultimate patcher on LF2 v.1.9c for get encoded version of copyright.
now it'll easier ^__^
RE: [PROGRAM] 0123 Encoder/Decoder - RenanDez - 10-02-2009
Good
RE: [PROGRAM] 0123 Encoder/Decoder - rikumaster - 10-03-2009
good job , just need the links to change now
RE: [PROGRAM] 0123 Encoder/Decoder - MH-Razen - 12-21-2009
congrats, just submitted this tool to EXE Editing Pack:
http://www.lf-empire.de/lfev9/en/lf2-empire/exe-editing/programs
|