Web Connection
Problem with authentication workekd in ver 7.4 but not 8,3
Gravatar is a globally recognized avatar based on your email address. Problem with authentication workekd in ver 7.4 but not 8,3
  Jim Day
  All
  May 7, 2025 @ 02:26am

these come back empty

gUsrName = LOWER(Session.GetSessionVar("_authenticateduser"))
gUsrFullName = Session.GetSessionVar("_authenticatedusername")
the following is in wwsession
<_authenticateduser>jim</_authenticateduser>
<_authenticatedusername>Jim Day</_authenticatedusername>

any ideas why i can not retrieve the variables?

Gravatar is a globally recognized avatar based on your email address. re: Problem with authentication workekd in ver 7.4 but not 8,3
  Rick Strahl
  Jim Day
  May 7, 2025 @ 07:06am

You don't need to get them out that way. If you're using Authentication and have enabled, you can use Process.cAuthenticatedUser and Process.cAuthenticatedUserName.

That said it should work, unless you're not actually have session set up properly.

It works for me:

This is in the sample app...

Make sure your process class enables sessions with InitSession().

+++ Rick ---

Gravatar is a globally recognized avatar based on your email address. re: Problem with authentication workekd in ver 7.4 but not 8,3
  Jim Day
  Rick Strahl
  May 7, 2025 @ 04:22pm
pcCookieName = Request.GetCookie("WhoGoes")
process.cauthenticateduser 
process.cauthenticatedusername 

The pcCookieName points to wwsession record that has an empty var field. process user info was also empty.

Each time I do login another wwsession record is generated. Those records have the user information in the var field.

the hit count on the first wwsession record is incremented but in the wwsession records with the var field filled only has a count of 1.

Any Ideas?

Thanks

Gravatar is a globally recognized avatar based on your email address. re: Problem with authentication workekd in ver 7.4 but not 8,3
  Rick Strahl
  Jim Day
  May 7, 2025 @ 10:34pm

Cookies are not session variables...

+++ Rick ---

Gravatar is a globally recognized avatar based on your email address. re: Problem with authentication workekd in ver 7.4 but not 8,3
  Jim Day
  Rick Strahl
  May 10, 2025 @ 06:04pm
pcCookieName = Request.GetCookie("WhoGoes")
SELECT wwsession
IF sessionid<>pcCookieName
   lcVars = Vars
   LOCATE FOR sessionid = pcCookieName
   replace Vars WITH lcVars
ENDIF 

This code is required to get my login information into the proper wwsession record.

Gravatar is a globally recognized avatar based on your email address. re: Problem with authentication workekd in ver 7.4 but not 8,3
  Jim Day
  Jim Day
  May 11, 2025 @ 04:53pm

Not sure why but 7.4 version has the same issue. So it has to do with my new computer.

Jim

© 1996-2025