For my current project I'm making PyQt GUI to be used in Maya. One of
my requirement is that users need to login with username and password
first.
After authenticating the account, I'm not sure how I can store the
session. I tried Cookie.Simplecookie but I guess it doesn't wok
because the GUI is not running through HTTP.
Any suggestion appreciate.
How much security do you need? For instance, I have an app at work that sets
the interface to either READ or EDIT mode depending on the group the current
user is in, in the LDAP. So when the app starts, I check their login against LDAP, and
if they are a Lead then they have EDIT mode. When the widgets load, they can check
for that value and control the read-only state of the forms.
In terms of the equivalent of an http session, that would mean you want to keep a session
key locally only, and all properties are actually kept on a server that is not directly visable
by the client. Each action would have to provide the session key to the server, and then
the server would deliver some form of content. I dont know if it makes sense in a desktop
application though. Auth once and store the state locally I think.
> --
> view archives: http://groups.google.com/group/python_inside_maya
> change your subscription settings: http://groups.google.com/group/python_inside_maya/subscribe
I was instructed to store the use's login and password in postgresql,
separate from LDAP account along with a separate set of permission
settings. I'm only planning to do a simple login and encrypted
password comparison here. Coming from PHP, cookies and online session
are the only ways I'm familiar with :(
So if I store the login data within the app itself as a
variable/dictionary, it will be available as long as the GUI is still
opened? If the user close the GUI and run it back again this variable
will be reset?
--
--
At the moment I'm implementing a method similar to cookie but using
SQLite to store the session ID locally instead. Other information will
be stored server side using this same session ID as reference. For my
current skill level I guess this is not too bad...
Thanks for suggestions and happy new year everyone :)
best regard,
Panupat C.