Module TinyActionScripter 'By: Fredrik Nordberg Almroth 'URL: http://h.ackack.net/ 'Note: Rough and dirty! Wont work on all scripts. ' Haven't really looked into it, extend it if you wish. '========================= '> javascript:alert('Yo.') '< Added successfully. '# Alright, creating the SWF, 634080079022420469.swf '~ javascript:alert('Yo.') '# Done! '========================= Private Const getURL As Byte = &H83 Private Const FlashVersion As Byte = &H6 Private Const NULL As Byte = &H0 Sub Main() Console.Write("> ") Dim URL As String = Console.ReadLine If URL.Length <= &HFD And URL.Length > &H0 Then Console.WriteLine("< Added successfully.") Else Console.WriteLine("< Unable to add requested URL.") End End If Console.Write("# Alright, creating the SWF, ") Dim Filename As String = String.Concat(Date.Now.Ticks, ".swf") Console.WriteLine(Filename) Dim Stream As New IO.FileStream(Filename, IO.FileMode.Create, IO.FileAccess.Write) Dim Output As New IO.BinaryWriter(Stream, System.Text.Encoding.ASCII) With Output For Each Content As Byte In New Byte() {&H46, &H57, &H53, FlashVersion, _ &H41, &H0, &H0, &H0, &H78, &H0, &H5, &H5F, &H0, &H0, &HF, &HA0, &H0, &H0, _ &HC, &H1, &H0, &H43, &H2, &HFF, &HFF, &HFF, &H3F, &H3, &H1D, &H0, &H0, &H0} .Write(Content) Next Console.Write("~ ") Try Dim Length As Byte = &H2 + CByte(URL.Length) .Write(CByte(getURL)) .Write(Length) .Write(NULL) For Each Letter As Char In URL If Asc(Letter) > NULL Then Console.Write(Letter) .Write(CByte(Asc(Letter))) End If Next Console.WriteLine() .Write(NULL) .Write(NULL) Catch Console.WriteLine("! Unable to write URL: " & URL) End Try For Each Content As Byte In New Byte() {&H0, &H40, &H0, &H0, &H0} .Write(Content) Next .Flush() .Close() End With Console.WriteLine("# Done!") End Sub End Module