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 7828031
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T10:08:43+00:00 2026-06-02T10:08:43+00:00

In my web app, I am using form-based login. I have a scenario where

  • 0

In my web app, I am using form-based login. I have a scenario where I have to validate the users present in a different database in addition to the data of the table set in login-config.xml.

So,I was thinking of this flow:

User tries to access a secured resource -> if No active session,will be redirected to login form -> User enters his credentials -> j_security_check authenticates as per login-config.xml -> if authentication succeeds, well and good, else redirect to a jsp error page, where I check if the user is present in the other DB(Active directory to be specific.I already have the code to validate the credentials) and create a session on success -> else redirect to error page

Is the part highlighted above in bold possible at all??

I have read in some articles that once the authentication is given to j_security_check, there is no way to over rule it. Is it true???

Is there any other possible solution for this problem (apart from adding the users from other db to the table specified in the login-config.xml or modifying the login-config.xml)??

(I am using Jboss)

Thanks.

  • 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-02T10:08:48+00:00Added an answer on June 2, 2026 at 10:08 am

    Create Servlet Filter that would catch URL to which user is redirected after j_security_check. In this filter check user credentials in the other database.

    If the check is succesful add to session boolean value that would reflect that fact. If the check fails remove session (HttpSession.invalidate() method) and redirect user to the error page.

    Probably the filter would catch all URL-s that need authorization. In you filter check if there is boolean flag, so you don’t do the database check again and again.

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

Sidebar

Related Questions

I have created a simple web app/form using google app engine. the site is
I am developing a web app using servlets and jsps. I have a question
I have a web app using forms authentication and I have restricted a folder
I have developed a web app using a webservice. Everything works fine in the
I have a web app using Hibernate, and I am attempting to persist some
I am devloping a web app using Drupal. My form contains two buttons, Submit
I have a web app using thin clients (bosanova terminals) as the front end
I am working on an iPhone Web App using HTML & CSS. I have
I need to implement a web app, but instead of using relational database I
I have been using the Windsor IoC Container for my web-based application, to resolve

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.