Glenn A. Hochberg
gah at research.att.com
Tue Jan 13 13:22:47 EST 2004
Good suggestion--thanks! -Glenn Michael C. Neel wrote: >I haven't seen anything that standardizes the way SSL should create >vars, and I think there is difference even between Apache-SSL and >mod_ssl in naming. You can get the port, 443, which is the standard for >SSL, but that doesn't mean SSL is in use. However, given you need a >separate virtural host on port 443 for the ssl configuration, you can >easily add a PythonOption there as well to know if you are in SSL or >not. > >Mike > > > > >>-----Original Message----- >>From: Glenn A. Hochberg [mailto:gah at research.att.com] >>Sent: Tuesday, January 13, 2004 11:44 AM >>To: mod_python at modpython.org >>Subject: [mod_python] Re: Mod_python Digest, Vol 10, Issue 15 >> >> >>REMOTE_ADDR is available as req.connection.remote_ip, >>SCRIPT_NAME as req.filename. >> >>Actually, one CGI env. var. that I have not been able to find >>via mod_python is HTTPS (set to "on" when using SSL). >> >>Is there some way to determine whether your baseurl should >>start with https: versus http:? I'm trying to pass my full >>URL to another site via a redirect; I can find out everything >>I need except for that. >> >> -Glenn >> >>On Mon, 12 Jan 2004 15:36:42 -0600, Edwin Grubbs wrote: >> >> >> >>>On Sun, Jan 11, 2004 at 11:27:12PM -0500, Gregory (Grisha) >>> >>> >>Trubetskoy wrote: >> >> >> >>>>On Sun, 11 Jan 2004, Edwin Grubbs wrote: >>>> >>>> >>> >>> >>> >>> >>>>>>The objective is to access the environment variables >>>>>> >>>>>> >>that are unique to >> >> >>>>>>each request such as REMOTE_ADDR, HTTP_USER_AGENT, and >>>>>> >>>>>> >>our own cookies >> >> >>>>>>such as SESSION_COOKIE. >>>>>> >>>>>> >>>>>> >>>> >>>> >>>> >>>>Hmm... This may be a bug somehwere, I'll have to take a >>>> >>>> >>look at it. But, >> >> >>>>all of this information is available directly without having to use >>>>subprocess_env, as part of the request object or req.headers_in. >>>>Subprocess_env is an inefficient way of doing it since it >>>> >>>> >>is artificially >> >> >>>>constructed from the same sources to which mod_python >>>> >>>> >>allows you direct >> >> >>>>access. >>>> >>>>Grisha >>>> >>>> >>> >>> >>> >>> >>>The req.headers_in variable does not contain the REMOTE_ADDR or the >>>SCRIPT_NAME variables which can not be passed in using PythonOption. >>> >>>-Edwin >>> >>> >>_______________________________________________ >>Mod_python mailing list >>Mod_python at modpython.org >>http://mailman.modpython.org/mailman/listinfo/mod_python >> >> >> > > >
|