Problem with using Request dispatcher in my login,jspx

Hi
I am using Jdev 11g and new to adf.
I am trying to work with adf security.
I designed a login.jspx page and loginproxy.jspx accoridng to the following link
http://groundside.com/blog/DuncanMills.php?title=j2ee_security_a_jsf_based_login_form&more=1&c=1&tb=1&pb=1
I have added this code in login.java
     ExternalContext ectx =    FacesContext.getCurrentInstance().getExternalContext();
     HttpServletRequest request =    (HttpServletRequest)ectx.getRequest();
     HttpServletResponse response =    (HttpServletResponse)ectx.getResponse();
     RequestDispatcher dispatcher =   request.getRequestDispatcher("loginnew.jspx");
RequestDispatcher dispatcher =   request.getRequestDispatcher("j_security_check");
    request.setAttribute("j_username", username);
    request.setAttribute("j_password", password);
     dispatcher.forward(request,response);
When it tries to execute dispatch statement, it goes in an infinite loop and finally gets me a stack overflow error and also in the cosole it prints series of exceptions like
ActionListenerImpl><processAction> javax.servlet.ServletException: javax.servlet.ServletException: java.lang.NoClassDefFoundError: Could not initialize class oracle.adf.controller.ControllerException
javax.faces.el.EvaluationException: javax.servlet.ServletException: javax.servlet.ServletException: java.lang.NoClassDefFoundError: Could not initialize class oracle.adf.controller.ControllerExceptionI have to validate the user against database hence i created a login.jspx with a backing bean so that i can access the username and password and validate the credentials against db and redirect user to the appropriate page.
The functionality i want to implement is very simple but i just cant get it to work using adf security.
any help is highly appreciated.
thanks
at

Hi Pedja,
Thanks for the prompt reply.
I have been following the link you mentioned to create ADF security and successfully implementedthe first part where if i directly give any internal page url it redirects me back to login page.
Instead of using weblogic-sql authenticator, i wanted to manually authenticate the user in loginbean.java where i check the username passowrd against the db.
I had also implemented the method to access username,password mentioned in the following thread
Re: ADF security on my jspx  page as login page
Insted of using authentication.login, i am calling the db method to do the validation.
The thing is after my db validation it does redirect me to the success page(menu.jspx). but when i click links on menu.jspx it redirects me back to login page.
so i understand that user is not yet set in the session.
I am stuck at the point how do i code the login.jspx, currently my login.jspx does not have any j_security_check and i think this is what is creating the problem.
while searching for adding jsecurity in jspx i landed on the blog of 2006 and started using that.
Can you please point me to some link which explains how to code login.jspx , i have been trying hard for couple of days.
Thanks again
ash

Similar Messages

  • I am going to buy unlocked iphone 5.. i will be going to india nxt months and will stay there for a while... so my question is will i get warrenty in india.. and will there be any problem with using indian sims..?? thnx for the help..

    i am going to buy unlocked iphone 5.. i will be going to india nxt months and will stay there for a while... so my question is will i get warrenty in india.. and will there be any problem with using indian sims..?? thnx for the help..

    The warranty for the iPhone is not and has never been International.
    Warranty and support are ONLY valid in the country of origin.  The only exception is the EU where the entire EU is treated as one country.
    If the device will be used in India, buy it in India.
    An unlocked iPhone will work on any supported GSM carrier world wide.  The LTE portion of a US purchased, unlocked iPhone is unlikely to work outside North America as it does not support the appropriate bands used in other countries.

  • I have two Iphones with different email addresses sharing one Apple ID. Will that cause problems with using messaging and FaceTime?

    I have two Iphones 5 with different email addresses sharing one Apple ID account.Both are using IOS 8.
    I would like to set up a new Apple Id for one of the phones and remove it from the old account.
    If I do that, can I move all of the purchased apps and songs to the new Apple account?
    Also, will sharing one Apple ID account with two devices cause problems with using messaging and FaceTime?

    Sharing an iCloud account between two devices can be done without causing issues with iMessage and FaceTime, just go into Settings for each of these functions and designate separate points of contact (i.e. phone number only, or phone number and unique email address).  While that works, you'll then face the problem where a phone call to one iPhone will ring both if on the same Wi-Fi network -- but again, that can be avoided by changing each phone's settings.
    Rather than do all that, don't fight it -- use separate IDs for iCloud.  You can still use a common ID for iTunes purchases (the ID for purchases and iCloud do not have to be the same) or you can use Family Sharing to share purchases from a primary Apple account.

  • I purchased Adobe Creative Suite C2 and have been using it for years on the same computer no problem with using it. Recently upon opening Photoshop I received a pop up window saying due to Adobe Software security we need you to activate your CS2 software.

    I purchased Adobe Creative Suite C2 and have been using it for years on the same computer without any problems with using it. Recently upon opening Photoshop I received a pop up window saying due to Adobe Software security we need you to activate your CS2 software. I tried, phone activation, web activation, nothing is working. I have the serial number and my Adobe account information. Any suggestions?

    Error: Activation Server Unavailable | CS2, Acrobat 7, Audition 3
    Mylenium

  • Problem with use of COM+ Transaction and DB Transaction

    Problem with use of COM+ Transaction and DB Transaction
    We build a Web site that use sometime COM+ Transaction and sometime DB
    Transaction. If we use a COM+ Transaction and a few seconds later we try to use
    a Database Transaction (OracleConnection.BeginTransaction), we get the error
    Connection is already part of a local or a distributed transaction
    Of course the error does not produce everytime; it takes some try before we get
    the problem. And of course, if i use pooling=false on the connection string,
    the problem does not appear.
    i run the Web page
    and push the COM+ Transaction and DB Transaction one after the other for some
    times and the problem should appear.
    Environment: Windows server 2003, .Net Framework 1.1, ODP.Net 9.2.0.401,
    Database Server 9.2.0.4

    > Why in form builder can't I...
    Is this happening at runtime or at buildtime? You'll need to provide more info on what you are actually doing that's causing the problem.
    Regards,
    Robin Zimmermann
    Forms Product Management

  • Problems with use cases in JDeveloper 11.1.1.1.0

    Use cases made with JDeveloper 11.1.1.0.2 can not be used and edited in JDeveloper 11.1.1.1.0.
    Same problems with Use Case Diagrams.
    And it seems to be impossible to create new use cases in JDeveloper 11.1.1.1.0.
    What are the differences between 11.1.1.0.2 and 11.1.1.1.0 if you look at use cases??

    In JDeveloper 11.1.1.0.2 each use case has one file with the folllowing name: *.xhtml_usc.
    In JDeveloper 11.1.1.1.0 each use case has two files with a names like *.xhtml_usc and *.uml_usc (after standard migration with JDeveloper). I can still edit the *.xhtml_usc files, but I have no idea what to do with the *.uml_usc files. I can only open a Property-editor, but the properties I see have no relation with the text I used in my original use cases . New use cases only have a *.uml_usc file and a Property-editor. In javadoc the new use case does not appear.
    My question is: why do I have two different use case files in JDeveloper 11.1.1.0 and how can I use the Property editor??

  • AxWindowsMediaPlayer problem with using subtitle sami.file in winform

    Hello every body
    I have a problem with using sami caption in axWindowsMediaPlayer;
    how can I use it?
    I used
    axWindowsMediaPlayer1.closedCaption.SAMIFileName="FileNameAddress";
    and
    axWindowsMediaPlayer1.ShowPropertyPages();//and select sami file
    but in both ways the subtitle is not shown in my axWindowsMediaPlayer1 control;
    please help me for solving this problem

    Hi ,
    As i know the Synchronized Accessible Media Interchange (SAMI) file must use an .smi or .sami file name extension.
    set the smi-file direclty like following
    AxWindowsMediaPlayer.closedCaption.SAMIFileName = "subtitles.smi";
    Please also refer here
    for more details.
    Follow the steps below for your Windows Media Player to display captions and subtitles.
    http://support.3playmedia.com/entries/21934486-windows-media-files-windows-media-player-settings
    Related thread, please note the Style secttion.
    http://answers.microsoft.com/en-us/windows/forum/windows_7-pictures/wmp-12-doesnt-play-sami-files-closed-captions/96fe98b7-1cdf-41f5-aa9e-a4e55fd07c0a
    In addition, Could you please provide your smi or sami file and full code? It could be better to help us do some test on my side.
    Have a nice day!
    Kristin
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • I am having problem with using the Basic brush definition

    I am having problem with using the Basic brush definition. When I try to click on it will not allow me to use it and will automatically use the 5 pt. oval brush definition. The only way I can use the basic brush is after I have already drawn something and then I have to click on the stroke and then press basic. This is incredibly annoying and if anyone could help I would greatly appreciate it. (I have Adobe CS6)

    for whatever reason, the basic 'brush' you see in the brushes palette effectively means removing any brush from a path. to draw with the brush tool you need a brush defined. in your case the last one selected being the 5 pt oval one.

  • I am having problem with using my Basic brush definition

    I am having problem with using the Basic brush definition. When I try to click on it will not allow me to use it and will automatically use the 5 pt. oval brush definition. The only way I can use the basic brush is after I have already drawn something and then I have to click on the stroke and then press basic. This is incredibly annoying and if anyone could help I would greatly appreciate it. (I have Adobe CS6)

    Basic is not a brush, only a starting point for you to make a brush. Load the real brush you want before beginning to draw.

  • In FF4.0.1 problem with using HTML creator in WebCT. WHY? Not a problem in FF4.0.0

    In FF4.0.1 problem with using HTML creator in WebCT. WHY? Not a problem in FF4.0.0

    Hi Shane,
    I passed through all the described problems in the list, and after doing several tests the error that you described is always present if the "jpcsclite_en_US.properties" is not present in the same place of the "jpcsclite.properties". I really don't know the reason, I just copied and pasted the same file, renamed the copy and the error was gone... though both of them include the line where the .dll is found!
    That's how it worked for me, but if anybody knows how it works without that dirty trick, it would be good.
    Regards,
    Leandro
    PS: Just in case that somebody is using the version JCSDK3.0, I did not find the .dll in that version, but in the JCSDK2.2.2 *(:-S)*

  • I have a problem with using MacBook Pro as wifi router when connected to ethernet

    I have a problem with using MacBook Pro as wifi router when connected to ethernet. The Airport icon changes to show a laptop inside, my iPad shows connected (I think) but Safari will not operate. I tried pinging my iPad, it seems to see the iPad, but no connection to Safari or to other apps such as Good on the iPad. I have read many posting and tried repeatedly via Sharing in Systems Preferences, but no luck. Suggestions to fix, or is this a Lion problem?

    Usually this is a problem related to the domain name server address. If you open Network preferences, select your Ethernet port then click on the Advanced button then on the DNS tab. You will likely see an entry like 10.0.1.1 already listed. Click on the Add [-] button and enter 208.67.222.222 then click on the OK button and then on the Apply button.  See if this helps.
    if it does not help then repeat the above but with the Airport port.

  • After installing Snow Leopard problems with using any of my Helvetica fonts

    I've never really have a problem with any of apple's products until now.
    After installing Snow Leopard I've found problems with using any of my Helvetica fonts,
    which is a BIG problem if you work in DTP or print. You CAN'T remove the system version of Helvetica, and replace it with your own anymore.
    Also Flash CS4 seems to be a dead duck, as after about 5-6 seconds of loading the program it crashes with a "KERNPROTECTIONFAILURE".
    <title edited by host>

    Thanks Tom but the original post title was "Work in DTP, don't install snow leopard", but of course apple were unhappy with the title. I know the issue/problem has been discussed for months, the real problem is that it shouldn't be a problem which everyone has to find work arounds for.
    After 4 days of playing about, I've finally got flash CS4 working and Quarkxpress was also a big problem for a few months. Printer description (PPD) files which snow leopard doesn't like, but worked in tiger & leopard.....means I can't use my two A3 inkjets for proofing anymore.
    I'm just disappointed by snow leopard

  • Unable to use Request Dispatcher; Duke $ Post;

    I am using a Controller Servlet to transfer control to a JSP using Request Dispatcher within doPost()
    RequestDispatcher rd;
    rd=req.getRequestDispatcher(URL);
    rd.forward(req,resp);
    I am seting a request object
    req.setAttribute("XXX",obj.func());
    prior to the Redirect;
    The page gets redirected to a JSP. I am unable to access req object in there.
    if i use
    String XXX = req.getAttribute("XXX");
    i get an error in the jsp as
    "req cannot be resolved"
    Do i need to import some directives? Please Reply

    The page gets redirected to a JSP. I am unable to
    access req object in there.
    if i use
    String XXX = req.getAttribute("XXX");
    i get an error in the jsp as
    "req cannot be resolved"
    Do i need to import some directives? Please ReplyThat's simple. Your req (which is the HttpServletRequest object) in the servlet becomes request in the JSP. That's always there. The compiler would not recognize req
    Use request.getAttribute("XXX"); in JSP
    Regards
    ***Annie***

  • Unable to view Behance - Oops! There was a problem with your request

    Hi,
    Today, I am unable to view Behance and I'm unable to log in as well.
    Received the error message - Oops! There was a problem with your request.
    Please refresh the page to try again.
    Contact support if the problem persists.
    Does anyone has the same problem, Anyone knows how to resolve this?

    Hi - we can definitely help! To have a private convo where we can give you your accont info, please write us a ticket here and someone will get back to you ASAP:
    Behance Support & Forum : Submit a request for assistance

  • Hi- have problems with ibook  osx 10.6 to login mobile me

    hi- have problems with ibook  osx 10.6 to login mobile me
    pls any idea helps
    tia

    MobileMe was discontinued. Now, it's iCloud, and iCloud requires OS X Lion or Mountain Lion

Maybe you are looking for

  • How can I convert a number field in a to Date?

    I have two columns in a table, and i would like to concate this two fiels to read Januaray-2010 CREATE TABLE "CATDB"."SC_DTL_MEASURE_DETAIL"            "TIME_YEAR"                 NUMBER(*,0),            "TIME_INCREMENT"            NUMBER(*,0),    )T

  • Configuration in Solman and Satellite system for Support message creation ?

    Hi , I want to send a support message to solman from the ( help menu -> create support message ) of my satellite system. any one tell me the settings that i have to make in both the sattelite system and the solman  for sending a support message.

  • Transferring files via Target Mode

    Hello, I just got my Mac Pro and I'm trying to transfer some files and programs from my existing G4... I have heard about using the "Target Mode" to do this, but when I tried no luck. Here's what I attempted to do: attmept #1. G4 is connected to my d

  • HT1414 my iphone has problem in open and if it open iphone shut  down after few minuate

    I have bought this iphone5 from Hannova German in April2013 and I am using this iphone5 in Nepal. In Nepal there is no authorized dealer. This problem came just from 15th July 2013. It has problem in opening and if it open it shut down after few minu

  • HT5293 how to upgrade from OS X (10.6.8) to OS X 8

    I have an old iMac currently running on OS X version 10.6.8. I don't know what animal this is! I'm not happy with the reviews for Mavericks so I want to upgrade to OS X version 8 - again, I don't what animal. How can I do this? thanks