Python disappointly failed to provide a convinient cgi session
management module. Not willing to use external modules, I would like to
implement a simplest Session object on my own.
The basic problem is: how could a python CGI program understand several
requests are in the same session? Definately, request from different IP
would be easy to identified to be in different sessions, but request
from the same IP would not.
Anyone has any idea?
Thank you:-) 5 5685
Sullivan WxPyQtKinter wrote: Python disappointly failed to provide a convinient cgi session management module.
Probably because there are much better options for web programming in
Python ?
Not willing to use external modules, I would like to implement a simplest Session object on my own.
The basic problem is: how could a python CGI program understand several requests are in the same session?
Just like anyone else: by setting a session cookie. This is not related
to CGI, it's just how HTTP works.
--
bruno desthuilliers
python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for
p in 'o****@xiludom. gro'.split('@')])"
>>>>> "Sullivan WxPyQtKinter" <su***********@ gmail.com> (SW) wrote: SW> Python disappointly failed to provide a convinient cgi session SW> management module. Not willing to use external modules, I would like to SW> implement a simplest Session object on my own.
SW> The basic problem is: how could a python CGI program understand several SW> requests are in the same session? Definately, request from different IP SW> would be easy to identified to be in different sessions, but request SW> from the same IP would not. http://starship.python.net/~davem/cg...=faq02.011.htp
or google for python cgi session for more.
But why write it yourself if someone else has already done the work?
--
Piet van Oostrum <pi**@cs.uu.n l>
URL: http://www.cs.uu.nl/~piet [PGP 8DAE142BE17999C 4]
Private email: pi**@vanoostrum .org
Sullivan WxPyQtKinter wrote: Python disappointly failed to provide a convinient cgi session management module. Not willing to use external modules, I would like to implement a simplest Session object on my own.
The basic problem is: how could a python CGI program understand several requests are in the same session? Definately, request from different IP would be easy to identified to be in different sessions, but request from the same IP would not.
Anyone has any idea?
Maybe you could get over your irrational fear of external modules just
long enough to download one or two and examine them, to learn how they
do it. Then you could answer your own question...
bruno at modulix 写道: Sullivan WxPyQtKinter wrote: Python disappointly failed to provide a convinient cgi session management module.
Probably because there are much better options for web programming in Python ?
Really? Then what is it?
Sullivan WxPyQtKinter wrote: bruno at modulix 写道:
Sullivan WxPyQtKinter wrote:
Python disappointly failed to provide a convinient cgi session management module.
Probably because there are much better options for web programming in Python ?
Really? Then what is it?
Please notice the 's' at the end of 'options'. For a quick and
incomplete overview, you can start here: http://wiki.python.org/moin/WebProgramming
--
bruno desthuilliers
python -c "print '@'.join(['.'.join([w[::-1] for w in p.split('.')]) for
p in 'o****@xiludom. gro'.split('@')])" This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Paul |
last post by:
Hmmm, didn't seem to work. I have set session.use_cookies = 1 and
session.use_trans_sid = 1 in my php.ini file. Index.php contains:
----------------------------------------------------------------------------
<?php
ini_set("session.use_cookies", "off");
ini_set("session.use_trans_sid", "on");
session_start();
$_SESSION = "";
$_SESSION = "";
echo "<form method='POST' action='login.php'>
|
by: mrbog |
last post by:
Tell me if my assertion is wrong here:
The only way to prevent session hijacking is to NEVER store
authentication information (such as name/password) in the session.
Well, to never authenticate a user from information you got from the
session. Each secure app on a site must challenge the user for name
and password, each and every time the user accesses it (not just once
and then store it in the session). If a secure app is multi-page,...
|
by: Damien |
last post by:
Hi to all,
I'm currently re-designing our intranet : nice and lean CSS2, cleaned-up
PHP 4.3.7, better-normalized MySQL ;o). So I've started using the
$_SESSION variable instead of register_globals and a couple "better
pratice" code. Not perfect, but better.
Problem : I'm testing everything with Firefox on my machine (IIS on
WinXP Pro), and everything is ok. As soon as I try MS IE 6, it doesn't
seem to keep the sessions from page to...
|
by: Mimi |
last post by:
Hello,
I am having trouble using the session vars in
PHP 4.3.9
OS: Win XP Prof
Web Server IIS (is local and there are no links to other servers from
the web pages I work on)
Browser: IE 6.0
The problem I am having is that each time I reload the same PHP page, I get
|
by: joseph conrad |
last post by:
Hi,
I tried to implement my own session handler in order to keep control on
the process
the drawback I foun it is not creating and storing in my cookie the
PHPSESSID variable anymore.
reading te documentation it seems it should do it anyway
any advice?
| |
by: aroraamit81 |
last post by:
Hi,
I am facing a trouble. I have some Session variables in my code and
somehow my session variables are getting mixed up with other users.
For example User A has access to 10 companies and User B has access to
5, now when both of us hits to the server at the same time then their
session variables gets mixedup means either User A and USer B will have
now 5 companies or both have 10 companies. Now again when User A hits
to the server...
|
by: aroraamit81 |
last post by:
Well Guys, Here is a very strange trouble. When more than one users
request tto same page at the same time then our session gets
conflicted.
Moreover I printed my SessionID, strangely but true I got the exact
same SessionID as of other users's.
Well I guess nothing wrong with my code, do I need to set any property
in Web.Config file??
|
by: Santosh |
last post by:
Dear All
i am writting a code sending mail with attachement.
i am writting code for sending mail in one page and code for attaching
a file in the next page.
aftet attaching a file i am taking name of that file from attaching
file page to email page through in session file .i am giving a
facility of attaching five files to user . and i am taking names of
both files in session variables but user attach less than five five
|
by: lyealain |
last post by:
<%
If Session("username") = "" Then
Response.Redirect("/CLS/Login.asp")
End If
Dim conn
Dim connectstr
Dim db_name, db_username, db_userpassword
Dim db_server
Dim res
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, well explore What is ONU, What Is Router, ONU & Routers main usage, and What is the difference between ONU and Router. Lets take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupr who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |