drsuapi.idl: add DN/fpo-enabled attributes as DRSUAPI_ATTID_* values
[gd/samba-autobuild/.git] / librpc / idl / drsuapi.idl
index 7e3d34317ecccf6011de3b6bac5b68876d841e26..cd90500faf57c4c9362e144b17b0ed4d59b57d09 100644 (file)
@@ -58,6 +58,10 @@ interface drsuapi
                DRSUAPI_DRS_GET_ALL_GROUP_MEMBERSHIP  = 0x80000000
        } drsuapi_DrsOptions;
 
+       typedef [public,bitmap32bit] bitmap {
+               DRSUAPI_DRS_GET_TGT                   = 0x00000001
+       } drsuapi_DrsMoreOptions;
+
        /* see DRS_MSG_REPMOD_V1 */
        typedef [public,bitmap32bit] bitmap {
                DRSUAPI_DRS_UPDATE_FLAGS              = 0x00000001,
@@ -66,7 +70,9 @@ interface drsuapi
         } drsuapi_DrsUpdate;
 
        /*****************/
-        /* Function 0x00 */
+        /* Function 0x00 drsuapi_DsBind() */
+
+        /* MS-DRSR 5.39 DRS_EXTENSIONS_INT */
         typedef [bitmap32bit] bitmap {
                DRSUAPI_SUPPORTED_EXTENSION_BASE                        = 0x00000001,
                DRSUAPI_SUPPORTED_EXTENSION_ASYNC_REPLICATION           = 0x00000002,
@@ -115,22 +121,30 @@ interface drsuapi
        } drsuapi_SupportedExtensionsExt;
 
        /* this is used by w2k */
-       typedef struct {
+       typedef [public] struct {
                drsuapi_SupportedExtensions supported_extensions;
                GUID site_guid;
                uint32 pid;
        } drsuapi_DsBindInfo24;
 
        /* this is used by w2k3 */
-       typedef struct {
+       typedef [public] struct {
                drsuapi_SupportedExtensions supported_extensions;
                GUID site_guid;
                uint32 pid;
                uint32 repl_epoch;
        } drsuapi_DsBindInfo28;
 
+       typedef [public] struct {
+               drsuapi_SupportedExtensions supported_extensions;
+               GUID site_guid;
+               uint32 pid;
+               uint32 repl_epoch;
+               drsuapi_SupportedExtensionsExt supported_extensions_ext;
+       } drsuapi_DsBindInfo32;
+
        /* this is used by w2k8 */
-       typedef struct {
+       typedef [public] struct {
                drsuapi_SupportedExtensions supported_extensions;
                GUID site_guid;
                uint32 pid;
@@ -139,15 +153,34 @@ interface drsuapi
                GUID config_dn_guid;
        } drsuapi_DsBindInfo48;
 
-       typedef struct {
+       /* this is used by w2k12 R2 [MS-DRSR] Section 5.39 */
+       typedef [public] struct {
+               drsuapi_SupportedExtensions supported_extensions;
+               GUID site_guid;
+               uint32 pid;
+               uint32 repl_epoch;
+               drsuapi_SupportedExtensionsExt supported_extensions_ext;
+               GUID config_dn_guid;
+               drsuapi_SupportedExtensionsExt supported_capabilities_ext;
+       } drsuapi_DsBindInfo52;
+
+       typedef [public] struct {
                [flag(NDR_REMAINING)] DATA_BLOB info;
        } drsuapi_DsBindInfoFallBack;
 
-       typedef [nodiscriminant] union {
-               [case(24)][subcontext(4)] drsuapi_DsBindInfo24 info24;
-               [case(28)][subcontext(4)] drsuapi_DsBindInfo28 info28;
-               [case(48)][subcontext(4)] drsuapi_DsBindInfo48 info48;
-               [default][subcontext(4)] drsuapi_DsBindInfoFallBack FallBack;
+       typedef [nopull, nopush, noprint] [nodiscriminant] union {
+               [case(24)][subcontext(0), subcontext_size(24)] drsuapi_DsBindInfo24 info24;
+               [case(28)][subcontext(0), subcontext_size(28)] drsuapi_DsBindInfo28 info28;
+               [case(32)][subcontext(0), subcontext_size(32)] drsuapi_DsBindInfo32 info32;
+               [case(48)][subcontext(0), subcontext_size(48)] drsuapi_DsBindInfo48 info48;
+               [case(52)][subcontext(0), subcontext_size(52)] drsuapi_DsBindInfo52 info52;
+               /*
+                * The size for the defaut case is a bit arbitrary it in fact the value
+                * of the switch but we can't reference it.
+                * As we hand(un-)marshall this structure it has 0 impact and makes
+                * pidl happy for wireshark too
+                */
+               [default][subcontext(0), subcontext_size(48)] drsuapi_DsBindInfoFallBack Fallback;
        } drsuapi_DsBindInfo;
 
        /* the drsuapi_DsBindInfoCtr was this before
@@ -160,11 +193,44 @@ interface drsuapi
         * so we're doing it here
         */
 
+       /*
+        * MS-DRSR.pdf gives the following definition
+       typedef struct {
+               [range(1,10000)] DWORD cb;
+               [size_is(cb)] BYTE rgb[];
+       } DRS_EXTENSIONS;
+
+       But we use a subcontext which has a slighly different signification on how
+       data are laid out.
+       With the MS-DRSR definition we will have
+               size_is_cb cv rgb_array
+       with size_is_cb being a uint3264 and cv being a uint32
+
+       We used to have
        typedef struct {
                [range(1,10000)] uint32 length;
                [switch_is(length)] drsuapi_DsBindInfo info;
        } drsuapi_DsBindInfoCtr;
 
+       typedef [nodiscriminant] union {
+               [case(24)][subcontext(4)] drsuapi_DsBindInfo24 info24;
+               [case(28)][subcontext(4)] drsuapi_DsBindInfo28 info28;
+               [case(48)][subcontext(4)] drsuapi_DsBindInfo48 info48;
+               [default][subcontext(4)] drsuapi_DsBindInfoFallBack FallBack;
+       } drsuapi_DsBindInfo;
+
+       With this definition data is laid out this way:
+       length subcontext_size drsuapi_DsBindInfoxx
+       with length being a uint32 and subcontext_size being a uint3264
+
+       It has clearly an impact on the way things are aligned when using NDR64
+       */
+       typedef [flag(NDR_NOALIGN)] struct {
+               [range(1,10000)] uint3264 length;
+               [value(length)] uint32 __ndr_length;
+               [switch_is(length)] drsuapi_DsBindInfo info;
+       } drsuapi_DsBindInfoCtr;
+
        /* this is a magic guid you need to pass to DsBind to make drsuapi_DsWriteAccountSpn() work
         *
         * maybe the bind_guid could also be the invocation_id see drsuapi_DsReplicaConnection04
@@ -394,6 +460,7 @@ interface drsuapi
                DRSUAPI_ATTID_ou                                = 0x0000000b,
                DRSUAPI_ATTID_description                       = 0x0000000d,
                DRSUAPI_ATTID_member                            = 0x0000001f,
+               DRSUAPI_ATTID_distinguishedName                 = 0x00000031,
                DRSUAPI_ATTID_instanceType                      = 0x00020001,
                DRSUAPI_ATTID_whenCreated                       = 0x00020002,
                DRSUAPI_ATTID_possSuperiors                     = 0x00020008,
@@ -423,6 +490,8 @@ interface drsuapi
                DRSUAPI_ATTID_auxiliaryClass                    = 0x0002015f,
                DRSUAPI_ATTID_lDAPDisplayName                   = 0x000201cc,
                DRSUAPI_ATTID_name                              = 0x00090001,
+               DRSUAPI_ATTID_objectGUID                        = 0x00090002,
+               DRSUAPI_ATTID_replPropertyMetaData              = 0x00090003,
                DRSUAPI_ATTID_userAccountControl                = 0x00090008,
                DRSUAPI_ATTID_badPwdCount                       = 0x0009000c,
                DRSUAPI_ATTID_codePage                          = 0x00090010,
@@ -446,8 +515,10 @@ interface drsuapi
                DRSUAPI_ATTID_trustAuthOutgoing                 = 0x00090087,
                DRSUAPI_ATTID_userParameters                    = 0x0009008a,
                DRSUAPI_ATTID_profilePath                       = 0x0009008b,
+               DRSUAPI_ATTID_operatorCount                     = 0x00090090,
                DRSUAPI_ATTID_objectSid                         = 0x00090092,
                DRSUAPI_ATTID_schemaIDGUID                      = 0x00090094,
+               DRSUAPI_ATTID_adminCount                        = 0x00090096,
                DRSUAPI_ATTID_comment                           = 0x0009009C,/* User-Comment */
                DRSUAPI_ATTID_accountExpires                    = 0x0009009f,
                DRSUAPI_ATTID_lmPwdHistory                      = 0x000900a0,
@@ -463,11 +534,13 @@ interface drsuapi
                DRSUAPI_ATTID_systemFlags                       = 0x00090177,
                DRSUAPI_ATTID_serverReference                   = 0x00090203,
                DRSUAPI_ATTID_serverReferenceBL                 = 0x00090204,
+               DRSUAPI_ATTID_nonSecurityMember                 = 0x00090212,
                DRSUAPI_ATTID_initialAuthIncoming               = 0x0009021b,
                DRSUAPI_ATTID_initialAuthOutgoing               = 0x0009021c,
                DRSUAPI_ATTID_wellKnownObjects                  = 0x0009026a,
                DRSUAPI_ATTID_dNSHostName                       = 0x0009026b,
                DRSUAPI_ATTID_isMemberOfPartialAttributeSet     = 0x0009027f,
+               DRSUAPI_ATTID_managedBy                         = 0x0009028d,
                DRSUAPI_ATTID_userPrincipalName                 = 0x00090290,
                DRSUAPI_ATTID_groupType                         = 0x000902ee,
                DRSUAPI_ATTID_servicePrincipalName              = 0x00090303,
@@ -477,8 +550,13 @@ interface drsuapi
                DRSUAPI_ATTID_transportAddressAttribute         = 0x0009037f,
                DRSUAPI_ATTID_msDS_Behavior_Version             = 0x000905b3,
                DRSUAPI_ATTID_msDS_KeyVersionNumber             = 0x000906f6,
+               DRSUAPI_ATTID_msDS_NonMembers                   = 0x00090701,
+               DRSUAPI_ATTID_msDS_MembersForAzRole             = 0x0009070e,
                DRSUAPI_ATTID_msDS_HasDomainNCs                 = 0x0009071c,
                DRSUAPI_ATTID_msDS_hasMasterNCs                 = 0x0009072c,
+               DRSUAPI_ATTID_msDS_NeverRevealGroup             = 0x00090786,
+               DRSUAPI_ATTID_msDS_RevealOnDemandGroup          = 0x00090788,
+               DRSUAPI_ATTID_msDS_HostServiceAccount           = 0x00090808,
                DRSUAPI_ATTID_isRecycled                        = 0x0009080a,
 
                DRSUAPI_ATTID_INVALID                           = 0xFFFFFFFF
@@ -491,7 +569,7 @@ interface drsuapi
                [size_is(num_attids)] drsuapi_DsAttributeId attids[];
        } drsuapi_DsPartialAttributeSet;
 
-       typedef struct {
+       typedef [public] struct {
                GUID destination_dsa_guid;
                GUID source_dsa_invocation_id; /* the 'invocationId' field of the CN=NTDS Settings object */
                [ref] drsuapi_DsReplicaObjectIdentifier *naming_context;
@@ -507,7 +585,7 @@ interface drsuapi
                drsuapi_DsReplicaOIDMapping_Ctr mapping_ctr;
        } drsuapi_DsGetNCChangesRequest8;
 
-       typedef struct {
+       typedef [public] struct {
                GUID destination_dsa_guid;
                GUID source_dsa_invocation_id; /* the 'invocationId' field of the CN=NTDS Settings object */
                [ref] drsuapi_DsReplicaObjectIdentifier *naming_context;
@@ -521,7 +599,7 @@ interface drsuapi
                drsuapi_DsPartialAttributeSet *partial_attribute_set;
                drsuapi_DsPartialAttributeSet *partial_attribute_set_ex;
                drsuapi_DsReplicaOIDMapping_Ctr mapping_ctr;
-               uint32 more_flags;
+               drsuapi_DrsMoreOptions more_flags;
        } drsuapi_DsGetNCChangesRequest10;
 
        typedef [switch_type(uint32)] union {