<?xml version='1.0' encoding="utf-8"?>
      <rss version='2.0'>
      <channel>
      <title>Форум на Исходниках.RU</title>
      <link>https://forum.sources.ru</link>
      <description>Форум на Исходниках.RU</description>
      <generator>Форум на Исходниках.RU</generator>
  	
      <item>
        <guid isPermaLink='true'>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2470666</guid>
        <pubDate>Tue, 12 Jan 2010 10:47:09 +0000</pubDate>
        <title>InternetQueryOption валится</title>
        <link>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2470666</link>
        <description><![CDATA[MichSpar: <strong class='tag-b'>arj99</strong>, ты прав. Спасибо :)]]></description>
        <author>MichSpar</author>
        <category>C/C++: Сетевое программирование</category>
      </item>
	
      <item>
        <guid isPermaLink='true'>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2470636</guid>
        <pubDate>Tue, 12 Jan 2010 10:28:22 +0000</pubDate>
        <title>InternetQueryOption валится</title>
        <link>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2470636</link>
        <description><![CDATA[arj99: Насколько понимаю InternetQueryOption и InternetSetOption для INTERNET_OPTION_SECURITY_FLAGS нужно вызывать с первым параметром hUrl = ::InternetOpenUrl(...), а не корневым дескриптором.]]></description>
        <author>arj99</author>
        <category>C/C++: Сетевое программирование</category>
      </item>
	
      <item>
        <guid isPermaLink='true'>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2470623</guid>
        <pubDate>Tue, 12 Jan 2010 10:18:37 +0000</pubDate>
        <title>InternetQueryOption валится</title>
        <link>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2470623</link>
        <description><![CDATA[MichSpar: С целью установить в последствии флаг SECURITY_FLAG_IGNORE_REVOCATION и вызова InternetOpenUrl:<br>
<div class='tag-code'><span class='pre_code'></span><div class='code  code_collapsed ' title='Подсветка синтаксиса доступна зарегистрированным участникам Форума.' style=''><div><div><ol type="1"><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;dwFlags = dwFlags | SECURITY_FLAG_IGNORE_REVOCATION;</div><div class="code_line">&nbsp;</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;if ( !::InternetSetOption( hSession, INTERNET_OPTION_SECURITY_FLAGS, &amp;dwFlags, size ) )</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;printf( _T( &quot;Warning: failed to set SECURITY_FLAG_IGNORE_REVOCATION: %x&quot;, ::GetLastError() ) );</div><div class="code_line">&nbsp;&nbsp; &nbsp;HINTERNET hUrl = ::InternetOpenUrl (</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;hSession, url, NULL, 0, INTERNET_FLAG_RELOAD | INTERNET_FLAG_NO_UI | INTERNET_FLAG_NO_CACHE_WRITE, 0 );</div></ol></div></div></div></div><script>preloadCodeButtons('1');</script><br>
вызов InternetSetOption тоже, кстати, падает с такими же случайными кодами ошибок.]]></description>
        <author>MichSpar</author>
        <category>C/C++: Сетевое программирование</category>
      </item>
	
      <item>
        <guid isPermaLink='true'>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2470604</guid>
        <pubDate>Tue, 12 Jan 2010 09:57:59 +0000</pubDate>
        <title>InternetQueryOption валится</title>
        <link>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2470604</link>
        <description><![CDATA[arj99: <strong class='tag-b'>MichSpar</strong>, а с какой целью в InternetQueryOption передаешь для запроса INTERNET_OPTION_SECURITY_FLAGS корневой HINTERNET-дескриптор?<br>
Насколько разумею, INTERNET_OPTION_SECURITY_FLAGS подразумевает параметры безопасности для конкретного соединения с конкретным объектом, а не всего использования WinInet программой.<br>
Т.е. при запросе INTERNET_OPTION_SECURITY_FLAGS InternetQueryOption ожидает дескриптор возвращенный чем-то вроде <a class='tag-url' href='http://msdn.microsoft.com/en-us/library/aa384233%28VS.85%29.aspx' target='_blank'>HttpOpenRequest</a>(..., &quot;GET&quot;, &quot;forum.sources.ru/index.php&quot;, ...)]]></description>
        <author>arj99</author>
        <category>C/C++: Сетевое программирование</category>
      </item>
	
      <item>
        <guid isPermaLink='true'>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2469950</guid>
        <pubDate>Mon, 11 Jan 2010 16:04:25 +0000</pubDate>
        <title>InternetQueryOption валится</title>
        <link>https://forum.sources.ru/index.php?showtopic=291899&amp;view=findpost&amp;p=2469950</link>
        <description><![CDATA[MichSpar: Есть такой код:<br>
<div class='tag-code'><span class='pre_code'></span><div class='code  code_collapsed ' title='Подсветка синтаксиса доступна зарегистрированным участникам Форума.' style=''><div><div><ol type="1"><div class="code_line">DWORD foo()</div><div class="code_line">&nbsp;&nbsp; &nbsp;HINTERNET hSession = ::InternetOpen(_T(&quot;User Agent&quot;),</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;INTERNET_OPEN_TYPE_PRECONFIG,</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;NULL, NULL, 0);</div><div class="code_line">&nbsp;&nbsp; &nbsp;if ( !hSession )</div><div class="code_line">&nbsp;&nbsp; &nbsp;{</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; return FALSE;</div><div class="code_line">&nbsp;&nbsp; &nbsp;}</div><div class="code_line">&nbsp;</div><div class="code_line">&nbsp;&nbsp; &nbsp;DWORD dwFlags = 0;</div><div class="code_line">&nbsp;&nbsp; &nbsp;DWORD size = sizeof( DWORD );</div><div class="code_line">&nbsp;</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;if ( </div><div class="code_line">&nbsp;&nbsp; &nbsp; !::InternetQueryOption( hSession, INTERNET_OPTION_SECURITY_FLAGS, &amp;dwFlags, &amp;size )</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; )</div><div class="code_line">&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; return ::GetLastError();</div><div class="code_line">&nbsp;</div><div class="code_line">&nbsp;&nbsp;return 0;</div><div class="code_line">}</div></ol></div></div></div></div><br>
InternetQueryOption почему-то валится, причём GetLastError всегда возвращает что-то новое и необычное. :unsure:]]></description>
        <author>MichSpar</author>
        <category>C/C++: Сетевое программирование</category>
      </item>
	
      </channel>
      </rss>
	