using System;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: AssemblyVersion("0.0.0.0")]
public static class Kernel32
{
	[DllImport("kernel32.dll", ExactSpelling = true)]
	public static extern IntPtr OpenProcess(uint processAccess, bool inheritHandle, int processID);

	[DllImport("kernel32.dll", ExactSpelling = true)]
	public static extern IntPtr CreateRemoteThread(IntPtr processHandle, IntPtr threadAttributes, uint stackSize, IntPtr startAddress, IntPtr parameter, uint creationFlags, out uint threadID);
}
public static class NtDLL
{
	[DllImport("ntdll.dll", ExactSpelling = true)]
	public static extern uint NtCreateSection(out IntPtr sectionHandle, uint desiredAccess, IntPtr objectAttributes, ref long maxSize, uint pageAttributes, uint sectionAttributes, IntPtr fileHandle);

	[DllImport("ntdll.dll", ExactSpelling = true)]
	public static extern uint NtMapViewOfSection(IntPtr sectionHandle, IntPtr processHandle, ref IntPtr baseAddress, uint zeroBits, uint commitSize, ref long sectionOffset, ref uint viewSize, uint inheritDisposition, uint allocationType, uint pageProtection);

	[DllImport("ntdll.dll", ExactSpelling = true)]
	public static extern uint NtUnmapViewOfSection(IntPtr processHandle, IntPtr baseAddress);

	[DllImport("ntdll.dll", ExactSpelling = true)]
	public static extern int NtClose(IntPtr objectHandle);
}
