Exemplo n.º 1
0
        public static void ResolveImports()
        {
            var hModule = Win32Imports.LoadLibrary(Directories.BootstrapFilePath);
            if (!(hModule != IntPtr.Zero))
            {
                return;
            }

            var procAddress = Win32Imports.GetProcAddress(hModule, "ModifyIAT");
            if (!(procAddress != IntPtr.Zero))
            {
                return;
            }

            ModifyIAT = Marshal.GetDelegateForFunctionPointer(procAddress, typeof(ModifyIATDelegate)) as ModifyIATDelegate;
        }
Exemplo n.º 2
0
        public static void ResolveImports()
        {
            var hModule = Win32Imports.LoadLibrary(Directories.BootstrapFilePath);

            if (!(hModule != IntPtr.Zero))
            {
                return;
            }

            var procAddress = Win32Imports.GetProcAddress(hModule, "ModifyIAT");

            if (!(procAddress != IntPtr.Zero))
            {
                return;
            }

            ModifyIAT = Marshal.GetDelegateForFunctionPointer(procAddress, typeof(ModifyIATDelegate)) as ModifyIATDelegate;
        }