Welcome to HostingForumz.com!
FAQFAQ      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

How to get session ID in ISAPI Filter

 
   Web Hosting Problem Solving Community! (Home) -> IIS RSS
Next:  I GIVE THANKS  
Author Message
anonymous1275

External


Since: Feb 25, 2004
Posts: 11



(Msg. 1) Posted: Thu May 20, 2004 3:31 am
Post subject: How to get session ID in ISAPI Filter
Archived from groups: microsoft>public>inetserver>iis (more info?)

Hi, all
At first, I must thank for David Wang's and Mark Weaver's answers. I have known that the ASP session object can't be used in ISAPI. There is other problem, please help me.
I want to get a session ID in ISAPI filter, but how to do it? If it is impossible, how can I judge a session from server to client?
session ID should be sent to server in a HTTP request, but how to get it?
Someone can give me a sample?

 >> Stay informed about: How to get session ID in ISAPI Filter 
Back to top
Login to vote
someone9

External


Since: Aug 25, 2003
Posts: 2419



(Msg. 2) Posted: Thu May 20, 2004 4:27 am
Post subject: Re: How to get session ID in ISAPI Filter [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

First, you must define what you mean by "session". This is an
application-layer concept that has no meaning at the HTTP Transport layer
that ISAPI operate at. Thus, before you can "get a session ID in ISAPI
filter", YOU must define this concept of "session".

Then, you need to realize that session involves keeping state which
distinguishes one session from another... but HTTP is stateless. One
application-layer protocol to persist state, implemented by web browsers and
web applications, is Cookies. Cookies are implemented via request/response
headers, which is something that ISAPI can manipulate.

ISAPI is a powerful low-level API, so, you must first define what you mean
by "session", then figure out how it is persisted between the client/server
and the appropriate manipulation protocol, and finally, write the ISAPI to
view/modify this state using the proper protocol.

--
//David
IIS
This posting is provided "AS IS" with no warranties, and confers no rights.
//
"Ray" <anonymous RemoveThis @discussions.microsoft.com> wrote in message
news:73C201AD-48FE-4216-AC9A-5A96F189E4F6@microsoft.com...
Hi, all
At first, I must thank for David Wang's and Mark Weaver's answers. I have
known that the ASP session object can't be used in ISAPI. There is other
problem, please help me.
I want to get a session ID in ISAPI filter, but how to do it? If it is
impossible, how can I judge a session from server to client?
session ID should be sent to server in a HTTP request, but how to get it?
Someone can give me a sample?

 >> Stay informed about: How to get session ID in ISAPI Filter 
Back to top
Login to vote
user1580

External


Since: Apr 03, 2004
Posts: 367



(Msg. 3) Posted: Thu May 20, 2004 2:17 pm
Post subject: Re: How to get session ID in ISAPI Filter [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

"Ray" <anonymous.RemoveThis@discussions.microsoft.com> wrote in message
news:73C201AD-48FE-4216-AC9A-5A96F189E4F6@microsoft.com...
 > Hi, all
 > At first, I must thank for David Wang's and Mark Weaver's answers. I have
known that the ASP session object can't be used in ISAPI. There is other
problem, please help me.
 > I want to get a session ID in ISAPI filter, but how to do it? If it is
impossible, how can I judge a session from server to client?
 > session ID should be sent to server in a HTTP request, but how to get it?
 > Someone can give me a sample?

ATL (C++ 7.x) does a wonderfull job managing sessions using it's own
mechanism in ATL server pages. There's no or little hope, you would be able
to transfer the ASP session id into ISAPI and vice versa.<!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: How to get session ID in ISAPI Filter 
Back to top
Login to vote
anonymous1275

External


Since: Feb 25, 2004
Posts: 11



(Msg. 4) Posted: Sat May 22, 2004 10:31 pm
Post subject: RE: How to get session ID in ISAPI Filter [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Thank for your response. My "session" is ASP session. You know ASP session is implemented by putting session ID into client cookie. I want to get session ID to judge if a request is from a same client. I think it should be finished by reading cookie, but there are some problems. I hope someone can describe the whole process.
 >> Stay informed about: How to get session ID in ISAPI Filter 
Back to top
Login to vote
olnews

External


Since: Apr 28, 2004
Posts: 5



(Msg. 5) Posted: Sun May 23, 2004 6:50 pm
Post subject: Re: How to get session ID in ISAPI Filter [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Hallo,

"Ray" <anonymous.TakeThisOut@discussions.microsoft.com> wrote:

 > Thank for your response. My "session" is ASP session. You know ASP
 > session is implemented by putting session ID into client cookie. I
 > want to get session ID to judge if a request is from a same client.
 > I think it should be finished by reading cookie,

That's correct.

 > but there are some problems.

What kind of problems?

 > I hope someone can describe the whole process.

You can download a complete filter sample (incl. source) dealing with
ASP session id at:

<a style='text-decoration: underline;' href="http://nogetec.de/asp/filter/sessionid" target="_blank">http://nogetec.de/asp/filter/sessionid</a>

--
Regards, Olaf
MS MVP ASP / ASP.NET<!-- ~MESSAGE_AFTER~ -->
 >> Stay informed about: How to get session ID in ISAPI Filter 
Back to top
Login to vote
anonymous1275

External


Since: Feb 25, 2004
Posts: 11



(Msg. 6) Posted: Sun May 23, 2004 10:01 pm
Post subject: Re: How to get session ID in ISAPI Filter [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Back to top
Login to vote
Display posts from previous:   
   Web Hosting Problem Solving Community! (Home) -> IIS All times are: Pacific Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]