GWT - Getting session management right -
i'm trying implement simple session management mechanism in gwt, , i'm still not quite sure if got right:
- first, in
onmoduleload, check ifsessionidcookie exists. if exists, call server see if still valid. if is, returnuserobject contains sessionid , full username (i need within application). - if doesn't exist, diplay
logindialog. user enters username , password. callauthenticationservice, check if username + password valid, returnuserobject. sessionid gets stored cookie. - when loggin out, delete
sessionidcookie.
this how sessionid gets created:
string sessionid = uuid.randomuuid().tostring(); is far correct?
this might too. have gone method too, needed wider user access control. should take @ ssl. go method suits needs.
Comments
Post a Comment