Exemplo n.º 1
0
        public override IntPtr Inject(PortableExecutable dll, IntPtr hProcess)
        {
            //same as above, write the temp file and defer to the other Inject methods.
            ClearErrors();
            string path    = Utils.WriteTempData(dll.ToArray());
            IntPtr hModule = IntPtr.Zero;

            if (!string.IsNullOrEmpty(path))
            {
                hModule = Inject(path, hProcess);
                try
                {
                    System.IO.File.Delete(path);
                }
                catch { /* nom nom nom */ }
            }
            return(hModule);
        }
Exemplo n.º 2
0
        // Token: 0x0600010B RID: 267 RVA: 0x0000CA2C File Offset: 0x0000AC2C
        public override IntPtr Inject(PortableExecutable dll, IntPtr hProcess)
        {
            this.ClearErrors();
            string text   = Utils.WriteTempData(dll.ToArray());
            IntPtr result = IntPtr.Zero;

            if (!string.IsNullOrEmpty(text))
            {
                result = this.Inject(text, hProcess);
                try
                {
                    File.Delete(text);
                }
                catch
                {
                }
            }
            return(result);
        }