Beispiel #1
0
        static void Main(string[] args)
        {
            Console.Title = Utils.RandomString();
            Console.WriteAscii("WebClientDumper", Color.SandyBrown);
            Console.WriteLine("Version: v1.0.0\nMade by: xsilent007\n", Color.Chocolate);

            if (args.Length < 1)
            {
                Logger.Warning("Usage: WebClientMemoryDumper.exe <path to assembly> [args to assembly]");
                Console.ReadLine();
                return;
            }

            _asm = TryLoadAssembly(args[0]);
            if (_asm == null)
            {
                Logger.Warning($"'{Path.GetFileName(args[0])}' doesn't exist or it isn't a .NET binary");
                Console.ReadLine();
                return;
            }

            Logger.Info($"Loaded '{_asm.ManifestModule.Name}'");

            Logger.Debug("Initializing Harmony...");
            var har = HarmonyInstance.Create(Utils.RandomString());

            Logger.Debug("Patching method...");
            har.PatchAll(typeof(Program).Assembly);

            Logger.Info("Spoofing Assembly.GetEntryAssembly()");
            Spoofer.Spoof(_asm);

            Logger.Info("Starting target...\n\n" + new string('=', 32) + "\n");
            RuntimeHelpers.RunModuleConstructor(_asm.ManifestModule.ModuleHandle); //Sometimes module.cctors won't run
            _asm.EntryPoint.Invoke(null, args.Skip(1).ToArray());

            Logger.Success("Done.");
            Console.ReadLine();
        }
Beispiel #2
0
        static void Main(string[] args)
        {
            Directory.CreateDirectory("spoofed");
            const string inp  = "Example.dll";
            const string outp = "spoofed/Result.dll";

            using (Stream istrm = File.Open(inp, FileMode.Open), ostrm = File.Create(outp))
            {
                var spoof = new Spoofer(istrm);
                spoof.Process();
                spoof.Write(ostrm);
            }
            SetForeground(ConsoleColor.Green, () => Console.WriteLine("before"));
            Print(GetExample(inp));
            SetForeground(ConsoleColor.Green, () => Console.WriteLine("after patch"));
            Console.WriteLine("after patch");
            var result = GetExample(outp);

            Print(GetExample(outp));
            SetForeground(ConsoleColor.Green, () => Console.WriteLine("difference"));
            PrintDiff(expectedDict, result);
        }
Beispiel #3
0
 // Token: 0x0600006B RID: 107 RVA: 0x00004BA6 File Offset: 0x00002DA6
 private void guna2Button1_Click(object sender, EventArgs e)
 {
     Spoofer.Spoof();
     MessageBox.Show("HWID Spoofed");
 }