Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8097757
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T21:51:45+00:00 2026-06-05T21:51:45+00:00

I created a login page using spring_security_check. Here: <form name=’f’ action=/sec_test/j_spring_security_check method=’POST’> <table> <tr>

  • 0

I created a login page using spring_security_check.
Here:

<form name='f' action="/sec_test/j_spring_security_check" method='POST'>

    <table>
        <tr>
            <td>User:</td>
            <td><input type="text" name="j_username" value=''>
            </td>
        </tr>
        <tr>
            <td>Password:</td>
            <td><input type="password" name="j_password" />
            </td>
        </tr>
        <tr>
            <td colspan='2'><input name="submit" type="submit"
                value="submit" />
            </td>
        </tr>
        <tr>
            <td colspan='2'><input name="reset" type="reset" />
            </td>
        </tr>
    </table>
</form>

But I can not have access to j_username afterward.

I’ve tried:

* request.getParameter(“j_username”)
* request.getAttribute(“j_username”)
* request.getAttribute(“j_username”)
* request.getUserPrincipal().getName()
* request.getRemoteUser()

From all of them, all I’m getting is null!

Any idea what to do?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T21:51:47+00:00Added an answer on June 5, 2026 at 9:51 pm

    Spring does authentication for you based on type of the authentication configured in your configuration file. Once authentication is successful it redirects to the login success url(say /login.htm). Because it redirects to /login.htm, you will not get any request parameter (username/user role) unless explicitly set in request in overriden authentication filter.

    After successful authentication spring stores the authenticated information in security context, including user roles. You can access this information from SecurityContext. Refer – link

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I created Aspx login page and ext js login form in it ExtJs code
I've created a login page and in the db table i have a field
I want to create a login page using Servlet & JSP. I ve created
I have created a simple login page for asp.net which takes in user name
Im trying to create a iPhone Objective C login page using PHP/MySQL to authenticate.
I have created login page forced login in several pages. Now i need to
I've created a login page and registration page and now I want to use
I have created Login forms and registration forms for a website. The form is
i am using spring framework,apache,tomcat and the login page is handled with spring security
I created this simple login page. It's supposed to display in the label text

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.