LizardWiz
2007-12-06 18:48:06 UTC
Can anyone tell me how INTERNET_FLAG_EXISTING_CONNECT flag works in the
header? I have a system that I am communicating with that claims that
sometimes when I send a HTTP get using WinInet that the authentication is
left out of the internet header.
Is it possible that the connection does not send the authentication in the
header if somehow it determines that it has successfully reused an existing
connection?
Thanks in advance if anyone can helpme with this...
Here is a sample of how I am using WinInet in C++, it is pretty standard:
CInternetSession m_InternetSession;
CHttpConnection* m_pConnection = NULL;
CHttpFile* m_pFile = NULL;
DWORD m_HttpRequestFlags = INTERNET_FLAG_EXISTING_CONNECT |
INTERNET_FLAG_RELOAD | INTERNET_FLAG_DONT_CACHE;
m_pConnection = m_InternetSession.GetHttpConnection(strHTTPSiteConnection,
nHTTPSitePort, strHTTPSiteUser, strHTTPSitePassword);
m_pFile = m_pConnection->OpenRequest(CHttpConnection::HTTP_VERB_GET,
(LPCSTR)m_strURL, NULL, NULL, NULL, NULL, m_HttpRequestFlags);
m_pFile->SendRequest();
header? I have a system that I am communicating with that claims that
sometimes when I send a HTTP get using WinInet that the authentication is
left out of the internet header.
Is it possible that the connection does not send the authentication in the
header if somehow it determines that it has successfully reused an existing
connection?
Thanks in advance if anyone can helpme with this...
Here is a sample of how I am using WinInet in C++, it is pretty standard:
CInternetSession m_InternetSession;
CHttpConnection* m_pConnection = NULL;
CHttpFile* m_pFile = NULL;
DWORD m_HttpRequestFlags = INTERNET_FLAG_EXISTING_CONNECT |
INTERNET_FLAG_RELOAD | INTERNET_FLAG_DONT_CACHE;
m_pConnection = m_InternetSession.GetHttpConnection(strHTTPSiteConnection,
nHTTPSitePort, strHTTPSiteUser, strHTTPSitePassword);
m_pFile = m_pConnection->OpenRequest(CHttpConnection::HTTP_VERB_GET,
(LPCSTR)m_strURL, NULL, NULL, NULL, NULL, m_HttpRequestFlags);
m_pFile->SendRequest();
--
~LizardWiz()
~LizardWiz()