ReactOS 0.4.16-dev-297-gc569aee
hnetcfg_private.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Enumerations

enum  type_id {
  INetFwAuthorizedApplication_tid , INetFwAuthorizedApplications_tid , INetFwMgr_tid , INetFwOpenPort_tid ,
  INetFwOpenPorts_tid , INetFwPolicy_tid , INetFwPolicy2_tid , INetFwProfile_tid ,
  INetFwRules_tid , IUPnPNAT_tid , last_tid , ISWbemLocator_tid ,
  ISWbemObject_tid , ISWbemObjectSet_tid , ISWbemProperty_tid , ISWbemPropertySet_tid ,
  ISWbemServices_tid , ISWbemSecurity_tid , last_tid , IWinHttpRequest_tid ,
  last_tid
}
 

Functions

HRESULT get_typeinfo (enum type_id, ITypeInfo **) DECLSPEC_HIDDEN
 
void release_typelib (void) DECLSPEC_HIDDEN
 
HRESULT NetFwMgr_create (IUnknown *, LPVOID *) DECLSPEC_HIDDEN
 
HRESULT NetFwPolicy_create (IUnknown *, LPVOID *) DECLSPEC_HIDDEN
 
HRESULT NetFwPolicy2_create (IUnknown *, void **) DECLSPEC_HIDDEN
 
HRESULT NetFwProfile_create (IUnknown *, LPVOID *) DECLSPEC_HIDDEN
 
HRESULT NetFwAuthorizedApplication_create (IUnknown *, LPVOID *) DECLSPEC_HIDDEN
 
HRESULT NetFwAuthorizedApplications_create (IUnknown *, LPVOID *) DECLSPEC_HIDDEN
 
HRESULT NetFwOpenPorts_create (IUnknown *, LPVOID *) DECLSPEC_HIDDEN
 
HRESULT NetFwOpenPort_create (IUnknown *, LPVOID *) DECLSPEC_HIDDEN
 
HRESULT NetFwServices_create (IUnknown *, LPVOID *) DECLSPEC_HIDDEN
 
HRESULT IUPnPNAT_create (IUnknown *, void **) DECLSPEC_HIDDEN
 

Enumeration Type Documentation

◆ type_id

Enumerator
INetFwAuthorizedApplication_tid 
INetFwAuthorizedApplications_tid 
INetFwMgr_tid 
INetFwOpenPort_tid 
INetFwOpenPorts_tid 
INetFwPolicy_tid 
INetFwPolicy2_tid 
INetFwProfile_tid 
INetFwRules_tid 
IUPnPNAT_tid 
last_tid 
ISWbemLocator_tid 
ISWbemObject_tid 
ISWbemObjectSet_tid 
ISWbemProperty_tid 
ISWbemPropertySet_tid 
ISWbemServices_tid 
ISWbemSecurity_tid 
last_tid 
IWinHttpRequest_tid 
last_tid 

Definition at line 21 of file hnetcfg_private.h.

22{
34};
@ INetFwOpenPort_tid
@ INetFwPolicy2_tid
@ INetFwPolicy_tid
@ INetFwRules_tid
@ last_tid
@ INetFwAuthorizedApplications_tid
@ INetFwAuthorizedApplication_tid
@ INetFwMgr_tid
@ INetFwOpenPorts_tid
@ INetFwProfile_tid
@ IUPnPNAT_tid

Function Documentation

◆ get_typeinfo()

HRESULT get_typeinfo ( enum  type_id,
ITypeInfo **  ret 
)

Definition at line 124 of file apps.c.

125{
126 HRESULT hr;
127
128 if (!typelib)
129 {
130 ITypeLib *lib;
131
132 hr = LoadRegTypeLib( &LIBID_NetFwPublicTypeLib, 1, 0, LOCALE_SYSTEM_DEFAULT, &lib );
133 if (FAILED(hr))
134 {
135 ERR("LoadRegTypeLib failed: %08x\n", hr);
136 return hr;
137 }
138 if (InterlockedCompareExchangePointer( (void **)&typelib, lib, NULL ))
139 ITypeLib_Release( lib );
140 }
141 if (!typeinfo[tid])
142 {
144
145 hr = ITypeLib_GetTypeInfoOfGuid( typelib, tid_id[tid], &info );
146 if (FAILED(hr))
147 {
148 ERR("GetTypeInfoOfGuid(%s) failed: %08x\n", debugstr_guid(tid_id[tid]), hr);
149 return hr;
150 }
152 ITypeInfo_Release( info );
153 }
154 *ret = typeinfo[tid];
155 ITypeInfo_AddRef(typeinfo[tid]);
156 return S_OK;
157}
#define ERR(fmt,...)
Definition: precomp.h:57
#define NULL
Definition: types.h:112
HRESULT WINAPI LoadRegTypeLib(REFGUID rguid, WORD wVerMajor, WORD wVerMinor, LCID lcid, ITypeLib **ppTLib)
Definition: typelib.c:531
#define InterlockedCompareExchangePointer
Definition: interlocked.h:129
#define S_OK
Definition: intsafe.h:52
#define FAILED(hr)
Definition: intsafe.h:51
#define debugstr_guid
Definition: kernel32.h:35
static TfClientId tid
#define LOCALE_SYSTEM_DEFAULT
HRESULT hr
Definition: shlfolder.c:183
int ret

Referenced by dictionary_GetIDsOfNames(), dictionary_GetTypeInfo(), dictionary_Invoke(), drive_GetIDsOfNames(), drive_GetTypeInfo(), drive_Invoke(), drivecoll_GetIDsOfNames(), drivecoll_GetTypeInfo(), drivecoll_Invoke(), file_GetIDsOfNames(), file_GetTypeInfo(), file_Invoke(), filecoll_GetIDsOfNames(), filecoll_GetTypeInfo(), filecoll_Invoke(), filesys_GetIDsOfNames(), filesys_GetTypeInfo(), filesys_Invoke(), folder_GetIDsOfNames(), folder_GetTypeInfo(), folder_Invoke(), foldercoll_GetIDsOfNames(), foldercoll_GetTypeInfo(), foldercoll_Invoke(), fw_app_GetIDsOfNames(), fw_app_GetTypeInfo(), fw_app_Invoke(), fw_apps_GetIDsOfNames(), fw_apps_GetTypeInfo(), fw_apps_Invoke(), fw_manager_GetIDsOfNames(), fw_manager_GetTypeInfo(), fw_manager_Invoke(), fw_policy_GetIDsOfNames(), fw_policy_GetTypeInfo(), fw_policy_Invoke(), fw_port_GetIDsOfNames(), fw_port_GetTypeInfo(), fw_port_Invoke(), fw_ports_GetIDsOfNames(), fw_ports_GetTypeInfo(), fw_ports_Invoke(), fw_profile_GetIDsOfNames(), fw_profile_GetTypeInfo(), fw_profile_Invoke(), fwpolicy2_GetIDsOfNames(), fwpolicy2_GetTypeInfo(), fwpolicy2_Invoke(), InternetExplorer_GetIDsOfNames(), InternetExplorer_GetTypeInfo(), InternetExplorer_Invoke(), MsiActiveScriptSite_GetItemInfo(), netfw_rules_GetIDsOfNames(), netfw_rules_GetTypeInfo(), netfw_rules_Invoke(), ProvideClassInfo_GetClassInfo(), textstream_GetIDsOfNames(), textstream_GetTypeInfo(), textstream_Invoke(), upnpnat_GetIDsOfNames(), upnpnat_GetTypeInfo(), upnpnat_Invoke(), VBSAXAttributes_GetIDsOfNames(), VBSAXAttributes_GetTypeInfo(), VBSAXAttributes_Invoke(), WebBrowser_GetIDsOfNames(), WebBrowser_GetTypeInfo(), WebBrowser_Invoke(), WshCollection_GetIDsOfNames(), WshCollection_GetTypeInfo(), WshCollection_Invoke(), WshEnvironment_GetIDsOfNames(), WshEnvironment_GetTypeInfo(), WshEnvironment_Invoke(), WshExec_GetIDsOfNames(), WshExec_GetTypeInfo(), WshExec_Invoke(), WshShell3_GetIDsOfNames(), WshShell3_GetTypeInfo(), WshShell3_Invoke(), WshShortcut_GetIDsOfNames(), WshShortcut_GetTypeInfo(), and WshShortcut_Invoke().

◆ IUPnPNAT_create()

HRESULT IUPnPNAT_create ( IUnknown outer,
void **  object 
)

Definition at line 759 of file port.c.

760{
761 upnpnat *nat;
762
763 TRACE("(%p,%p)\n", outer, object);
764
765 nat = heap_alloc( sizeof(*nat) );
766 if (!nat) return E_OUTOFMEMORY;
767
768 nat->IUPnPNAT_iface.lpVtbl = &upnpnat_vtbl;
769 nat->ref = 1;
770
771 *object = &nat->IUPnPNAT_iface;
772
773 TRACE("returning iface %p\n", *object);
774 return S_OK;
775}
static void * heap_alloc(size_t len)
Definition: appwiz.h:66
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
static const IUPnPNATVtbl upnpnat_vtbl
Definition: port.c:744
#define TRACE(s)
Definition: solgame.cpp:4
Definition: port.c:608
LONG ref
Definition: port.c:610
IUPnPNAT IUPnPNAT_iface
Definition: port.c:609

◆ NetFwAuthorizedApplication_create()

HRESULT NetFwAuthorizedApplication_create ( IUnknown pUnkOuter,
LPVOID ppObj 
)

Definition at line 432 of file apps.c.

433{
434 fw_app *fa;
435
436 TRACE("(%p,%p)\n", pUnkOuter, ppObj);
437
438 fa = HeapAlloc( GetProcessHeap(), 0, sizeof(*fa) );
439 if (!fa) return E_OUTOFMEMORY;
440
441 fa->INetFwAuthorizedApplication_iface.lpVtbl = &fw_app_vtbl;
442 fa->refs = 1;
443 fa->filename = NULL;
444
445 *ppObj = &fa->INetFwAuthorizedApplication_iface;
446
447 TRACE("returning iface %p\n", *ppObj);
448 return S_OK;
449}
static const struct INetFwAuthorizedApplicationVtbl fw_app_vtbl
Definition: apps.c:409
#define GetProcessHeap()
Definition: compat.h:736
#define HeapAlloc
Definition: compat.h:733
f_args fa
Definition: format.c:280
Definition: apps.c:41

Referenced by fw_apps_Item().

◆ NetFwAuthorizedApplications_create()

HRESULT NetFwAuthorizedApplications_create ( IUnknown pUnkOuter,
LPVOID ppObj 
)

Definition at line 645 of file apps.c.

646{
647 fw_apps *fa;
648
649 TRACE("(%p,%p)\n", pUnkOuter, ppObj);
650
651 fa = HeapAlloc( GetProcessHeap(), 0, sizeof(*fa) );
652 if (!fa) return E_OUTOFMEMORY;
653
654 fa->INetFwAuthorizedApplications_iface.lpVtbl = &fw_apps_vtbl;
655 fa->refs = 1;
656
657 *ppObj = &fa->INetFwAuthorizedApplications_iface;
658
659 TRACE("returning iface %p\n", *ppObj);
660 return S_OK;
661}
static const struct INetFwAuthorizedApplicationsVtbl fw_apps_vtbl
Definition: apps.c:629
Definition: apps.c:451

Referenced by fw_profile_get_AuthorizedApplications().

◆ NetFwMgr_create()

HRESULT NetFwMgr_create ( IUnknown pUnkOuter,
LPVOID ppObj 
)

Definition at line 241 of file manager.c.

242{
243 fw_manager *fm;
244
245 TRACE("(%p,%p)\n", pUnkOuter, ppObj);
246
247 fm = HeapAlloc( GetProcessHeap(), 0, sizeof(*fm) );
248 if (!fm) return E_OUTOFMEMORY;
249
250 fm->INetFwMgr_iface.lpVtbl = &fw_manager_vtbl;
251 fm->refs = 1;
252
253 *ppObj = &fm->INetFwMgr_iface;
254
255 TRACE("returning iface %p\n", *ppObj);
256 return S_OK;
257}
static const struct INetFwMgrVtbl fw_manager_vtbl
Definition: manager.c:225
LONG refs
Definition: manager.c:38
INetFwMgr INetFwMgr_iface
Definition: manager.c:37

◆ NetFwOpenPort_create()

HRESULT NetFwOpenPort_create ( IUnknown pUnkOuter,
LPVOID ppObj 
)

Definition at line 360 of file port.c.

361{
362 fw_port *fp;
363
364 TRACE("(%p,%p)\n", pUnkOuter, ppObj);
365
366 fp = HeapAlloc( GetProcessHeap(), 0, sizeof(*fp) );
367 if (!fp) return E_OUTOFMEMORY;
368
370 fp->refs = 1;
371 fp->name = NULL;
373 fp->port = 0;
374
375 *ppObj = &fp->INetFwOpenPort_iface;
376
377 TRACE("returning iface %p\n", *ppObj);
378 return S_OK;
379}
static const struct INetFwOpenPortVtbl fw_port_vtbl
Definition: port.c:334
@ NET_FW_IP_PROTOCOL_TCP
Definition: icftypes.idl:75
Definition: port.c:38
INetFwOpenPort INetFwOpenPort_iface
Definition: port.c:39
LONG port
Definition: port.c:43
BSTR name
Definition: port.c:41
LONG refs
Definition: port.c:40
NET_FW_IP_PROTOCOL protocol
Definition: port.c:42

Referenced by fw_ports_Item().

◆ NetFwOpenPorts_create()

HRESULT NetFwOpenPorts_create ( IUnknown pUnkOuter,
LPVOID ppObj 
)

Definition at line 589 of file port.c.

590{
591 fw_ports *fp;
592
593 TRACE("(%p,%p)\n", pUnkOuter, ppObj);
594
595 fp = HeapAlloc( GetProcessHeap(), 0, sizeof(*fp) );
596 if (!fp) return E_OUTOFMEMORY;
597
599 fp->refs = 1;
600
601 *ppObj = &fp->INetFwOpenPorts_iface;
602
603 TRACE("returning iface %p\n", *ppObj);
604 return S_OK;
605}
static const struct INetFwOpenPortsVtbl fw_ports_vtbl
Definition: port.c:573
Definition: port.c:382
LONG refs
Definition: port.c:384
INetFwOpenPorts INetFwOpenPorts_iface
Definition: port.c:383

Referenced by fw_profile_get_GloballyOpenPorts(), and fw_service_get_GloballyOpenPorts().

◆ NetFwPolicy2_create()

HRESULT NetFwPolicy2_create ( IUnknown outer,
void **  obj 
)

Definition at line 769 of file policy.c.

770{
771 fw_policy2 *fp;
772
773 TRACE("(%p,%p)\n", outer, obj);
774
775 fp = HeapAlloc( GetProcessHeap(), 0, sizeof(*fp) );
776 if (!fp) return E_OUTOFMEMORY;
777
779 fp->refs = 1;
780
781 *obj = &fp->INetFwPolicy2_iface;
782
784 {
785 HeapFree( GetProcessHeap(), 0, fp );
786 return E_OUTOFMEMORY;
787 }
788
789 TRACE("returning iface %p\n", *obj);
790 return S_OK;
791}
#define HeapFree(x, y, z)
Definition: compat.h:735
static const struct INetFwPolicy2Vtbl fw_policy2_vtbl
Definition: policy.c:736
static HRESULT create_INetFwRules(INetFwRules **object)
Definition: policy.c:266
INetFwRules * fw_policy2_rules
Definition: policy.c:49
LONG refs
Definition: policy.c:50
INetFwPolicy2 INetFwPolicy2_iface
Definition: policy.c:48

◆ NetFwPolicy_create()

HRESULT NetFwPolicy_create ( IUnknown pUnkOuter,
LPVOID ppObj 
)

Definition at line 436 of file policy.c.

437{
438 fw_policy *fp;
439
440 TRACE("(%p,%p)\n", pUnkOuter, ppObj);
441
442 fp = HeapAlloc( GetProcessHeap(), 0, sizeof(*fp) );
443 if (!fp) return E_OUTOFMEMORY;
444
446 fp->refs = 1;
447
448 *ppObj = &fp->INetFwPolicy_iface;
449
450 TRACE("returning iface %p\n", *ppObj);
451 return S_OK;
452}
static const struct INetFwPolicyVtbl fw_policy_vtbl
Definition: policy.c:423
LONG refs
Definition: policy.c:38
INetFwPolicy INetFwPolicy_iface
Definition: policy.c:37

Referenced by fw_manager_get_LocalPolicy().

◆ NetFwProfile_create()

HRESULT NetFwProfile_create ( IUnknown pUnkOuter,
LPVOID ppObj 
)

Definition at line 331 of file profile.c.

332{
333 fw_profile *fp;
334
335 TRACE("(%p,%p)\n", pUnkOuter, ppObj);
336
337 fp = HeapAlloc( GetProcessHeap(), 0, sizeof(*fp) );
338 if (!fp) return E_OUTOFMEMORY;
339
341 fp->refs = 1;
342
343 *ppObj = &fp->INetFwProfile_iface;
344
345 TRACE("returning iface %p\n", *ppObj);
346 return S_OK;
347}
static const struct INetFwProfileVtbl fw_profile_vtbl
Definition: profile.c:306
LONG refs
Definition: profile.c:38
INetFwProfile INetFwProfile_iface
Definition: profile.c:37

Referenced by fw_policy_get_CurrentProfile().

◆ NetFwServices_create()

HRESULT NetFwServices_create ( IUnknown pUnkOuter,
LPVOID ppObj 
)

Definition at line 461 of file service.c.

462{
463 fw_services *fp;
464
465 TRACE("(%p,%p)\n", pUnkOuter, ppObj);
466
467 fp = HeapAlloc( GetProcessHeap(), 0, sizeof(*fp) );
468 if (!fp) return E_OUTOFMEMORY;
469
471 fp->refs = 1;
472
473 *ppObj = &fp->INetFwServices_iface;
474
475 TRACE("returning iface %p\n", *ppObj);
476 return S_OK;
477}
static const struct INetFwServicesVtbl fw_services_vtbl
Definition: service.c:447
INetFwServices INetFwServices_iface
Definition: service.c:307
LONG refs
Definition: service.c:308

Referenced by fw_profile_get_Services().

◆ release_typelib()

void release_typelib ( void  )

Definition at line 159 of file apps.c.

160{
161 unsigned i;
162
163 for (i = 0; i < ARRAY_SIZE(typeinfo); i++)
164 if (typeinfo[i])
165 ITypeInfo_Release(typeinfo[i]);
166
167 if (typelib)
168 ITypeLib_Release(typelib);
169}
#define ARRAY_SIZE(A)
Definition: main.h:20
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248