diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2008-09-16 04:15:39 +0200 |
---|---|---|
committer | Jelmer Vernooij <jelmer@samba.org> | 2008-09-16 04:15:39 +0200 |
commit | e9d44b2e1cbfe4f5b318086423649ece39ce6ef9 (patch) | |
tree | 1f4643ec8e00a32bee84173f6ebb4fbb30765ce0 /source4 | |
parent | c212a65b65ba0100ceb9c4fa48c1f44dc0c804f5 (diff) | |
download | samba-e9d44b2e1cbfe4f5b318086423649ece39ce6ef9.tar.gz samba-e9d44b2e1cbfe4f5b318086423649ece39ce6ef9.tar.bz2 samba-e9d44b2e1cbfe4f5b318086423649ece39ce6ef9.zip |
Import proper IDL for interface pointers.
Diffstat (limited to 'source4')
-rw-r--r-- | source4/librpc/idl/wmi.idl | 611 | ||||
-rw-r--r-- | source4/librpc/rpc/dcerpc.h | 2 | ||||
-rw-r--r-- | source4/pidl/idl.yp | 9 |
3 files changed, 275 insertions, 347 deletions
diff --git a/source4/librpc/idl/wmi.idl b/source4/librpc/idl/wmi.idl index e3e98ba83d..8b3fda3b40 100644 --- a/source4/librpc/idl/wmi.idl +++ b/source4/librpc/idl/wmi.idl @@ -33,6 +33,15 @@ interface IWbemClassObject : IUnknown }; [ + uuid(9A653086-174F-11d2-B5F9-00104B703EFD) +] +coclass WbemClassObject +{ + interface IWbemClassObject; +}; + + +[ uuid("9556dc99-828c-11cf-a37e-00aa003240c7"), object, pointer_default(unique) @@ -379,35 +388,6 @@ interface IWbemClassObject : IUnknown // WCF_CLASS_PART_SHARED = 0x104 } WCO_FLAGS; - typedef [public,nopush,nopull] struct - { - [relative,charset(UTF16)] uint16 *name; - WBEM_FLAVOR_TYPE flavors; - CIMTYPE_ENUMERATION cimtype; - [switch_is(cimtype)] CIMVAR value; - } WbemQualifier; - - typedef [public,nopush,nopull] struct - { - uint32 count; - [ref] WbemQualifier* item[count]; - } WbemQualifiers; - - typedef [public] struct - { - uint32 cimtype; - uint16 nr; - uint32 offset; - uint32 depth; - WbemQualifiers qualifiers; - } WbemPropertyDesc; - - typedef [public] struct - { - [relative,charset(UTF16)] uint16 *name; - [relative] WbemPropertyDesc *desc; - } WbemProperty; - typedef [public,nopull,nopush] struct { uint32 count; @@ -419,178 +399,107 @@ interface IWbemClassObject : IUnknown DEFAULT_FLAG_INHERITED = 2 } DEFAULT_FLAGS; - typedef struct { - WbemProperty property; - uint8 default_flags; - [switch_is(property.desc->cimtype)] CIMVAR default_values; - } WbemClassProperty; - - - typedef [public,nopush,nopull,flag(NDR_NOALIGN)] struct - { - uint8 u_0; - [relative, null_is_ffffffff,charset(UTF16)] uint16 *__CLASS; - uint32 data_size; - CIMSTRINGS __DERIVATION; - WbemQualifiers qualifiers; - uint32 __PROPERTY_COUNT; - WbemClassProperty properties[__PROPERTY_COUNT]; - } WbemClass; - - typedef [public] struct - { - [relative,null_is_ffffffff,charset(UTF16)] uint16 *name; - uint32 u0; - uint32 u1; - [relative] WbemQualifiers *qualifiers; - [subcontext(4),relative] WbemClassObject *in; - [subcontext(4),relative] WbemClassObject *out; - } WbemMethod; - - typedef [public,flag(NDR_NOALIGN)] struct - { - uint16 count; - uint16 u0; // It has value 5F5F if there are no methods - WbemMethod method[count]; - } WbemMethods; - - typedef [public,flag(NDR_NOALIGN),nopush,nopull,noprint] struct - { - uint8 u1_0; - [relative,charset(UTF16)] uint16 *__CLASS; - uint8 *default_flags; - uint32 *data; - uint32 u2_4; - uint8 u3_1; - } WbemInstance; - - typedef [public,nopush,nopull,noprint,flag(NDR_NOALIGN)] struct - { - WCO_FLAGS flags; - [ref,charset(UTF16)] uint16 *__SERVER; - [ref,charset(UTF16)] uint16 *__NAMESPACE; - WbemClass *sup_class; - WbemMethods *sup_methods; - WbemClass *obj_class; - WbemMethods *obj_methods; - WbemInstance *instance; - } WbemClassObject; - -// typedef [public] struct { -// [value(0x72657355)] uint32 fFlags; -// uint32 clSize; -// [value(2*clSize)] uint32 _bsize; -// [value(clSize)] uint32 _wsize; -// [flag(NDR_NOALIGN)] uint16 asData[clSize]; -// } BSTR1; - //typedef [public,nopush,nopull,noprint,string,charset(UTF16)] uint16 *BSTR; - - WERROR OpenNamespace( -// [in] BSTR *strNamespace, -// [in] int32 lFlags -// [in] IWbemContext* pCtx, -// [out] IWbemServices** ppWorkingNamespace, -// [out] IWbemCallResult** ppResult - ); - - WERROR CancelAsyncCall( -// [in] IWbemObjectSink* pSink - ); - - WERROR QueryObjectSink( -// [in] long lFlags -// [out] IWbemObjectSink** ppResponseHandler - ); - - // Classes and instances. - // ====================== - - WERROR GetObject( - [in] BSTR strObjectPath, - [in] long lFlags, - [in,unique] IWbemContext* pCtx, -// [in,out,unique] IUnknown** ppObject, -// [in,out,unique] IUnknown** ppCallResult - [in,out,unique] IWbemClassObject** ppObject, - [in,out,unique] IWbemCallResult** ppCallResult - ); - - WERROR GetObjectAsync( -// [in] BSTR strObjectPath, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); - - WERROR PutClass( -// [in] IWbemClassObject* pObject, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [out, OPTIONAL] IWbemCallResult** ppCallResult - ); - - WERROR PutClassAsync( -// [in] IWbemClassObject* pObject, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); - - WERROR DeleteClass( -// [in] BSTR strClass, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [out, OPTIONAL] IWbemCallResult** ppCallResult - ); - - WERROR DeleteClassAsync( -// [in] BSTR strClass, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); - - WERROR CreateClassEnum( -// [in] BSTR strSuperclass, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [out] IEnumWbemClassObject** ppEnum - ); - - WERROR CreateClassEnumAsync( -// [in] BSTR strSuperclass, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); - - WERROR PutInstance( -// [in] IWbemClassObject* pInst, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [out, OPTIONAL] IWbemCallResult** ppCallResult - ); + WERROR OpenNamespace( + [in] BSTR strNamespace, + [in] long lFlags, + [in] IWbemContext* pCtx, + [out, in, unique] IWbemServices** ppWorkingNamespace, + [out, in, unique] IWbemCallResult** ppResult + ); + WERROR CancelAsyncCall( + [in] IWbemObjectSink* pSink + ); + WERROR QueryObjectSink( + [in] long lFlags, + [out] IWbemObjectSink** ppResponseHandler + ); + WERROR GetObject( + [in] BSTR strObjectPath, + [in] long lFlags, + [in] IWbemContext* pCtx, + [out, in, unique] IWbemClassObject** ppObject, + [out, in, unique] IWbemCallResult** ppCallResult + ); + + + WERROR GetObjectAsync( + [in] BSTR strObjectPath, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); + WERROR PutClass( + [in] IWbemClassObject* pObject, + [in] long lFlags, + [in] IWbemContext* pCtx, + [out, in, unique] IWbemCallResult** ppCallResult + ); + + WERROR PutClassAsync( + [in] IWbemClassObject* pObject, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); + + WERROR DeleteClass( + [in] BSTR strClass, + [in] long lFlags, + [in] IWbemContext* pCtx, + [out, in, unique] IWbemCallResult** ppCallResult + ); + + WERROR DeleteClassAsync( + [in] BSTR strClass, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); + + WERROR CreateClassEnum( + [in] BSTR strSuperclass, + [in] long lFlags, + [in] IWbemContext* pCtx, + [out] IEnumWbemClassObject** ppEnum + ); + + WERROR CreateClassEnumAsync( + [in] BSTR strSuperclass, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); + + WERROR PutInstance( + [in] IWbemClassObject* pInst, + [in] long lFlags, + [in] IWbemContext* pCtx, + [out, in, unique] IWbemCallResult** ppCallResult + ); + + WERROR PutInstanceAsync( + [in] IWbemClassObject* pInst, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); + + + WERROR DeleteInstance( + [in] BSTR strObjectPath, + [in] long lFlags, + [in] IWbemContext* pCtx, + [out, in, unique] IWbemCallResult** ppCallResult + ); + + + WERROR DeleteInstanceAsync( + [in] BSTR strObjectPath, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); - WERROR PutInstanceAsync( -// [in] IWbemClassObject* pInst, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); - - WERROR DeleteInstance( -// [in] BSTR strObjectPath, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [out, OPTIONAL] IWbemCallResult** ppCallResult - ); - - WERROR DeleteInstanceAsync( -// [in] BSTR strObjectPath, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); WERROR CreateInstanceEnum( [in] BSTR strFilter, // allow more things than a class name @@ -599,12 +508,12 @@ interface IWbemClassObject : IUnknown [out] IEnumWbemClassObject** ppEnum ); - WERROR CreateInstanceEnumAsync( -// [in] BSTR strFilter, // allow more things than a class name -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); + WERROR CreateInstanceEnumAsync( + [in] BSTR strSuperClass, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); WERROR ExecQuery( [in] BSTR strQueryLanguage, @@ -614,14 +523,13 @@ interface IWbemClassObject : IUnknown [out] IEnumWbemClassObject** ppEnum ); - WERROR ExecQueryAsync( -// [in] BSTR strQueryLanguage, -// [in] BSTR strQuery, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); - + WERROR ExecQueryAsync( + [in] BSTR strQueryLanguage, + [in] BSTR strQuery, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); WERROR ExecNotificationQuery( [in] BSTR strQueryLanguage, @@ -631,16 +539,13 @@ interface IWbemClassObject : IUnknown [out] IEnumWbemClassObject** ppEnum ); - WERROR ExecNotificationQueryAsync( -// [in] BSTR strQueryLanguage, -// [in] BSTR strQuery, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemObjectSink* pResponseHandler - ); - - // Methods - // ======= + WERROR ExecNotificationQueryAsync( + [in] BSTR strQueryLanguage, + [in] BSTR strQuery, + [in] long lFlags, + [in] IWbemContext* pCtx, + [in] IWbemObjectSink* pResponseHandler + ); WERROR ExecMethod( [in] BSTR strObjectPath, @@ -652,14 +557,14 @@ interface IWbemClassObject : IUnknown [in,out,unique] IWbemCallResult** ppCallResult ); - WERROR ExecMethodAsync( -// [in] BSTR strObjectPath, -// [in] BSTR strMethodName, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [in] IWbemClassObject* pInParams, -// [in] IWbemObjectSink* pResponseHandler - ); + WERROR ExecMethodAsync( + [in] BSTR strObjectPath, + [in] BSTR strMethodName, + [in] uint32 lFlags, + [in] IWbemContext* pCtx, + [in] IWbemClassObject* pInParams, + [in] IWbemObjectSink* pResponseHandler + ); } [ @@ -679,17 +584,17 @@ interface IWbemClassObject : IUnknown ); WERROR NextAsync( -// [in] ULONG uCount -// [in] IWbemObjectSink* pSink + [in] uint32 uCount + [in] IWbemObjectSink* pSink ); WERROR IEnumWbemClassObject_Clone( -// [out] IEnumWbemClassObject** ppEnum + [out] IEnumWbemClassObject** ppEnum ); WERROR Skip( -// [in] long lTimeout, -// [in] ULONG nCount + [in] int32 lTimeout, + [in] uint32 nCount ); }; @@ -744,33 +649,33 @@ interface IWbemClassObject : IUnknown pointer_default(unique) ] interface IWbemLevel1Login : IUnknown { - WERROR EstablishPosition( -// [in, unique, string] LPWSTR wszClientMachineName, -// [in] uint32 dwProcessId, -// [out] uint32* phAuthEventHandle - ); - - WERROR RequestChallenge( -// [in, unique, string] LPWSTR wszNetworkResource, -// [in, unique, string] LPWSTR wszUser, -// [out] WBEM_128BITS Nonce - ); - - WERROR WBEMLogin( -// [in, unique, string] LPWSTR wszPreferredLocale, -// [in, unique] WBEM_128BITS AccessToken, -// [in] long lFlags -// [in] IWbemContext* pCtx, -// [out] IWbemServices** ppNamespace - ); - - WERROR NTLMLogin( - [in,unique,string,charset(UTF16)] uint16 *wszNetworkResource, - [in,unique,string,charset(UTF16)] uint16 *wszPreferredLocale, - [in] long lFlags, - [in,unique] IWbemContext* pCtx, - [out,ref] IWbemServices** ppNamespace - ); + WERROR EstablishPosition( + [in, unique, string, charset(UTF16)] uint16* wszLocaleList, + [in] DWORD dwNumLocales, + [out] DWORD* reserved + ); + WERROR RequestChallenge( + [in, unique, string, charset(UTF16)] uint16* wszNetworkResource, + [in, unique, string, charset(UTF16)] uint16* wszUser, + [out, size_is(16), length_is(16)] unsigned char* Nonce + ); + WERROR WBEMLogin( + [in, unique, string, charset(UTF16)] uint16* wszPreferredLocale, + [in, size_is(16), length_is(16), unique] + unsigned char* AccessToken, + [in] long lFlags, + [in] IWbemContext* pCtx, + [out] IWbemServices** ppNamespace + ); + + + WERROR NTLMLogin( + [in,unique,string,charset(UTF16)] uint16 *wszNetworkResource, + [in,unique,string,charset(UTF16)] uint16 *wszPreferredLocale, + [in] long lFlags, + [in,unique] IWbemContext* pCtx, + [out,ref] IWbemServices** ppNamespace + ); } @@ -780,61 +685,61 @@ interface IWbemClassObject : IUnknown pointer_default(unique) ] interface IWbemWCOSmartEnum : IUnknown { - typedef struct { - uint32 size; - char data[size]; - } WBEMDATA; - - typedef enum { - WTYPE_SCHEMA = 1, - WTYPE_CLASS = 2, - WTYPE_OBJECT = 3 - } WTYPES; - - typedef [relative_base] struct { -// [relative] WBEMDATA4 *data; /* 0x9 */ - uint32 data_size; - uint8 wtype; - } WBEMDATA4; - - typedef [relative_base] struct { - [relative] WBEMDATA4 *data; /* 0x9 */ - uint32 data_size; - uint8 wtype; - } WBEMDATA3; - - typedef [relative_base] struct { - [relative,size_is(obj_num)] WBEMDATA3 *data; /* 0x8 */ - uint32 data_size; - uint32 obj_num; - } WBEMDATA2; - - typedef [relative_base] struct { - [relative] WBEMDATA2 *data; /* 0x8 */ - uint32 data_size; - } WBEMDATA1; - - typedef [relative_base] struct { - uint32 u1_0; /* 0 */ - hyper signature; /* 'WBEMDATA' */ - [relative] WBEMDATA1 *data; /* 0x1A */ - uint32 data_size; - uint32 u2_0; /* 0 */ - uint8 ver_major; /* 1 */ - uint8 ver_minor; /* 0 - Win2000, 1 - WinXP/2003 */ - } WBEMDATA0; - - WERROR IWbemWCOSmartEnum_Next( - [in,ref] GUID *gEWCO, - [in] uint32 lTimeOut, - [in] uint32 uCount, -// [in] uint32 unknown, -// [in,ref] GUID *gWCO, - [out,ref] uint32 *puReturned, - [out,ref] uint32 *pSize, -// [out,ref] WBEMDATA0 **pData - [out,ref,noprint,size_is(,*pSize)] uint8 **pData - ); + typedef struct { + uint32 size; + char data[size]; + } WBEMDATA; + + typedef enum { + WTYPE_SCHEMA = 1, + WTYPE_CLASS = 2, + WTYPE_OBJECT = 3 + } WTYPES; + + typedef [relative_base] struct { + // [relative] WBEMDATA4 *data; /* 0x9 */ + uint32 data_size; + uint8 wtype; + } WBEMDATA4; + + typedef [relative_base] struct { + [relative] WBEMDATA4 *data; /* 0x9 */ + uint32 data_size; + uint8 wtype; + } WBEMDATA3; + + typedef [relative_base] struct { + [relative,size_is(obj_num)] WBEMDATA3 *data; /* 0x8 */ + uint32 data_size; + uint32 obj_num; + } WBEMDATA2; + + typedef [relative_base] struct { + [relative] WBEMDATA2 *data; /* 0x8 */ + uint32 data_size; + } WBEMDATA1; + + typedef [relative_base] struct { + uint32 u1_0; /* 0 */ + hyper signature; /* 'WBEMDATA' */ + [relative] WBEMDATA1 *data; /* 0x1A */ + uint32 data_size; + uint32 u2_0; /* 0 */ + uint8 ver_major; /* 1 */ + uint8 ver_minor; /* 0 - Win2000, 1 - WinXP/2003 */ + } WBEMDATA0; + + WERROR IWbemWCOSmartEnum_Next( + [in,ref] GUID *gEWCO, + [in] uint32 lTimeOut, + [in] uint32 uCount, + // [in] uint32 unknown, + // [in,ref] GUID *gWCO, + [out,ref] uint32 *puReturned, + [out,ref] uint32 *pSize, + // [out,ref] WBEMDATA0 **pData + [out,ref,noprint,size_is(,*pSize)] uint8 **pData + ); } [ @@ -843,39 +748,55 @@ interface IWbemClassObject : IUnknown pointer_default(unique) ] interface IWbemFetchSmartEnum : IUnknown { - WERROR Fetch( - [out] IWbemWCOSmartEnum** ppEnum - ); - WERROR Test( - [out] WbemClassObject** ppEnum - ); + WERROR Fetch([out] IWbemWCOSmartEnum** ppEnum); + WERROR Test([out] WbemClassObject** ppEnum); } [ object, -// restricted, + // restricted, uuid(44aca675-e8fc-11d0-a07c-00c04fb68820) ] interface IWbemCallResult : IUnknown { - WERROR GetResultObject( - [in] long lTimeout, - [out] IUnknown** ppResultObject -// [out] IWbemClassObject** ppResultObject - ); - - WERROR GetResultString( - [in] long lTimeout -// [out] BSTR* pstrResultString - ); + WERROR GetResultObject( + [in] long lTimeout, + [out] IUnknown** ppResultObject + [out] IWbemClassObject** ppResultObject + ); + + WERROR GetResultString( + [in] long lTimeout + [out] BSTR* pstrResultString + ); + + WERROR GetResultServices( + [in] long lTimeout, + [out] IWbemServices** ppServices + ); + + WERROR GetCallStatus( + [in] long lTimeout, + [out] long* plStatus + ); +} - WERROR GetResultServices( - [in] long lTimeout, - [out] IWbemServices** ppServices - ); - WERROR GetCallStatus( - [in] long lTimeout, - [out] long* plStatus - ); -} +[ + object, + restricted, + uuid(7c857801-7381-11cf-884d-00aa004b2e24) +] +interface IWbemObjectSink : IUnknown +{ + WERROR SetStatus( + [in] long lFlags, + [in] WERROR hResult, + [in] BSTR strParam, + [in] IWbemClassObject* pObjParam + ); + WERROR Indicate( + [in] long lObjectCount, + [in, size_is(lObjectCount)] IWbemClassObject** apObjArray + ); +}; diff --git a/source4/librpc/rpc/dcerpc.h b/source4/librpc/rpc/dcerpc.h index 1fd56cb052..2b38c65669 100644 --- a/source4/librpc/rpc/dcerpc.h +++ b/source4/librpc/rpc/dcerpc.h @@ -375,4 +375,6 @@ NTSTATUS dcerpc_request(struct dcerpc_pipe *p, typedef NTSTATUS (*dcerpc_call_fn) (struct dcerpc_pipe *, TALLOC_CTX *, void *); +enum dcerpc_transport_t dcerpc_transport_by_endpoint_protocol(int prot); + #endif /* __DCERPC_H__ */ diff --git a/source4/pidl/idl.yp b/source4/pidl/idl.yp index 8589982a2c..d557590494 100644 --- a/source4/pidl/idl.yp +++ b/source4/pidl/idl.yp @@ -276,11 +276,16 @@ element_list1: | element_list1 base_element ';' { push(@{$_[1]}, $_[2]); $_[1] } ; +optional_const: + #empty + | 'const' +; + element_list2: #empty | 'void' - | base_element { [ $_[1] ] } - | element_list2 ',' base_element { push(@{$_[1]}, $_[3]); $_[1] } + | optional_const base_element { [ $_[2] ] } + | element_list2 ',' optional_const base_element { push(@{$_[1]}, $_[4]); $_[1] } ; array_len: |