Re: Igor, pAPP toolkit questions
From: Josh Mclaren (optics201_at_optonline.com)
Date: 11/24/04
- Next message: Jan: "Re: Escaping both spaces and unsafe chars"
- Previous message: Igor Tandetnik: "Re: Escaping both spaces and unsafe chars"
- In reply to: Igor Tandetnik: "Re: Igor, pAPP toolkit questions"
- Next in thread: Igor Tandetnik: "Re: Igor, pAPP toolkit questions"
- Reply: Igor Tandetnik: "Re: Igor, pAPP toolkit questions"
- Messages sorted by: [ date ] [ thread ]
Date: 23 Nov 2004 16:28:55 -0800
Igor,
Your advice worked, just as you had expected. This even helped my
greater goal of looking at all data that went out.. the
HTTP_QUERY_RAW_HEADERS_CRLF has a lot more detail when checked within
BINDSTATUS_SENDINGREQUEST.
Although it worked, I found that this might not be everything that I
need...
For basic authentication we can be pretty sure that sending the same
data will result in authorization and the same response at a later
time. So that is good.
As far as I understand NTLM credentials, this credentials data will
not be useful in a playback scenario where we send the same HTTP
stream of data at a later time to the server. If the credentials
header is sufficient to send back at a later time and have it
authorize, then I technically should be ok.
Again, with my cursory glance at the NTLM protocol, I am guessing this
is not the case (would make life too easy for me ;) ).
I suspect I need to implement IAuthenticate, but somehow make it pass
through as well. I also suspect this is stuff that may need to be
handled at the host application/WebBrowser control rather than at the
protocol level. I haven't had much success with this in the C#
project which is consuming the pAPP COM object.
I hope you still get a chance to look at my previous post since
although this post deals with outgoing stuff and NTLM credentials, I'm
still curious about reading back or building the entire response
stream including response headers / HTML content, preferabally to
store it in its entirety.
If you could point me in the direction of the easiest way to extract
this using the pAPP toolkit that would be just excellent!
HTTPS is also something I am keeping in mind, I want to be able to
see/build both the request and response streams unencrypted. With my
tests so far, I believe the pAPP toolkit already is setup to show it
to me unencrypted.
Thanks again for your help!!
-Josh
"Igor Tandetnik" <itandetnik@mvps.org> wrote in message news:<#RzCtmX0EHA.804@TK2MSFTNGP12.phx.gbl>...
> "Josh Mclaren" <optics201@optonline.com> wrote in message
> news:72494446.0411221935.4f759181@posting.google.com
> > I am having trouble implementing what you suggested in the following
> > post, with the pAPP toolkit. :
> >
> > http://groups.google.com/groups?hl=en&lr=&safe=off&selm=OsmO3iP5DHA.1664%40TK2MSFTNGP11.phx.gbl
> >
> > When I simply take the pAPP toolkit and replace the
> > HTTP_QUERY_RAW_HEADERS_CRLF | HTTP_QUERY_FLAG_REQUEST_HEADERS
> > QueryInfo call
> >
> > with
> >
> > HTTP_QUERY_AUTHORIZATION | HTTP_QUERY_FLAG_REQUEST_HEADERS
> >
> > the buffer is always an invalid pointer.
>
> I'm not sure what that means. You pass the buffer to the method, right?
> So make sure it is valid. Am I missing something obvious?
>
> Also, make sure you don't call too early. You definitely need to do it
> after IAuthenticate::Authenticate returns. Probably the best place is in
> BINDSTATUS_SENDINGREQUEST notification - by this time, all the request
> headers have been fully prepared.
>
> > I've also played around with
> > GetBindInfo off of the m_spInternetBindInfo object. I've been able to
> > use that succesfully to retreive post Data (though I'm not sure that
> > is the best way)
>
> It is the best and only way. The POST data is supplied in BINDINFO
> structure.
>
> > and I thought I might be able to use it similarly to
> > retrieve BINDSTRING_USERNAME as some MSDN code retrieves MIME types.
>
> I found GetBindString to be very inconsistent. It works for some strings
> but not others, with no apparent reason. Usually there are alternative
> ways to get the same information, so I haven't spent much time on it.
>
> > Another question I had is to ask is what is the best way to examine
> > the html content that is received with the current toolkit.
>
> IInternetProtocol::Read is the only place you can see it.
>
> > Ideally
> > I'd like the entire message rather than dealing with QueryInfo's
> > splitting of the headers etc.
>
> Now I'm confused. Are you asking about response body (presumably HTML
> content), or response headers?
- Next message: Jan: "Re: Escaping both spaces and unsafe chars"
- Previous message: Igor Tandetnik: "Re: Escaping both spaces and unsafe chars"
- In reply to: Igor Tandetnik: "Re: Igor, pAPP toolkit questions"
- Next in thread: Igor Tandetnik: "Re: Igor, pAPP toolkit questions"
- Reply: Igor Tandetnik: "Re: Igor, pAPP toolkit questions"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|