[C#]qCrypt - Open Source Encryption

Page 1 of 2 12 LastLast
Results 1 to 15 of 22
  1. #1
    Account Upgraded | Title Enabled! Intelext is offline
    MemberRank
    Mar 2007 Join Date
    EuropeLocation
    1,228Posts

    [C#]qCrypt - Open Source Encryption

    qCrypt - One side encryption. It's kinda hard to decrypt it. Although if used small amount of letters it's not so hard. Very basic encryption. Feel free to modify/improve it and upload of course so everyone can see.

    Screenshot: http://img337.imageshack.us/img337/4745/66454548.png
    Download: http://yy.lv/download.php?f=69738

    Example:
    I love RaGEZONE -> 67937422414128769424316766586502
    I iove RaGEZONE -> 43694397774867024729779803447143

    Main Form
    PHP Code:
    namespace qCrypt
    {
        public 
    partial class frmMainForm Form
        
    {
            public 
    frmMainForm()
            {
                
    InitializeComponent();
            }

            private 
    void buttonEncrypt_Click(object senderEventArgs e)
            {
                
    Encrypt.StartEncryption(textBoxUncrypted.Text);
                
    textBoxEncrypted.Text Encrypt.ReturnString();
            }
        }

    Encrypt
    PHP Code:
    namespace qCrypt.Classes
    {
        static class 
    Encrypt
        
    {
            static 
    string FinalIntegers;
            static 
    string EncryptText;
            static 
    int[] MyIntArray = new int[32];

            public static 
    void StartEncryption(string MyText)
            {
                
    //Uppering it just in case.
                
    MyText MyText.ToUpper();

                
    //Making these strings empty.
                
    FinalIntegers string.Empty;
                
    EncryptText string.Empty;

                
    //Main loop where checking each letter.
                
    for (int i 0MyText.Lengthi++)
                {
                    if (
    MyText[i] == 'A')
                    {
                        
    EncryptText "67147804386935659614295334925265";
                    }

                    if (
    MyText[i] == 'B')
                    {
                        
    EncryptText "40234261117512095921888831693698";
                    }

                    if (
    MyText[i] == 'C')
                    {
                        
    EncryptText "25554594088772765822059033491034";
                    }

                    if (
    MyText[i] == 'D')
                    {
                        
    EncryptText "49257666344761728762503183692300";
                    }

                    if (
    MyText[i] == 'E')
                    {
                        
    EncryptText "92345676992698286431550173278515";
                    }

                    if (
    MyText[i] == 'F')
                    {
                        
    EncryptText "93726526035464017048882091246568";
                    }

                    if (
    MyText[i] == 'G')
                    {
                        
    EncryptText "24590313462079242595407758509550";
                    }

                    if (
    MyText[i] == 'H')
                    {
                        
    EncryptText "83759930172522751880516343255280";
                    }

                    if (
    MyText[i] == 'I')
                    {
                        
    EncryptText "90291595376905753003909888385940";
                    }

                    if (
    MyText[i] == 'K')
                    {
                        
    EncryptText "37127880863226049166796151709548";
                    }

                    if (
    MyText[i] == 'L')
                    {
                        
    EncryptText "71461042420384157122852407900801";
                    }

                    if (
    MyText[i] == 'M')
                    {
                        
    EncryptText "58006678924036605768805688980313";
                    }

                    if (
    MyText[i] == 'N')
                    {
                        
    EncryptText "12447122735386729167866363617985";
                    }

                    if (
    MyText[i] == 'O')
                    {
                        
    EncryptText "36141394090474783907420403818251";
                    }

                    if (
    MyText[i] == 'P')
                    {
                        
    EncryptText "99248304649302231675368493493475";
                    }

                    if (
    MyText[i] == 'Q')
                    {
                        
    EncryptText "40735018298008298730725431001991";
                    }

                    if (
    MyText[i] == 'R')
                    {
                        
    EncryptText "81629254782078072283690311362428";
                    }

                    if (
    MyText[i] == 'S')
                    {
                        
    EncryptText "11484931118782297739315078625300";
                    }

                    if (
    MyText[i] == 'T')
                    {
                        
    EncryptText "80642658828236815024324663471131";
                    }

                    if (
    MyText[i] == 'V')
                    {
                        
    EncryptText "98185113022618718347727108401890";
                    }

                    if (
    MyText[i] == 'W')
                    {
                        
    EncryptText "64055954743088822242668717475581";
                    }

                    if (
    MyText[i] == 'X')
                    {
                        
    EncryptText "34011518510939004400504471925399";
                    }

                    if (
    MyText[i] == 'Y')
                    {
                        
    EncryptText "34044922747088848241238723934011";
                    }

                    if (
    MyText[i] == 'Z')
                    {
                        
    EncryptText "34084952747088846202261871934781";
                    }

                    for (
    int n 032n++)
                    {
                        
    //Adding.
                        
    MyIntArray[n] = MyIntArray[n] + Convert.ToInt32(EncryptText[n]);

                        
    //Checking if the value is more than 10.
                        
    while (MyIntArray[n] > 9)
                        {
                            
    MyIntArray[n] = MyIntArray[n] - 10;
                        }
                    }
                }

                
    //Adding everything.
                
    for (int i 032i++)
                {
                    
    FinalIntegers FinalIntegers Convert.ToString(MyIntArray[i]);
                }

                
    //TODO - Add your own sequence here. - TODO//
            
    }

            
    //Returning encrypted text.
            
    public static string ReturnString()
            {
                return 
    FinalIntegers;
            }

        }



  2. #2
    (oO (||||) (||||) Oo) jM2.me is offline
    MemberRank
    Aug 2009 Join Date
    USA (Fuck Yeah)Location
    2,527Posts

    Re: [C#]qCrypt - Open Source Encryption

    It seems really cool to me. Never knew how to make such thing.
    But as I understand from code it will work only for letters.
    And when you try to decrypt text it will be all upper case.

  3. #3
    Account Upgraded | Title Enabled! Intelext is offline
    MemberRank
    Mar 2007 Join Date
    EuropeLocation
    1,228Posts

    Re: [C#]qCrypt - Open Source Encryption

    Quote Originally Posted by ProKiller002 View Post
    It seems really cool to me. Never knew how to make such thing.
    But as I understand from code it will work only for letters.
    And when you try to decrypt text it will be all upper case.

    Well you can improve it so it will work with numbers and stuff. But actually it does work with numbers or any characters as long as it is not first char. It will just simply use the numbers from last letter which exists in the context. Actually I made them uppercase just for checking, it does not matter upper or lower. This program is not case-sensitive so does not matter at all.

  4. #4
    (oO (||||) (||||) Oo) jM2.me is offline
    MemberRank
    Aug 2009 Join Date
    USA (Fuck Yeah)Location
    2,527Posts

    Re: [C#]qCrypt - Open Source Encryption

    Quote Originally Posted by Intelext View Post
    Well you can improve it so it will work with numbers and stuff. But actually it does work with numbers or any characters as long as it is not first char. It will just simply use the numbers from last letter which exists in the context. Actually I made them uppercase just for checking, it does not matter upper or lower. This program is not case-sensitive so does not matter at all.
    Ohh I see. Then I must learn more to understand it better

  5. #5
    Omega Ron is offline
    MemberRank
    Apr 2005 Join Date
    Location
    8,990Posts

    Re: [C#]qCrypt - Open Source Encryption

    Encryption is useless without being able to decrypt it.

  6. #6
    Account Upgraded | Title Enabled! Intelext is offline
    MemberRank
    Mar 2007 Join Date
    EuropeLocation
    1,228Posts

    Re: [C#]qCrypt - Open Source Encryption

    Quote Originally Posted by Ron View Post
    Encryption is useless without being able to decrypt it.
    Now this is just wrong.

    It's not useless, it is used in passwords. When user enters it's password and encrypted password is compared with db password. Like MD5. It's also decryptable as far as I know. You can only guess the password using bruteforce or directory lookup.

  7. #7
    Member SimpleBB is offline
    MemberRank
    Aug 2009 Join Date
    58Posts

    Re: [C#]qCrypt - Open Source Encryption

    Why did you change it to upper?
    You can just do
    Code:
    if(MyText[i] == 'A' || MyText[i] == 'a')
    etc.

    This is more like a hash than an encryption. O_O

  8. #8
    Account Upgraded | Title Enabled! Intelext is offline
    MemberRank
    Mar 2007 Join Date
    EuropeLocation
    1,228Posts

    Re: [C#]qCrypt - Open Source Encryption

    Quote Originally Posted by SimpleBB View Post
    Why did you change it to upper?
    You can just do
    Code:
    if(MyText[i] == 'A' || MyText[i] == 'a')
    etc.

    This is more like a hash than an encryption. O_O
    It's because I want to change every letter in the text. Not just A, or B.

  9. #9
    (oO (||||) (||||) Oo) jM2.me is offline
    MemberRank
    Aug 2009 Join Date
    USA (Fuck Yeah)Location
    2,527Posts

    Re: [C#]qCrypt - Open Source Encryption

    Btw numbers for each letter are completely random right?

  10. #10
    Account Upgraded | Title Enabled! Intelext is offline
    MemberRank
    Mar 2007 Join Date
    EuropeLocation
    1,228Posts

    Re: [C#]qCrypt - Open Source Encryption

    Quote Originally Posted by ProKiller002 View Post
    Btw numbers for each letter are completely random right?
    Yes, no algorithm was made during number creation.

    You can create random numbers for each letter at program start, but then encrypted text will be useless if you restart the application.

  11. #11
    (oO (||||) (||||) Oo) jM2.me is offline
    MemberRank
    Aug 2009 Join Date
    USA (Fuck Yeah)Location
    2,527Posts

    Re: [C#]qCrypt - Open Source Encryption

    I thought about generating random numbers each time but add like 4 characters specifying how numbers were generated or something like that.
    Will that work? And will it be useful?

  12. #12
    Account Upgraded | Title Enabled! Intelext is offline
    MemberRank
    Mar 2007 Join Date
    EuropeLocation
    1,228Posts

    Re: [C#]qCrypt - Open Source Encryption

    Well you need to figure it out by yourself. If you will generate numbers and add 4 to the end.. Well you will need to read only those last 4 if you want encryption to be the same every time. Otherwise it's cool to generate everything randomly each start.

    Try it, then make it better, then try again and make it even more better.

  13. #13
    Ginger by design. jMerliN is offline
    MemberRank
    Feb 2007 Join Date
    2,497Posts

    Re: [C#]qCrypt - Open Source Encryption

    Quote Originally Posted by Intelext View Post
    Now this is just wrong.

    It's not useless, it is used in passwords. When user enters it's password and encrypted password is compared with db password. Like MD5. It's also decryptable as far as I know. You can only guess the password using bruteforce or directory lookup.
    This isn't encryption. It's not 100% reversible but it is incredibly weak, so it's also not suitable for a hash.

    Why don't you get a book on encryption algorithms and read up a bit on some math before you try and make your own encryption algorithm?

  14. #14
    Account Upgraded | Title Enabled! Intelext is offline
    MemberRank
    Mar 2007 Join Date
    EuropeLocation
    1,228Posts

    Re: [C#]qCrypt - Open Source Encryption

    Quote Originally Posted by jMerliN View Post
    Why don't you get a book on encryption algorithms and read up a bit on some math before you try and make your own encryption algorithm?
    I have no point in making one. This was just for fun.

  15. #15
    Mako is insane. ThePhailure772 is offline
    MemberRank
    Sep 2007 Join Date
    1,115Posts

    Re: [C#]qCrypt - Open Source Encryption

    This isn't actually encryption at all. You're just giving a random number for a letter. Example for a BASIC encryption:

    PHP Code:
    public void Encrpyt (ref byte[] bArrayInt32 nIndexInt32 nSize)
    {
       if (
    nSize 0) return;
       for (
    int i nIndexnSize; ++i)
            
    bArray[i] = ~((bArray[i] << 3) | (bArray[i] >> 5)&0xff);

    Like I said, that's veryyyyyyyy basic.



Page 1 of 2 12 LastLast

Advertisement