New crypto R63+ C#

Page 1 of 6 123456 LastLast
Results 1 to 15 of 89
  1. #1
    Account Upgraded | Title Enabled! =dj.matias= is offline
    MemberRank
    Apr 2008 Join Date
    FinlandLocation
    381Posts

    New crypto R63+ C#

    I've found new crypto files. I've tested it -> Working. This code need editing etc.

    Crypto.cs

    Code:
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    
    namespace Packetlogger_Varoke
    {
        class HabboEncoders
        {
            // New Habbo Encoding by Itachi // Thanks to LittleJ
            // Called 'charEncode', nice name, no?
            // Include a easy CryptoClientMessage, enjoy!
    
            #region Habbo new Crypto: 'char Encode' by Itachi
            string Data;
            int Header;
            int Lenght;
            public string[] ExtraDatas;
            int e1 = 0;
            int e2 = 0;
            internal HabboEncoders(string InternalData)
            {
                Data = InternalData;
                string conn = Data.ToString();
                conn = conn.Replace("{char0}", Convert.ToChar(0).ToString());
                conn = conn.Replace("{char1}", Convert.ToChar(1).ToString());
                conn = conn.Replace("{char2}", Convert.ToChar(2).ToString());
                conn = conn.Replace("{char13}", Convert.ToChar(13).ToString());
                string final = "";
                foreach (char C in conn)
                {
                    string zC = "{char" + (int)C + "}";
                    final += zC;
                }
                final = final.Replace("{char", "");
                final = final.Substring(0, final.Length - 1);
                final = final.Replace("}", ";");
                string[] ToSepare = final.Split(';');
                int sLenght = HabboCrypto.DecodeBit8(InternalData.Substring(2, 2));
                int sHeader = HabboCrypto.DecodeBit8(InternalData.Substring(4, 2));
                string Extra = "";
                for (int i = 6; i != ToSepare.Length; i++)
                {
                    string s = Convert.ToChar(int.Parse(ToSepare[i])).ToString();
                    string Fs = "";
                    if (ToSepare.Length > i + 1)
                        Fs = Convert.ToChar(int.Parse(ToSepare[i + 1])).ToString();
                    if (GeneralSystem.IsValidName(s))
                    {
                        Extra += Convert.ToChar(int.Parse(ToSepare[i]));
                        if (!GeneralSystem.IsValidName(Fs))
                            Extra += ";";
                    }
                    else
                        Extra += ToSepare[i] + ";";
    
                }
                Header = sHeader;
                Lenght = sLenght;
                ExtraDatas = Extra.Split(';');
            }
    
            internal int CharEncode_GetHeader()
            {
                return Header;
            }
    
            internal int CharEncode_GetLenght()
            {
                return Lenght;
            }
    
            internal string CharEncode_GetNextString()
            {
                while (true)
                {
                    if (ExtraDatas.Length < e1)
                        return null;
    
                    if (GeneralSystem.IsValidString(ExtraDatas[e1]))
                        return ExtraDatas[e1];
                    else
                        e1++;
                }
            }
    
            internal int CharEncode_GetNextInt()
            {
                while (true)
                {
                    if (ExtraDatas.Length < e1)
                        return -1;
    
                    if (GeneralSystem.IsValidInt(ExtraDatas[e1]))
                        return int.Parse(ExtraDatas[e1]);
                    else
                        e1++;
                }
            }
        }
            #endregion
    }
    HabboCrypto.cs

    Code:
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    
    namespace Packetlogger_Varoke
    {
        class HabboCrypto
        {
            public static string EncodeBit32(string v)
            {
                return EncodeBit32(v.Length);
            }
    
            public static string EncodeBit32(int v) // int
            {
                string t = "";
                t += (char)0; // 4 bytes
                t += (char)((v >> 24) & 0xFF); // 3 bytes
                t += (char)((v >> 16) & 0xFF); // 2 bytes
                t += (char)((v >> 8) & 0xFF); // 1 byte
                t += (char)((v) & 0xFF);
                return t;
            }
    
            public static int DecodeBit24(string v)
            {
                if ((v[0] | v[1] | v[2] | v[3]) < 0)
                    return -1;
                return ((v[0] << 24) + (v[1] << 16) + (v[2] << 8) + (v[3] << 0));
            }
    
            public static int DecodeBit8(string v)
            {
                if ((v[0] | v[1]) < 0)
                    return -1;
                return ((v[0] << 8) + (v[1] << 0));
            }
        }
    }
    ClientMessage.cs

    Code:
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    
    namespace Packetlogger_Varoke
    {
        static class HabboEncoding
        {
            public static string cypherShort(int v) // str len, packet len, packet header -- b64
            {
                string t = "";
                t += (char)((v >> 8) & 0xFF);
                t += (char)((v >> 0) & 0xFF);
                return t;
            }
    
            public static string cypherInt(int v)
            {
                string t = "";
                t += (char)((v >> 24) & 0xFF);
                t += (char)((v >> 16) & 0xFF);
                t += (char)((v >> 8) & 0xFF);
                t += (char)((v >> 0) & 0xFF);
                return t;
            }
    
            public static int DecodeBit24(string v)
            {
                if ((v[0] | v[1] | v[2] | v[3]) < 0)
                    return -1;
                return ((v[0] << 24) + (v[1] << 16) + (v[2] << 8) + (v[3] << 0));
            }
    
            public static int DecodeBit8(string v)
            {
                if ((v[0] | v[1]) < 0)
                    return -1;
                return ((v[0] << 8) + (v[1] << 0));
            }
    
        }
    
        public class SClientMessage
        {
            public String oString;
            private String oData;
            public SClientMessage(string Data)
            {
                oString = Data;
                oData = oString.Substring(6);
            }
    
            public int Lenght()
            {
                return HabboEncoding.DecodeBit8(oString.Substring(2, 4));
            }
    
            public int Header()
            {
                return HabboEncoding.DecodeBit8(oString.Substring(4, 6));
            }
    
            public int GetNextInt()
            {
                int result = HabboEncoding.DecodeBit24(oData.Substring(0, 4));
                oData = oData.Substring(4);
    
                return result;
            }
    
            public String GetNextString()
            {
                int len = HabboEncoding.DecodeBit8(oData.Substring(0, 2));
                oData = oData.Substring(2);
    
                String Result = oData.Substring(0, len);
                oData = oData.Substring(len);
    
                return Result;
            }
        }
    
        class ClientMessage
        {
            public String oString;
            public String oData;
    
            public ClientMessage(string Data)
            {
                oData = Data.Substring(4);
            }
            public int Header()
            {
                int Header = HabboCrypto.DecodeBit8(oData.Substring(0, 2));
                oData = oData.Substring(2);
                return Header;
            }
    
            public bool CanGetNextString()
            {
                try
                {
                    int len = HabboCrypto.DecodeBit8(oData.Substring(0, 2));
                    if (len > 0)
                    {
                        String Result = oData.Substring(0, len);
                        if (Result != "")
                            return true;
                        else
                            return false;
                    }
                    else
                        return false;
                }
                catch
                {
                    return false;
                }
            }
    
            public int NewNextInt()
            {
                int result = HabboCrypto.DecodeBit24(oData.Substring(1, 4));
                return result;
            }
    
            public int GetNextInt()
            {
                int result = HabboCrypto.DecodeBit24(oData.Substring(0, 4));
                oData = oData.Substring(4);
    
                return result;
            }
    
            public String GetNextString()
            {
                int len = HabboCrypto.DecodeBit8(oData.Substring(0, 2));
                oData = oData.Substring(2);
    
                String Result = oData.Substring(0, len);
                oData = oData.Substring(len);
    
                return Result;
            }
        }
    }
    System.cs

    Code:
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    
    namespace Packetlogger_Varoke
    {
        class GeneralSystem
        {
            public static bool IsValidString(string inputStr)
            {
                if (string.IsNullOrEmpty(inputStr))
                {
                    return false;
                }
    
                for (int i = 0; i < inputStr.Length; i++)
                {
                    string s = inputStr[i].ToString();
                    if (s == "." || s == "," || s == ";" || s == ":" || s == "<" || s == ">" || s == "@" || s == @"\" || s == "/")
                    {
                        return true;
                    }
                    else if (!(IsLetter(s)))
                    {
                        return false;
                    }
                }
    
                return true;
            }
    
            public static bool IsValidInt(string inputStr)
            {
                if (string.IsNullOrEmpty(inputStr))
                {
                    return false;
                }
    
                for (int i = 0; i < inputStr.Length; i++)
                {
                    string s = inputStr[i].ToString();
                    if (!(char.IsNumber(inputStr[i])))
                    {
                        return false;
                    }
                }
    
                return true;
            }
    
    
            public static bool IsValidName(string inputStr)
            {
                if (string.IsNullOrEmpty(inputStr))
                {
                    return false;
                }
    
                for (int i = 0; i < inputStr.Length; i++)
                {
                    string s = inputStr[i].ToString();
                    if (s == "." || s == "," || s == ";" || s == ":" || s == "<" || s == ">" || s == "@" || s == @"\" || s == "/" || s == "#")
                    {
                        return true;
                    }
                    else if (!(IsLetter(s)) && !(char.IsNumber(inputStr[i])))
                    {
                        return false;
                    }
                }
    
                return true;
            }
    
            public static bool IsLetter(string s)
            {
                s = s.ToLower();
                if (s == "a" || s == "b" || s == "c" || s == "d" || s == "e" || s == "f" || s == "g"
                     || s == "h" || s == "i" || s == "j" || s == "k" || s == "l" || s == "m" || s == "n" || s == "ñ"
                     || s == "o" || s == "p" || s == "q" || s == "r" || s == "s" || s == "t" || s == "u" || s == "v"
                     || s == "w" || s == "x" || s == "y" || s == "z" || s == "¡" || s == "!" || s == "¿" || s == "?" || s == "á"
                     || s == "é" || s == "í" || s == "ó" || s == "ú" || s == "|" || s == "#" || s == "-" || s == "_" ||
                        s == "[" || s == " " || s == "]")
                    return true;
                else
                    return false;
            }
        }
    }
    Get Packet header Example:

    Code:
    HabboCrypto.DecodeBit8(PACKETDATAHERE.Substring(4, 6));
    Last edited by =dj.matias=; 22-11-11 at 06:31 PM.


  2. #2
    Eye Eye Capt'n Spheral is offline
    MemberRank
    May 2010 Join Date
    TumptonshireLocation
    2,488Posts

    Re: New crypto R63+ C#

    Hope Aaron uses in Phoenix if it works.

  3. #3
    Account Upgraded | Title Enabled! LucasReis is offline
    MemberRank
    Jun 2009 Join Date
    Sorocaba, BraziLocation
    206Posts

    Re: New crypto R63+ C#

    What is this?

  4. #4
    Live Ocottish Sverlord Joopie is offline
    LegendRank
    Jun 2010 Join Date
    The NetherlandsLocation
    2,773Posts

    Re: New crypto R63+ C#

    Quote Originally Posted by LucasReis View Post
    What is this?
    Something what you don't understand

  5. #5
    Account Upgraded | Title Enabled! American is offline
    MemberRank
    Sep 2011 Join Date
    WeedlandLocation
    658Posts

    Re: New crypto R63+ C#

    Thanks =dj.matias=, I'll try code it into my emu.

    well i can't.

    http://www.images.scottbekmezci.com/icantcode.png

    If Aaron don't code it, guys....
    i recommend you all don't buy phoenix ^_^
    cuz Aaron will be really noooob.
    Last edited by American; 22-11-11 at 07:47 PM.

  6. #6
    this is title Shredinator is offline
    MemberRank
    May 2011 Join Date
    399Posts

    Re: New crypto R63+ C#

    Already had another version of the same thing, pretty interesting to see another shot at it, though. Thanks.

  7. #7
    Account Upgraded | Title Enabled! George2000 is offline
    MemberRank
    Jul 2011 Join Date
    The NetherlandsLocation
    1,150Posts

    Re: New crypto R63+ C#

    Thanks, you made my day <3

  8. #8
    Garry's Mod is addictive! Law is offline
    MemberRank
    Dec 2009 Join Date
    NorwayLocation
    993Posts

    Re: New crypto R63+ C#

    Quote Originally Posted by George2000 View Post
    Thanks, you made my day <3
    Cause you couldn't do it yourself?

  9. #9
    Web Developer Papercup is offline
    MemberRank
    Nov 2009 Join Date
    WalesLocation
    1,607Posts

    Re: New crypto R63+ C#

    This is nice.

  10. #10
    Account Upgraded | Title Enabled! George2000 is offline
    MemberRank
    Jul 2011 Join Date
    The NetherlandsLocation
    1,150Posts

    Re: New crypto R63+ C#

    Quote Originally Posted by Law View Post
    Cause you couldn't do it yourself?
    Cause I couldn't figure it out.

  11. #11
    Account Upgraded | Title Enabled! =dj.matias= is offline
    MemberRank
    Apr 2008 Join Date
    FinlandLocation
    381Posts

    Re: New crypto R63+ C#

    This code need editing. I've got it client to server headers decode.

  12. #12
    C# | C++ Emerica is offline
    MemberRank
    Oct 2010 Join Date
    GermanyLocation
    437Posts

    Re: New crypto R63+ C#

    Quote Originally Posted by JohnHearfield View Post
    Hope Aaron uses in Phoenix if it works.
    I don't hope so...
    did you test it ?

    Quote Originally Posted by American View Post
    Thanks =dj.matias=, I'll try code it into my emu.

    well i can't.

    http://www.images.scottbekmezci.com/icantcode.png

    If Aaron don't code it, guys....
    i recommend you all don't buy phoenix ^_^
    cuz Aaron will be really noooob.
    Maybe because you didn't change the namespace ?

  13. #13
    Account Upgraded | Title Enabled! American is offline
    MemberRank
    Sep 2011 Join Date
    WeedlandLocation
    658Posts

    Re: New crypto R63+ C#

    Quote Originally Posted by Emerica View Post
    I don't hope so...
    did you test it ?



    Maybe because you didn't change the namespace ?
    I changed.

  14. #14
    C# | C++ Emerica is offline
    MemberRank
    Oct 2010 Join Date
    GermanyLocation
    437Posts

    Re: New crypto R63+ C#

    Need the Login Packets and a little 'tut' how to Use :D

  15. #15
    ส็็็็็็็ Bloodraven is offline
    MemberRank
    Sep 2009 Join Date
    AntarcticaLocation
    2,414Posts

    Re: New crypto R63+ C#

    Thanks.



Page 1 of 6 123456 LastLast

Advertisement