0

I'm a beginner in Web Designing. I have an application which requires login. After i login on every next page i want to use the user's username for storing and retrieving data from mysql database. How to do this? Please help me out!

Naveen K K
  • 23
  • 5

1 Answers1

0

First: You have to learn about JAAS: really complete and technical http://docs.oracle.com/javase/8/docs/technotes/guides/security/jgss/tutorials/AcnOnly.html

In fact it depends of your application server and the login module you want to use for login (tomcat; glassfish; kerberos; database ...)

Second: Think also to reuse cloud authentication like OpenID Connect and provider like Google, Yahoo!

Third: At the end you will found information in the Principal see What is the meaning of Subject vs. User vs. Principal in a Security Context?

Community
  • 1
  • 1
spopoff
  • 1
  • 3