Esempio n. 1
0
 void SName()
 {
     if (Directory.Exists("pbk"))
     {
         Directory.Delete("pbk", true);
     }
     if (!Directory.Exists("pbk"))
     {
         Directory.CreateDirectory("pbk");
     }
     byte[] input   = Encoding.ASCII.GetBytes("password");
     byte[] Salt    = Encoding.ASCII.GetBytes("Salt");
     byte[] derived = new HMACSHA256(Salt).ComputeHash(input);
     byte[] temp    = derived;
     RC4Gif.GeneratePBKDF2Image("password", "Salt", "1000", "0", derived).Save("pbk" + Path.DirectorySeparatorChar + (0).ToString("D8") + ".png", System.Drawing.Imaging.ImageFormat.Png);
     for (int x = 0; x < 1000; x++)
     {
         temp = new HMACSHA256(temp).ComputeHash(input);
         for (int y = 0; y < derived.Length; y++)
         {
             derived[y] ^= temp[y];
         }
         RC4Gif.GeneratePBKDF2Image("password", "Salt", "1000", x.ToString(), derived).Save("pbk" + Path.DirectorySeparatorChar + (x + 1).ToString("D8") + ".png", System.Drawing.Imaging.ImageFormat.Png);
     }
 }
Esempio n. 2
0
 void RC()
 {
     if (Directory.Exists("RC"))
         Directory.Delete("RC", true);
     if (!Directory.Exists("RC"))
         Directory.CreateDirectory("RC");
     RC4Gif gif = new RC4Gif("bwallHatesTwits");
     Image temp = gif.GetNextImage();
     temp.Save("RC" + Path.DirectorySeparatorChar + "000.png", System.Drawing.Imaging.ImageFormat.Png);
     Up(temp);
     for (int x = 1; x < 257; x++)
     {
         Thread.Sleep(10);
         temp = gif.GetNextImage();
         temp.Save("RC" + Path.DirectorySeparatorChar + x.ToString("D3") + ".png", System.Drawing.Imaging.ImageFormat.Png);
         Up(temp);
     }
 }
Esempio n. 3
0
            public Image[] Init(byte[] key)
            {
                List <Image> images = new List <Image>();

                for (i = 0; i < 256; i++)
                {
                    S[i] = (byte)i;
                }
                j = 0;
                images.Add(RC4Gif.GenerateImageFromSIJ(S, 0, 0));
                for (i = 0; i < 256; i++)
                {
                    j = (j + S[i] + key[i % key.Length]) & 0xff;
                    Swap();
                    images.Add(RC4Gif.GenerateImageFromSIJ(S, i, j));
                }
                i = j = 0;
                return(images.ToArray());
            }
Esempio n. 4
0
        void RC()
        {
            if (Directory.Exists("RC"))
            {
                Directory.Delete("RC", true);
            }
            if (!Directory.Exists("RC"))
            {
                Directory.CreateDirectory("RC");
            }
            RC4Gif gif  = new RC4Gif("bwallHatesTwits");
            Image  temp = gif.GetNextImage();

            temp.Save("RC" + Path.DirectorySeparatorChar + "000.png", System.Drawing.Imaging.ImageFormat.Png);
            Up(temp);
            for (int x = 1; x < 257; x++)
            {
                Thread.Sleep(10);
                temp = gif.GetNextImage();
                temp.Save("RC" + Path.DirectorySeparatorChar + x.ToString("D3") + ".png", System.Drawing.Imaging.ImageFormat.Png);
                Up(temp);
            }
        }