37static const WCHAR currentlevelW[] = {
'C',
'u',
'r',
'r',
'e',
'n',
't',
'L',
'e',
'v',
'e',
'l',0};
38static const WCHAR descriptionW[] = {
'D',
'e',
's',
'c',
'r',
'i',
'p',
't',
'i',
'o',
'n',0};
39static const WCHAR displaynameW[] = {
'D',
'i',
's',
'p',
'l',
'a',
'y',
'N',
'a',
'm',
'e',0};
44static const WCHAR recommendedlevelW[] = {
'R',
'e',
'c',
'o',
'm',
'm',
'e',
'n',
'd',
'e',
'd',
45 'L',
'e',
'v',
'e',
'l',0};
47 'M',
'i',
'c',
'r',
'o',
's',
'o',
'f',
't',
'\\',
48 'W',
'i',
'n',
'd',
'o',
'w',
's',
'\\',
49 'C',
'u',
'r',
'r',
'e',
'n',
't',
'V',
'e',
'r',
's',
'i',
'o',
'n',
'\\',
50 'I',
'n',
't',
'e',
'r',
'n',
'e',
't',
' ',
'S',
'e',
't',
't',
'i',
'n',
'g',
's',
'\\',
51 'Z',
'o',
'n',
'e',
's',
'\\',0};
53 'M',
'i',
'c',
'r',
'o',
's',
'o',
'f',
't',
'\\',
54 'W',
'i',
'n',
'd',
'o',
'w',
's',
'\\',
55 'C',
'u',
'r',
'r',
'e',
'n',
't',
'V',
'e',
'r',
's',
'i',
'o',
'n',
'\\',
56 'I',
'n',
't',
'e',
'r',
'n',
'e',
't',
' ',
'S',
'e',
't',
't',
'i',
'n',
'g',
's',
'\\',
57 'Z',
'o',
'n',
'e',
'M',
'a',
'p',0};
59 'M',
'i',
'c',
'r',
'o',
's',
'o',
'f',
't',
'\\',
60 'W',
'i',
'n',
'd',
'o',
'w',
's',
'\\',
61 'C',
'u',
'r',
'r',
'e',
'n',
't',
'V',
'e',
'r',
's',
'i',
'o',
'n',
'\\',
62 'I',
'n',
't',
'e',
'r',
'n',
'e',
't',
' ',
'S',
'e',
't',
't',
'i',
'n',
'g',
's',
'\\',
63 'Z',
'o',
'n',
'e',
'M',
'a',
'p',
'\\',
64 'D',
'o',
'm',
'a',
'i',
'n',
's',0};
137 static const WCHAR wszZoneMapProtocolKey[] =
138 {
'S',
'o',
'f',
't',
'w',
'a',
'r',
'e',
'\\',
139 'M',
'i',
'c',
'r',
'o',
's',
'o',
'f',
't',
'\\',
140 'W',
'i',
'n',
'd',
'o',
'w',
's',
'\\',
141 'C',
'u',
'r',
'r',
'e',
'n',
't',
'V',
'e',
'r',
's',
'i',
'o',
'n',
'\\',
142 'I',
'n',
't',
'e',
'r',
'n',
'e',
't',
' ',
'S',
'e',
't',
't',
'i',
'n',
'g',
's',
'\\',
143 'Z',
'o',
'n',
'e',
'M',
'a',
'p',
'\\',
144 'P',
'r',
'o',
't',
'o',
'c',
'o',
'l',
'D',
'e',
'f',
'a',
'u',
'l',
't',
's',0};
148 ERR(
"Could not open key %s\n",
debugstr_w(wszZoneMapProtocolKey));
160 ERR(
"Could not open key %s\n",
debugstr_w(wszZoneMapProtocolKey));
219 if (
ptr ==
str || implicit_wildcard) {
224 }
else if(implicit_wildcard &&
str_len > pattern_len) {
258 TRACE(
"No match found\n");
320 DWORD subdomain_count, subdomain_len;
333 if(subdomain_count) {
351 for(
i = 0;
i < subdomain_count; ++
i) {
353 const WCHAR *sub_matched;
368 ERR(
"Unable to open subdomain key %s of %s: %d\n",
debugstr_w(subdomain),
377 check_domain =
FALSE;
408 if(check_domain && !domain_offset && !
wcschr(
host, matched-
host-1))
420 DWORD domain_count, domain_len,
i;
427 WARN(
"Failed to retrieve information about key\n");
438 for(
i = 0;
i < domain_count; ++
i) {
464 hres = IUri_GetScheme(
uri, &scheme_type);
483 *
zone = URLZONE_INVALID;
525 *
zone = URLZONE_INVALID;
562 *
zone = URLZONE_LOCAL_MACHINE;
566 *
zone = URLZONE_INTERNET;
570 FIXME(
"unsupported drive type %d\n",
type);
576 if(*
zone == URLZONE_INVALID) {
592 *
zone = URLZONE_INVALID;
605 hres =
CreateUri(secur_url, Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, 0, &secur_uri);
612 IUri_Release(secur_uri);
617 *ret_url = secur_url;
633 IUri_Release(secur_uri);
635 *ret_uri = secur_uri;
642 static const WCHAR wszFormat[] = {
'%',
's',
'%',
'u',0};
652 WARN(
"RegOpenKey failed\n");
667 case URLACTION_SCRIPT_OVERRIDE_SAFETY:
668 case URLACTION_ACTIVEX_OVERRIDE_SCRIPT_SAFETY:
674 case URLZONEREG_DEFAULT:
675 case URLZONEREG_HKCU:
678 case URLZONEREG_HKLM:
682 WARN(
"Unknown URLZONEREG: %d\n", zone_reg);
688 WCHAR action_str[16];
691 static const WCHAR formatW[] = {
'%',
'X',0};
701 ERR(
"RegQueryValue failed: %d\n",
res);
708 if(
FAILED(
hres) && zone_reg == URLZONEREG_DEFAULT)
720 if(
zone == URLZONE_INVALID)
723 hres = IUri_GetScheme(
uri, &scheme_type);
731 hres = IUri_GetDisplayUri(
uri, &display_uri);
737 if(
len+
sizeof(
DWORD) > *secid_len) {
748 DWORD host_len, scheme_len;
770 len = host_len+scheme_len+
sizeof(
BYTE);
772 if(
len+
sizeof(
DWORD) > *secid_len) {
808 hres =
CreateUri(secur_url, Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, 0, &
uri);
830 IUri_Release(secur_uri);
873 IInternetSecurityManagerEx2_AddRef(iface);
897 IInternetSecurityMgrSite_Release(
This->mgrsite);
898 if(
This->custom_manager)
899 IInternetSecurityManager_Release(
This->custom_manager);
917 IInternetSecurityMgrSite_Release(
This->mgrsite);
919 if(
This->custom_manager) {
920 IInternetSecurityManager_Release(
This->custom_manager);
924 This->mgrsite = pSite;
930 IInternetSecurityMgrSite_AddRef(pSite);
932 hres = IInternetSecurityMgrSite_QueryInterface(pSite, &IID_IServiceProvider,
935 IServiceProvider_QueryService(servprov, &SID_SInternetSecurityManager,
936 &IID_IInternetSecurityManager, (
void**)&
This->custom_manager);
937 IServiceProvider_Release(servprov);
955 IInternetSecurityMgrSite_AddRef(
This->mgrsite);
957 *ppSite =
This->mgrsite;
970 if(
This->custom_manager) {
971 hres = IInternetSecurityManager_MapUrlToZone(
This->custom_manager,
973 if(
hres != INET_E_DEFAULT_ACTION)
978 *pdwZone = URLZONE_INVALID;
993 TRACE(
"(%p)->(%s %p %p %08lx)\n", iface,
debugstr_w(pwszUrl), pbSecurityId,
996 if(
This->custom_manager) {
999 hres = IInternetSecurityManager_GetSecurityId(
This->custom_manager,
1000 pwszUrl, pbSecurityId, pcbSecurityId,
dwReserved);
1001 if(
hres != INET_E_DEFAULT_ACTION)
1005 if(!pwszUrl || !pbSecurityId || !pcbSecurityId)
1009 FIXME(
"dwReserved is not supported\n");
1025 TRACE(
"(%p)->(%s %08x %p %08x %p %08x %08x %08x)\n", iface,
debugstr_w(pwszUrl), dwAction,
1028 if(
This->custom_manager) {
1029 hres = IInternetSecurityManager_ProcessUrlAction(
This->custom_manager, pwszUrl, dwAction,
1031 if(
hres != INET_E_DEFAULT_ACTION)
1036 FIXME(
"Unsupported arguments\n");
1050 if(cbPolicy >=
sizeof(
DWORD))
1053 switch(GetUrlPolicyPermissions(
policy)) {
1054 case URLPOLICY_ALLOW:
1055 case URLPOLICY_CHANNEL_SOFTDIST_PRECACHE:
1057 case URLPOLICY_DISALLOW:
1059 case URLPOLICY_QUERY:
1060 FIXME(
"URLPOLICY_QUERY not implemented\n");
1080 ppPolicy, pcbPolicy, pContext, cbContext,
dwReserved);
1082 if(
This->custom_manager) {
1083 hres = IInternetSecurityManager_QueryCustomPolicy(
This->custom_manager, pwszUrl, guidKey,
1084 ppPolicy, pcbPolicy, pContext, cbContext,
dwReserved);
1085 if(
hres != INET_E_DEFAULT_ACTION)
1101 if(
This->custom_manager) {
1102 hres = IInternetSecurityManager_SetZoneMapping(
This->custom_manager, dwZone,
1104 if(
hres != INET_E_DEFAULT_ACTION)
1108 FIXME(
"Default action is not implemented\n");
1118 TRACE(
"(%p)->(%08x %p %08x)\n", iface, dwZone, ppenumString,
dwFlags);
1120 if(
This->custom_manager) {
1121 hres = IInternetSecurityManager_GetZoneMappings(
This->custom_manager, dwZone,
1123 if(
hres != INET_E_DEFAULT_ACTION)
1127 FIXME(
"Default action is not implemented\n");
1136 FIXME(
"(%p)->(%s %08x %p %d %p %d %08x %08x %p) stub\n",
This,
debugstr_w(pwszUrl), dwAction, pPolicy, cbPolicy,
1146 TRACE(
"(%p)->(%p %p %08x %p %p)\n",
This, pUri, pdwZone,
dwFlags, ppwszMappedUrl, pdwOutFlags);
1148 if(
This->custom_manager) {
1152 hres = IInternetSecurityManager_QueryInterface(
This->custom_manager, &IID_IInternetSecurityManagerEx2,
1155 hres = IInternetSecurityManagerEx2_MapUrlToZoneEx2(sec_mgr2, pUri, pdwZone,
dwFlags, ppwszMappedUrl, pdwOutFlags);
1156 IInternetSecurityManagerEx2_Release(sec_mgr2);
1160 hres = IUri_GetDisplayUri(pUri, &
url);
1164 hres = IInternetSecurityManager_MapUrlToZone(
This->custom_manager,
url, pdwZone,
dwFlags);
1168 if(
hres != INET_E_DEFAULT_ACTION)
1176 *pdwZone = URLZONE_INVALID;
1191 FIXME(
"(%p)->(%p %08x %p %d %p %d %08x %08x %p) stub\n",
This, pUri, dwAction, pPolicy,
1203 FIXME(
"dwReserved is not supported yet\n");
1205 if(!pUri || !pcbSecurityId || !pbSecurityId)
1245 TRACE(
"(%p,%p)\n",pUnkOuter,ppobj);
1290 DWORD allocated = 6;
1311 if (
used == allocated) {
1315 new_data = heap_realloc_zero(
data, allocated *
sizeof(
DWORD));
1366 IInternetZoneManagerEx2_AddRef(iface);
1378 TRACE(
"(%p)->(ref before=%u)\n",
This, refCount - 1);
1391 TRACE(
"(%p)->(ref before=%u)\n",
This, refCount + 1);
1408 ZONEATTRIBUTES* pZoneAttributes)
1415 TRACE(
"(%p)->(%d %p)\n",
This, dwZone, pZoneAttributes);
1417 if (!pZoneAttributes)
1426 TRACE(
"Zone %d not in HKLM\n", dwZone);
1446 ZONEATTRIBUTES* pZoneAttributes)
1452 TRACE(
"(%p)->(%d %p)\n",
This, dwZone, pZoneAttributes);
1454 if (!pZoneAttributes)
1463 (
lstrlenW(pZoneAttributes->szDisplayName)+1)*
sizeof(
WCHAR));
1466 (
lstrlenW(pZoneAttributes->szDescription)+1)*
sizeof(
WCHAR));
1472 (
const BYTE*) &pZoneAttributes->dwTemplateMinLevel,
sizeof(
DWORD));
1475 (
const BYTE*) &pZoneAttributes->dwTemplateCurrentLevel,
sizeof(
DWORD));
1478 (
const BYTE*) &pZoneAttributes->dwTemplateRecommended,
sizeof(
DWORD));
1494 URLZONEREG ulrZoneReg)
1497 ppPolicy, pcbPolicy, ulrZoneReg);
1509 URLZONEREG ulrZoneReg)
1512 ppPolicy, cbPolicy, ulrZoneReg);
1522 TRACE(
"(%p)->(%d %08x %p %d %d)\n", iface, dwZone, dwAction, pPolicy,
1523 cbPolicy, urlZoneReg);
1539 URLZONEREG urlZoneReg)
1541 FIXME(
"(%p)->(%08x %08x %p %08x %08x) stub\n", iface, dwZone, dwAction, pPolicy,
1542 cbPolicy, urlZoneReg);
1554 DWORD dwPromptFlags)
1570 FIXME(
"(%p)->(%08x %s %s %08x) stub\n", iface, dwAction,
debugstr_w(pwszUrl),
1589 if (!pdwEnum || !pdwCount || (
dwFlags != 0))
1598 for (
i = 0;
i <
This->zonemap_count;
i++) {
1599 if (
This->zonemaps && !
This->zonemaps[
i]) {
1602 *pdwCount =
data[0];
1607 if (
This->zonemaps) {
1609 new_maps = heap_realloc_zero(
This->zonemaps,
This->zonemap_count * 2 *
sizeof(
LPDWORD));
1611 This->zonemap_count *= 2;
1615 This->zonemap_count = 2;
1616 new_maps = heap_alloc_zero(
This->zonemap_count *
sizeof(
LPDWORD));
1623 This->zonemaps = new_maps;
1626 *pdwCount =
data[0];
1641 TRACE(
"(%p)->(0x%08x, %d, %p)\n",
This, dwEnum, dwIndex, pdwZone);
1644 if (dwEnum < This->zonemap_count) {
1645 if ((
data =
This->zonemaps[dwEnum])) {
1646 if (dwIndex <
data[0]) {
1647 *pdwZone =
data[dwIndex + 1];
1664 TRACE(
"(%p)->(0x%08x)\n",
This, dwEnum);
1666 if (dwEnum < This->zonemap_count) {
1667 if ((
data =
This->zonemaps[dwEnum])) {
1684 FIXME(
"(%p)->(%08x %08x %08x) stub\n", iface, dwTemplate, dwZone,
dwReserved);
1696 URLZONEREG urlZoneReg,
1699 TRACE(
"(%p)->(%d, 0x%x, %p, %d, %d, 0x%x)\n", iface, dwZone,
1700 dwAction, pPolicy, cbPolicy, urlZoneReg,
dwFlags);
1719 URLZONEREG urlZoneReg,
1722 FIXME(
"(%p)->(%d, 0x%x, %p, %d, %d, 0x%x) stub\n", iface, dwZone, dwAction, pPolicy,
1723 cbPolicy, urlZoneReg,
dwFlags);
1732 ZONEATTRIBUTES* pZoneAttributes,
1735 TRACE(
"(%p)->(%d, %p, 0x%x)\n", iface, dwZone, pZoneAttributes,
dwFlags);
1740 return IInternetZoneManagerEx2_GetZoneAttributes(iface, dwZone, pZoneAttributes);
1749 BOOL fRespectPolicy,
1751 BOOL *pfPolicyEncountered)
1753 FIXME(
"(%p)->(%d, %d, %p, %p) stub\n", iface, dwZoneIndex, fRespectPolicy,
1754 pdwState, pfPolicyEncountered);
1756 *pdwState = SECURITY_IE_STATE_GREEN;
1758 if (pfPolicyEncountered)
1759 *pfPolicyEncountered =
FALSE;
1768 BOOL fRespectPolicy,
1770 BOOL *pfPolicyEncountered,
1773 FIXME(
"(%p)->(%d, %p, %p, %d) stub\n", iface, fRespectPolicy, pdwState,
1774 pfPolicyEncountered, fNoCache);
1776 *pdwState = SECURITY_IE_STATE_GREEN;
1778 if (pfPolicyEncountered)
1779 *pfPolicyEncountered =
FALSE;
1789 FIXME(
"(%p) stub\n", iface);
1827 TRACE(
"(%p %p)\n", pUnkOuter, ppobj);
1830 *ppobj = &
ret->IInternetZoneManagerEx2_iface;
1847 FIXME(
"pSP not supported\n");
1882 parse_hres = IInternetProtocolInfo_ParseUrl(
protocol_info,
url, PARSE_SECURITY_URL, 0, new_url,
size, &new_size, 0);
1895 parse_hres = IInternetProtocolInfo_ParseUrl(
protocol_info,
url, PARSE_SECURITY_URL, 0, new_url,
1896 new_size, &new_size, 0);
1907 url = alloc_url = new_url;
1924 parse_hres = IInternetProtocolInfo_ParseUrl(
protocol_info,
url, PARSE_SECURITY_DOMAIN, 0,
1925 new_url,
size, &new_size, 0);
1931 parse_hres = IInternetProtocolInfo_ParseUrl(
protocol_info,
url, PARSE_SECURITY_DOMAIN, 0, new_url,
1932 new_size, &new_size, 0);
1945 url = alloc_url = new_url;
1988 if(psuAction != PSU_SECURITY_URL_ONLY) {
1989 PARSEDURLW parsed_url = {
sizeof(parsed_url) };
2008 WARN(
"UrlGetPart failed: %08x\n",
hres);
2012 secure_url = new_url;
2017 *ppwzSecUrl = secure_url;
2033 if(!pUri || !ppSecUri)
2036 hres = IUri_GetDisplayUri(pUri, &secure_uri);
2046 hres = IUri_GetScheme(pUri, (
DWORD*)&scheme_type);
2048 const WCHAR *tmp = ret_url;
2052 if(*tmp !=
'/' || *(tmp+1) !=
'/')
2057 hres =
CreateUri(ret_url, Uri_CREATE_ALLOW_IMPLICIT_WILDCARD_SCHEME, 0, ppSecUri);
2078 static BOOL esc_initialized, esc_enabled;
2082 if(!esc_initialized) {
2086 static const WCHAR iehardenW[] = {
'I',
'E',
'H',
'a',
'r',
'd',
'e',
'n',0};
2094 esc_initialized =
TRUE;
static void * heap_alloc(size_t len)
static BOOL heap_free(void *mem)
#define InterlockedIncrement
#define InterlockedDecrement
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
#define RegCloseKey(hKey)
LONG WINAPI RegOpenKeyExW(HKEY hKey, LPCWSTR lpSubKey, DWORD ulOptions, REGSAM samDesired, PHKEY phkResult)
LONG WINAPI RegEnumKeyExW(_In_ HKEY hKey, _In_ DWORD dwIndex, _Out_ LPWSTR lpName, _Inout_ LPDWORD lpcbName, _Reserved_ LPDWORD lpReserved, _Out_opt_ LPWSTR lpClass, _Inout_opt_ LPDWORD lpcbClass, _Out_opt_ PFILETIME lpftLastWriteTime)
LONG WINAPI RegOpenKeyW(HKEY hKey, LPCWSTR lpSubKey, PHKEY phkResult)
LONG WINAPI RegSetValueExW(_In_ HKEY hKey, _In_ LPCWSTR lpValueName, _In_ DWORD Reserved, _In_ DWORD dwType, _In_ CONST BYTE *lpData, _In_ DWORD cbData)
LONG WINAPI RegQueryInfoKeyW(HKEY hKey, LPWSTR lpClass, LPDWORD lpcClass, LPDWORD lpReserved, LPDWORD lpcSubKeys, LPDWORD lpcMaxSubKeyLen, LPDWORD lpcMaxClassLen, LPDWORD lpcValues, LPDWORD lpcMaxValueNameLen, LPDWORD lpcMaxValueLen, LPDWORD lpcbSecurityDescriptor, PFILETIME lpftLastWriteTime)
LONG WINAPI RegQueryValueExW(_In_ HKEY hkeyorg, _In_ LPCWSTR name, _In_ LPDWORD reserved, _In_ LPDWORD type, _In_ LPBYTE data, _In_ LPDWORD count)
#define WideCharToMultiByte
static void cleanup(void)
UINT WINAPI GetDriveTypeW(IN LPCWSTR lpRootPathName)
HRESULT WINAPI UrlGetPartW(LPCWSTR pszIn, LPWSTR pszOut, LPDWORD pcchOut, DWORD dwPart, DWORD dwFlags)
HRESULT WINAPI ParseURLW(LPCWSTR x, PARSEDURLW *y)
static HRESULT WINAPI ZoneMgrImpl_GetIESecurityState(IInternetZoneManagerEx2 *iface, BOOL fRespectPolicy, LPDWORD pdwState, BOOL *pfPolicyEncountered, BOOL fNoCache)
static ULONG WINAPI SecManagerImpl_AddRef(IInternetSecurityManagerEx2 *iface)
static const WCHAR fileW[]
static ULONG WINAPI ZoneMgrImpl_Release(IInternetZoneManagerEx2 *iface)
static HRESULT WINAPI SecManagerImpl_GetSecurityIdEx2(IInternetSecurityManagerEx2 *iface, IUri *pUri, BYTE *pbSecurityId, DWORD *pcbSecurityId, DWORD_PTR dwReserved)
static HRESULT get_zone_from_domains(IUri *uri, DWORD *zone)
static HRESULT WINAPI ZoneMgrImpl_CopyTemplatePoliciesToZone(IInternetZoneManagerEx2 *iface, DWORD dwTemplate, DWORD dwZone, DWORD dwReserved)
static HRESULT WINAPI ZoneMgrImpl_DestroyZoneEnumerator(IInternetZoneManagerEx2 *iface, DWORD dwEnum)
static ULONG WINAPI ZoneMgrImpl_AddRef(IInternetZoneManagerEx2 *iface)
static HRESULT WINAPI ZoneMgrImpl_GetZoneCustomPolicy(IInternetZoneManagerEx2 *iface, DWORD dwZone, REFGUID guidKey, BYTE **ppPolicy, DWORD *pcbPolicy, URLZONEREG ulrZoneReg)
HRESULT ZoneMgrImpl_Construct(IUnknown *pUnkOuter, LPVOID *ppobj)
static LPDWORD build_zonemap_from_reg(void)
static HRESULT map_security_uri_to_zone(IUri *uri, DWORD *zone)
static const WCHAR wszZonesKey[]
static HRESULT WINAPI SecManagerImpl_SetZoneMapping(IInternetSecurityManagerEx2 *iface, DWORD dwZone, LPCWSTR pwszPattern, DWORD dwFlags)
static HRESULT map_uri_to_zone(IUri *uri, DWORD *zone, IUri **ret_uri)
BOOL WINAPI IsInternetESCEnabledLocal(void)
static HRESULT WINAPI ZoneMgrImpl_FixInsecureSettings(IInternetZoneManagerEx2 *iface)
static HRESULT WINAPI ZoneMgrImpl_GetZoneAttributes(IInternetZoneManagerEx2 *iface, DWORD dwZone, ZONEATTRIBUTES *pZoneAttributes)
static const WCHAR wszZoneMapDomainsKey[]
static BOOL is_drive_path(const WCHAR *path)
static HRESULT WINAPI SecManagerImpl_GetSecuritySite(IInternetSecurityManagerEx2 *iface, IInternetSecurityMgrSite **ppSite)
static HRESULT search_domain_for_zone(HKEY domains, LPCWSTR domain, DWORD domain_len, LPCWSTR schema, LPCWSTR host, DWORD host_len, DWORD *zone)
static BOOL matches_domain_pattern(LPCWSTR pattern, LPCWSTR str, BOOL implicit_wildcard, LPCWSTR *matched)
static HRESULT WINAPI SecManagerImpl_ProcessUrlActionEx2(IInternetSecurityManagerEx2 *iface, IUri *pUri, DWORD dwAction, BYTE *pPolicy, DWORD cbPolicy, BYTE *pContext, DWORD cbContext, DWORD dwFlags, DWORD_PTR dwReserved, DWORD *pdwOutFlags)
static HRESULT WINAPI SecManagerImpl_ProcessUrlAction(IInternetSecurityManagerEx2 *iface, LPCWSTR pwszUrl, DWORD dwAction, BYTE *pPolicy, DWORD cbPolicy, BYTE *pContext, DWORD cbContext, DWORD dwFlags, DWORD dwReserved)
static const WCHAR minlevelW[]
static HRESULT WINAPI ZoneMgrImpl_GetZoneAttributesEx(IInternetZoneManagerEx2 *iface, DWORD dwZone, ZONEATTRIBUTES *pZoneAttributes, DWORD dwFlags)
static HRESULT WINAPI ZoneMgrImpl_CreateZoneEnumerator(IInternetZoneManagerEx2 *iface, DWORD *pdwEnum, DWORD *pdwCount, DWORD dwFlags)
static HRESULT WINAPI ZoneMgrImpl_PromptAction(IInternetZoneManagerEx2 *iface, DWORD dwAction, HWND hwndParent, LPCWSTR pwszUrl, LPCWSTR pwszText, DWORD dwPromptFlags)
HRESULT WINAPI CoInternetCreateZoneManager(IServiceProvider *pSP, IInternetZoneManager **ppZM, DWORD dwReserved)
static HRESULT get_zone_from_reg(LPCWSTR schema, DWORD *zone)
static const WCHAR currentlevelW[]
static const WCHAR iconW[]
static HRESULT WINAPI ZoneMgrImpl_SetZoneActionPolicyEx(IInternetZoneManagerEx2 *iface, DWORD dwZone, DWORD dwAction, BYTE *pPolicy, DWORD cbPolicy, URLZONEREG urlZoneReg, DWORD dwFlags)
static const WCHAR displaynameW[]
static HRESULT WINAPI SecManagerImpl_QueryInterface(IInternetSecurityManagerEx2 *iface, REFIID riid, void **ppvObject)
static HRESULT WINAPI ZoneMgrImpl_LogAction(IInternetZoneManagerEx2 *iface, DWORD dwAction, LPCWSTR pwszUrl, LPCWSTR pwszText, DWORD dwLogFlags)
static HRESULT WINAPI SecManagerImpl_MapUrlToZone(IInternetSecurityManagerEx2 *iface, LPCWSTR pwszUrl, DWORD *pdwZone, DWORD dwFlags)
static HRESULT search_for_domain_mapping(HKEY domains, LPCWSTR schema, LPCWSTR host, DWORD host_len, DWORD *zone)
static HRESULT WINAPI SecManagerImpl_SetSecuritySite(IInternetSecurityManagerEx2 *iface, IInternetSecurityMgrSite *pSite)
static BOOL is_hierarchical_scheme(URL_SCHEME type)
static HRESULT parse_security_url(const WCHAR *url, PSUACTION action, WCHAR **result)
HRESULT WINAPI CoInternetGetSecurityUrlEx(IUri *pUri, IUri **ppSecUri, PSUACTION psuAction, DWORD_PTR dwReserved)
static HRESULT WINAPI SecManagerImpl_QueryCustomPolicy(IInternetSecurityManagerEx2 *iface, LPCWSTR pwszUrl, REFGUID guidKey, BYTE **ppPolicy, DWORD *pcbPolicy, BYTE *pContext, DWORD cbContext, DWORD dwReserved)
static const WCHAR zone_map_keyW[]
static HRESULT WINAPI ZoneMgrImpl_GetZoneSecurityState(IInternetZoneManagerEx2 *iface, DWORD dwZoneIndex, BOOL fRespectPolicy, LPDWORD pdwState, BOOL *pfPolicyEncountered)
HRESULT WINAPI CoInternetCreateSecurityManager(IServiceProvider *pSP, IInternetSecurityManager **ppSM, DWORD dwReserved)
static SecManagerImpl * impl_from_IInternetSecurityManagerEx2(IInternetSecurityManagerEx2 *iface)
static HRESULT WINAPI ZoneMgrImpl_QueryInterface(IInternetZoneManagerEx2 *iface, REFIID riid, void **ppvObject)
static HRESULT WINAPI ZoneMgrImpl_GetZoneActionPolicy(IInternetZoneManagerEx2 *iface, DWORD dwZone, DWORD dwAction, BYTE *pPolicy, DWORD cbPolicy, URLZONEREG urlZoneReg)
static HRESULT get_action_policy(DWORD zone, DWORD action, BYTE *policy, DWORD size, URLZONEREG zone_reg)
static HRESULT WINAPI SecManagerImpl_QueryCustomPolicyEx2(IInternetSecurityManagerEx2 *iface, IUri *pUri, REFGUID guidKey, BYTE **ppPolicy, DWORD *pcbPolicy, BYTE *pContext, DWORD cbContext, DWORD_PTR dwReserved)
static HRESULT WINAPI SecManagerImpl_GetSecurityId(IInternetSecurityManagerEx2 *iface, LPCWSTR pwszUrl, BYTE *pbSecurityId, DWORD *pcbSecurityId, DWORD_PTR dwReserved)
static HRESULT get_security_id_for_url(LPCWSTR url, BYTE *secid, DWORD *secid_len)
HRESULT SecManagerImpl_Construct(IUnknown *pUnkOuter, LPVOID *ppobj)
static ULONG WINAPI SecManagerImpl_Release(IInternetSecurityManagerEx2 *iface)
static HRESULT WINAPI ZoneMgrImpl_SetZoneAttributes(IInternetZoneManagerEx2 *iface, DWORD dwZone, ZONEATTRIBUTES *pZoneAttributes)
static HRESULT WINAPI SecManagerImpl_GetZoneMappings(IInternetSecurityManagerEx2 *iface, DWORD dwZone, IEnumString **ppenumString, DWORD dwFlags)
static HRESULT WINAPI ZoneMgrImpl_GetZoneActionPolicyEx(IInternetZoneManagerEx2 *iface, DWORD dwZone, DWORD dwAction, BYTE *pPolicy, DWORD cbPolicy, URLZONEREG urlZoneReg, DWORD dwFlags)
static HRESULT WINAPI ZoneMgrImpl_SetZoneCustomPolicy(IInternetZoneManagerEx2 *iface, DWORD dwZone, REFGUID guidKey, BYTE *ppPolicy, DWORD cbPolicy, URLZONEREG ulrZoneReg)
static void get_dword_from_reg(HKEY hcu, HKEY hklm, LPCWSTR name, LPDWORD out)
static const WCHAR flagsW[]
static HRESULT WINAPI ZoneMgrImpl_SetZoneActionPolicy(IInternetZoneManagerEx2 *iface, DWORD dwZone, DWORD dwAction, BYTE *pPolicy, DWORD cbPolicy, URLZONEREG urlZoneReg)
static HRESULT WINAPI SecManagerImpl_ProcessUrlActionEx(IInternetSecurityManagerEx2 *iface, LPCWSTR pwszUrl, DWORD dwAction, BYTE *pPolicy, DWORD cbPolicy, BYTE *pContext, DWORD cbContext, DWORD dwFlags, DWORD dwReserved, DWORD *pdwOutFlags)
static BOOL get_zone_for_scheme(HKEY key, LPCWSTR schema, DWORD *zone)
static HRESULT generate_security_id(IUri *uri, BYTE *secid, DWORD *secid_len, DWORD zone)
static HRESULT map_url_to_zone(LPCWSTR url, DWORD *zone, LPWSTR *ret_url)
static HRESULT get_security_id_for_uri(IUri *uri, BYTE *secid, DWORD *secid_len)
HRESULT WINAPI CompareSecurityIds(BYTE *secid1, DWORD size1, BYTE *secid2, DWORD size2, DWORD reserved)
static const WCHAR recommendedlevelW[]
HRESULT WINAPI CoInternetGetSecurityUrl(LPCWSTR pwzUrl, LPWSTR *ppwzSecUrl, PSUACTION psuAction, DWORD dwReserved)
static HRESULT WINAPI ZoneMgrImpl_GetZoneAt(IInternetZoneManagerEx2 *iface, DWORD dwEnum, DWORD dwIndex, DWORD *pdwZone)
static HRESULT WINAPI SecManagerImpl_MapUrlToZoneEx2(IInternetSecurityManagerEx2 *iface, IUri *pUri, DWORD *pdwZone, DWORD dwFlags, LPWSTR *ppwszMappedUrl, DWORD *pdwOutFlags)
static const IInternetZoneManagerEx2Vtbl ZoneMgrImplVtbl
static void get_string_from_reg(HKEY hcu, HKEY hklm, LPCWSTR name, LPWSTR out, DWORD maxlen)
static ZoneMgrImpl * impl_from_IInternetZoneManagerEx2(IInternetZoneManagerEx2 *iface)
static const IInternetSecurityManagerEx2Vtbl VT_SecManagerImpl
static const WCHAR descriptionW[]
static HRESULT open_zone_key(HKEY parent_key, DWORD zone, HKEY *hkey)
IInternetProtocolInfo * get_protocol_info(LPCWSTR url)
void find_domain_name(const WCHAR *host, DWORD host_len, INT *domain_start)
HRESULT WINAPI CreateUri(LPCWSTR pwzURI, DWORD dwFlags, DWORD_PTR dwReserved, IUri **ppURI)
WDF_INTERRUPT_POLICY policy
GLuint GLuint GLsizei GLenum type
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
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
LPVOID WINAPI CoTaskMemRealloc(LPVOID pvOld, SIZE_T size)
VOID WINAPI CoTaskMemFree(LPVOID ptr)
LPVOID WINAPI CoTaskMemAlloc(SIZE_T size)
_Check_return_ long __cdecl wcstol(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix)
#define memcpy(s1, s2, n)
#define ERROR_FILE_NOT_FOUND
static IInternetProtocolInfo protocol_info
static const BYTE secid2[]
static const BYTE secid1[]
_In_ HANDLE _In_ DWORD _In_ DWORD _Inout_opt_ LPOVERLAPPED _In_opt_ LPTRANSMIT_FILE_BUFFERS _In_ DWORD dwReserved
UINT WINAPI SysStringLen(BSTR str)
void WINAPI DECLSPEC_HOTPATCH SysFreeString(BSTR str)
#define IsEqualIID(riid1, riid2)
_Check_return_ _CRTIMP int __cdecl wcscmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)
static const WCHAR wildcardW[]
#define URL_PARTFLAG_KEEPSCHEME
IInternetSecurityManager * custom_manager
IInternetSecurityMgrSite * mgrsite
IInternetSecurityManagerEx2 IInternetSecurityManagerEx2_iface
IInternetZoneManagerEx2 IInternetZoneManagerEx2_iface
#define CONTAINING_RECORD(address, type, field)
static void URLMON_LockModule(void)
static void URLMON_UnlockModule(void)
#define DRIVE_NO_ROOT_DIR
_In_ PCCERT_CONTEXT _In_ DWORD dwFlags
_In_ void _In_ PCCERT_CONTEXT _In_opt_ LPFILETIME _In_ DWORD _In_ DWORD _Outptr_opt_ void ** ppvObject
#define E_NOT_SUFFICIENT_BUFFER
#define HRESULT_FROM_WIN32(x)
#define HKEY_LOCAL_MACHINE
#define HKEY_CURRENT_USER
int WINAPIV wsprintfW(_Out_ LPWSTR, _In_ _Printf_format_string_ LPCWSTR,...)