csharp/tyranid/WindowsRpcClients/Win10_1809/appinfo.dll/0497b57d-2e66-424f-a0c6-157cd5d41700_1.0.cs

0497b57d-2e66-424f-a0c6-157cd5d41700_1.0.cs
//------------------------------------------------------------------------------
// 
//     This code was generated by a tool.
//     Runtime Version:4.0.30319.42000
//
//     Changes to this file may cause incorrect behavior and will be lost if
//     the code is regenerated.
// 
//------------------------------------------------------------------------------

// Source Executable: c:\windows\system32\appinfo.dll
// Interface ID: 0497b57d-2e66-424f-a0c6-157cd5d41700
// Interface Version: 1.0



namespace rpc_0497b57d_2e66_424f_a0c6_157cd5d41700_1_0
{
    
    #region Marshal Helpers
    internal clast _Marshal_Helper : NtApiDotNet.Ndr.Marshal.NdrMarshalBuffer
    {
        public void Write_0(Struct_0 p0)
        {
            WriteStruct(p0);
        }
        public void Write_1(Struct_1 p0)
        {
            WriteStruct(p0);
        }
        public void Write_2(Struct_3 p0)
        {
            WriteStruct(p0);
        }
        public void Write_3(NtApiDotNet.NtProcess p0)
        {
            WriteSystemHandle(p0);
        }
        public void Write_4(NtApiDotNet.NtToken p0)
        {
            WriteSystemHandle(p0);
        }
        public void Write_5(NtApiDotNet.NtProcess p0)
        {
            WriteSystemHandle(p0);
        }
        public void Write_6(NtApiDotNet.NtThread p0)
        {
            WriteSystemHandle(p0);
        }
    }
    internal clast _Unmarshal_Helper : NtApiDotNet.Ndr.Marshal.NdrUnmarshalBuffer
    {
        public _Unmarshal_Helper(NtApiDotNet.Win32.Rpc.RpcClientResponse r) : 
                base(r.NdrBuffer, r.Handles, r.DataRepresentation)
        {
        }
        public _Unmarshal_Helper(byte[] ba) : 
                base(ba)
        {
        }
        public Struct_0 Read_0()
        {
            return ReadStruct();
        }
        public Struct_1 Read_1()
        {
            return ReadStruct();
        }
        public Struct_3 Read_2()
        {
            return ReadStruct();
        }
        public NtApiDotNet.NtProcess Read_3()
        {
            return ReadSystemHandle();
        }
        public NtApiDotNet.NtToken Read_4()
        {
            return ReadSystemHandle();
        }
        public NtApiDotNet.NtProcess Read_5()
        {
            return ReadSystemHandle();
        }
        public NtApiDotNet.NtThread Read_6()
        {
            return ReadSystemHandle();
        }
    }
    #endregion
    #region Complex Types
    public struct Struct_0 : NtApiDotNet.Ndr.Marshal.INdrStructure
    {
        void NtApiDotNet.Ndr.Marshal.INdrStructure.Marshal(NtApiDotNet.Ndr.Marshal.NdrMarshalBuffer m)
        {
            Marshal(((_Marshal_Helper)(m)));
        }
        private void Marshal(_Marshal_Helper m)
        {
            m.WriteEmbeddedPointer(Member0, new System.Action(m.WriteTerminatedString));
            m.WriteInt32(Member8);
            m.WriteInt32(MemberC);
            m.WriteInt32(Member10);
            m.WriteInt32(Member14);
            m.WriteInt32(Member18);
            m.WriteInt32(Member1C);
            m.WriteInt32(Member20);
            m.WriteInt32(Member24);
            m.WriteInt16(Member28);
            m.Write_1(Member2C);
        }
        void NtApiDotNet.Ndr.Marshal.INdrStructure.Unmarshal(NtApiDotNet.Ndr.Marshal.NdrUnmarshalBuffer u)
        {
            Unmarshal(((_Unmarshal_Helper)(u)));
        }
        private void Unmarshal(_Unmarshal_Helper u)
        {
            Member0 = u.ReadEmbeddedPointer(new System.Func(u.ReadConformantVaryingString), false);
            Member8 = u.ReadInt32();
            MemberC = u.ReadInt32();
            Member10 = u.ReadInt32();
            Member14 = u.ReadInt32();
            Member18 = u.ReadInt32();
            Member1C = u.ReadInt32();
            Member20 = u.ReadInt32();
            Member24 = u.ReadInt32();
            Member28 = u.ReadInt16();
            Member2C = u.Read_1();
        }
        int NtApiDotNet.Ndr.Marshal.INdrStructure.GetAlignment()
        {
            return 4;
        }
        public NtApiDotNet.Ndr.Marshal.NdrEmbeddedPointer Member0;
        public int Member8;
        public int MemberC;
        public int Member10;
        public int Member14;
        public int Member18;
        public int Member1C;
        public int Member20;
        public int Member24;
        public short Member28;
        public Struct_1 Member2C;
        public static Struct_0 CreateDefault()
        {
            return new Struct_0();
        }
        public Struct_0(string Member0, int Member8, int MemberC, int Member10, int Member14, int Member18, int Member1C, int Member20, int Member24, short Member28, Struct_1 Member2C)
        {
            this.Member0 = Member0;
            this.Member8 = Member8;
            this.MemberC = MemberC;
            this.Member10 = Member10;
            this.Member14 = Member14;
            this.Member18 = Member18;
            this.Member1C = Member1C;
            this.Member20 = Member20;
            this.Member24 = Member24;
            this.Member28 = Member28;
            this.Member2C = Member2C;
        }
    }
    public struct Struct_1 : NtApiDotNet.Ndr.Marshal.INdrStructure
    {
        void NtApiDotNet.Ndr.Marshal.INdrStructure.Marshal(NtApiDotNet.Ndr.Marshal.NdrMarshalBuffer m)
        {
            Marshal(((_Marshal_Helper)(m)));
        }
        private void Marshal(_Marshal_Helper m)
        {
            m.WriteInt32(Member0);
            m.WriteInt32(Member4);
        }
        void NtApiDotNet.Ndr.Marshal.INdrStructure.Unmarshal(NtApiDotNet.Ndr.Marshal.NdrUnmarshalBuffer u)
        {
            Unmarshal(((_Unmarshal_Helper)(u)));
        }
        private void Unmarshal(_Unmarshal_Helper u)
        {
            Member0 = u.ReadInt32();
            Member4 = u.ReadInt32();
        }
        int NtApiDotNet.Ndr.Marshal.INdrStructure.GetAlignment()
        {
            return 4;
        }
        public int Member0;
        public int Member4;
        public static Struct_1 CreateDefault()
        {
            return new Struct_1();
        }
        public Struct_1(int Member0, int Member4)
        {
            this.Member0 = Member0;
            this.Member4 = Member4;
        }
    }
    public struct Struct_3 : NtApiDotNet.Ndr.Marshal.INdrStructure
    {
        void NtApiDotNet.Ndr.Marshal.INdrStructure.Marshal(NtApiDotNet.Ndr.Marshal.NdrMarshalBuffer m)
        {
            Marshal(((_Marshal_Helper)(m)));
        }
        private void Marshal(_Marshal_Helper m)
        {
            m.WriteUInt3264(Member0);
            m.WriteUInt3264(Member8);
            m.WriteInt32(Member10);
            m.WriteInt32(Member14);
        }
        void NtApiDotNet.Ndr.Marshal.INdrStructure.Unmarshal(NtApiDotNet.Ndr.Marshal.NdrUnmarshalBuffer u)
        {
            Unmarshal(((_Unmarshal_Helper)(u)));
        }
        private void Unmarshal(_Unmarshal_Helper u)
        {
            Member0 = u.ReadUInt3264();
            Member8 = u.ReadUInt3264();
            Member10 = u.ReadInt32();
            Member14 = u.ReadInt32();
        }
        int NtApiDotNet.Ndr.Marshal.INdrStructure.GetAlignment()
        {
            return 4;
        }
        public NtApiDotNet.Ndr.Marshal.NdrUInt3264 Member0;
        public NtApiDotNet.Ndr.Marshal.NdrUInt3264 Member8;
        public int Member10;
        public int Member14;
        public static Struct_3 CreateDefault()
        {
            return new Struct_3();
        }
        public Struct_3(NtApiDotNet.Ndr.Marshal.NdrUInt3264 Member0, NtApiDotNet.Ndr.Marshal.NdrUInt3264 Member8, int Member10, int Member14)
        {
            this.Member0 = Member0;
            this.Member8 = Member8;
            this.Member10 = Member10;
            this.Member14 = Member14;
        }
    }
    #endregion
    #region Client Implementation
    public sealed clast Client : NtApiDotNet.Win32.Rpc.RpcClientBase
    {
        public Client() : 
                base("0497b57d-2e66-424f-a0c6-157cd5d41700", 1, 0)
        {
        }
        private _Unmarshal_Helper SendReceive(int p, _Marshal_Helper m)
        {
            return new _Unmarshal_Helper(SendReceive(p, m.DataRepresentation, m.ToArray(), m.Handles));
        }
        // async
        public int RAiLaunchProcessWithIdensaty(
                    string p0, 
                    string p1, 
                    int p2, 
                    int p3, 
                    string p4, 
                    string p5, 
                    Struct_0 p6, 
                    string p7, 
                    string p8, 
                    NtApiDotNet.Ndr.Marshal.NdrUInt3264 p9, 
                    int p10, 
                    int p11, 
                    NtApiDotNet.NtProcess p12, 
                    long p13, 
                    System.Nullable p14, 
                    System.Nullable p15, 
                    long p16, 
                    out Struct_3 p17)
        {
            _Marshal_Helper m = new _Marshal_Helper();
            m.WriteReferent(p0, new System.Action(m.WriteTerminatedString));
            m.WriteReferent(p1, new System.Action(m.WriteTerminatedString));
            m.WriteInt32(p2);
            m.WriteInt32(p3);
            m.WriteTerminatedString(NtApiDotNet.Win32.Rpc.RpcUtils.CheckNull(p4, "p4"));
            m.WriteTerminatedString(NtApiDotNet.Win32.Rpc.RpcUtils.CheckNull(p5, "p5"));
            m.Write_0(p6);
            m.WriteTerminatedString(NtApiDotNet.Win32.Rpc.RpcUtils.CheckNull(p7, "p7"));
            m.WriteTerminatedString(NtApiDotNet.Win32.Rpc.RpcUtils.CheckNull(p8, "p8"));
            m.WriteUInt3264(p9);
            m.WriteInt32(p10);
            m.WriteInt32(p11);
            m.Write_3(p12);
            m.WriteInt64(p13);
            m.WriteReferent(p14, new System.Action(m.WriteInt64));
            m.WriteReferent(p15, new System.Action(m.WriteGuid));
            m.WriteInt64(p16);
            _Unmarshal_Helper u = SendReceive(0, m);
            p17 = u.Read_2();
            return u.ReadInt32();
        }
        // async
        public int RAiGetPackageActivationToken(string p0, NtApiDotNet.NtToken p1, out NtApiDotNet.NtToken p2)
        {
            _Marshal_Helper m = new _Marshal_Helper();
            m.WriteTerminatedString(NtApiDotNet.Win32.Rpc.RpcUtils.CheckNull(p0, "p0"));
            m.Write_4(p1);
            _Unmarshal_Helper u = SendReceive(1, m);
            p2 = u.Read_4();
            return u.ReadInt32();
        }
        // async
        public int RAiFinishPackageActivation(NtApiDotNet.NtProcess p0, NtApiDotNet.NtThread p1, int p2, string p3, string p4, NtApiDotNet.NtToken p5, out int p6)
        {
            _Marshal_Helper m = new _Marshal_Helper();
            m.Write_5(p0);
            m.Write_6(p1);
            m.WriteInt32(p2);
            m.WriteReferent(p3, new System.Action(m.WriteTerminatedString));
            m.WriteReferent(p4, new System.Action(m.WriteTerminatedString));
            m.Write_4(p5);
            _Unmarshal_Helper u = SendReceive(2, m);
            p6 = u.ReadInt32();
            return u.ReadInt32();
        }
        // async
        public int RAiEnsurePackageShutdown(string p0, int p1)
        {
            _Marshal_Helper m = new _Marshal_Helper();
            m.WriteTerminatedString(NtApiDotNet.Win32.Rpc.RpcUtils.CheckNull(p0, "p0"));
            m.WriteInt32(p1);
            _Unmarshal_Helper u = SendReceive(3, m);
            return u.ReadInt32();
        }
    }
    #endregion
}