UTF8 handling in OC4J

Dear all, I got some problems in CMP ejb dealing with UTF-8 charset.
My OS platform is traditional chinese win2000, installing OC4J 9.0.2
and 9iJdevleoper. My 9iDB Server with UTF8 characterset is on an AIX server.
Through my 9iJdeveloper and OC4J, I created a CMP and got it deployed. But no matter what I tried, the CMP sample client inserted record in Big5 encoding into the DB rather than in UTF-8.
I set the CMP project complier characterset to UTF-8
What else do I need to set(e.g. *.xml OC4J config files) ?
rgds,
gabriel

Dear All,
I want to display japanese characters in the browser from servlet, so i set the following things in my program,
res.setContentType( "text/html; charset=UTF-8");
     PrintWriter out = res.getWriter();
     out.println("<html>");
     out.println("<h1>Hello World111</h1>");
out.println("HIpoOIIlpt/gj=");
     out.println("</body></html>");
But I'm not able to see the japanese chars instead some junk chars are displayed.
Please help me, this is very urgent.
Thanks in Advance,
Dayalan

Similar Messages

  • Exception Handling with OC4J Web Services

    Hi,
    I want to throw some custom exceptions from my web services, based upon my business logic. From the documents I came to know that I can use "javax.xml.rpc.soap.SOAPFaultException" for the same. Following is the sample web service code which I'm trying in my environment.
    import javax.ejb.Stateless;
    import javax.jws.WebMethod;
    import javax.jws.WebService;
    import javax.xml.namespace.QName;
    import javax.xml.rpc.soap.SOAPFaultException;
    @WebService
    @Stateless
    public class TestService {
         @WebMethod
         public void greeting()
              throw new SOAPFaultException(new QName("uri", "local"),
         "My Fault String", "My Fault Actor", null);
    Deployment of the web service goes fine and on the invocation of the "greeting" operation the exception is being thrown. But the problem is that, the soap response, which my web service client receives is as of follows,
    <env:Envelope
    xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:ns0="http://service.csm.nb.md.inglife.jp.co/">
    <env:Body>
    <env:Fault>
    <faultcode>env:Server</faultcode>
    <faultstring>Internal Server Error (Caught exception while handling request: oracle.oc4j.rmi.OracleRemoteException: javax.xml.rpc.soap.SOAPFaultException: My Fault String; nested exception is: javax.xml.rpc.soap.SOAPFaultException: My Fault String)</faultstring>
    </env:Fault>
    </env:Body>
    </env:Envelope>
    This means that OC4J again wraps the SOAPFaultException thrown by me. Is there any way by which I can avoid the further wrapping of my exceptions? If there is anything wrong in my approach please do let me know.
    Regards,
    Dipu

    This is one of the "classic" design problems in this kind of architecture. And, unfortunately, the answer is "it depends on how you think you need to handle it." And I'm sure there are plenty of "gurus" that will tell you one way or another is the only way to do it.
    I'll be more honest: I'll give you a couple of personal suggestions, based on experience in this architecture. These are suggestions - you may do with them what you will. I will not say this is the best, most correct, or even remotely relevant to what you're doing.
    If it's simple data validation for "typing" (e.g. String, number, Date, etc.), that is taken care of when you attempt to stuff in the information into the appropriate DTO. If it's more "sophisticated" than that (must be in a certain range, etc.), that particular checking should probably be delegated from your Controller to a helper class. That not only saves the "expense" of transmitting the information back and forth across the wire, it's "faster" to the end user so say "Ooopsie" by redirecting back to the form right then. Basically the same thing if the types are wrong.
    That only leaves the "big" problems in the business layer (EJBs), where you have to deal with concurrency, database failures, etc. Generally these kinds of exceptions are thrown back to to the Controller in one of two forms:
    1) a sublass of RuntimeException, which signals that some Very Bad Things have happened in your container. EJBException is one like that and you can see where it's being thrown from.
    2) a subclass of Exception, also called "application exceptions." They are usually something like a "duplicate record" or a validation-like error (which you mentioned) like a missing field. They're used as a signal to a failure in the logic, not the container. That way you have to decide at what layer of your architecture they should be handled and/or passed on to the next.

  • Session handling on OC4j

    Hi !
    I have two web applications running on OC4J; A and B.
    Application A contains data that are needed by application B.
    Application B accesses the data through a set of jsp's defined on A.
    Problem:
    The data is created with one sessionID. Everytime the jsp's are called from B, there is a new sessionID created on A.
    Hence the jsp's are unable to find the data created in the first place.
    Are there any way I can configure OC4J to ensure that I remain in the same session each time I access A ??
    This kind of solution is already up and running on Apache Tomcat without any problems. The problems occur on OC4j.
    Ted

    Hello Ted,
    Sharing the session between Web applications breaks the servlet specifications, see:
    * "SRV.7.3 Session Scope:
    HttpSession objects must be scoped at the application (or servlet context) level. The underlying mechanism, such as the cookie used to establish the session, can be the same for different contexts, but the object referenced, including the attributes in that object, must never be shared between contexts by the container."
    * SRV.9.2 Relationship to ServletContext:
    The servlet container must enforce a one to one correspondence between a web application and a ServletContext. A ServletContext object provides a servlet with its view of the application
    This is why it is not supported by OC4J.
    One work around is to use a persistence layer, for example saving the information you need to share between applications in your database.
    In the same time, Oracle understands the importance of this requirement, so we will support "Shared Session between Web applications" in OC4J 10g (10.1.3) production.
    Regards
    Tugdual Grall

  • How OC4J handles fatal error codes

    1. Does OC4j cleans/closes all connections in the connection pool when OC4J detects fatal error codes? Does OC4J really work as per oracle documentation? Can I get an example showing how is it done?
    Oracle Documentation says:
    For each data source defined in data-sources.xml, you can define fatal error codes that indicate that the back-end database with which the data source communicates is no longer accessible. When OC4J detects one of these error codes (stated when a SQLException is thrown by the JDBC driver), OC4J will clean its connection pool. That is, it closes all connections in the connection pool. For Oracle, the predefined fatal error codes are: 3113, 3114, 1033, 1034, 1089, and 1090.
    2. When OC4J detects fatal error codes defined in an connection pool in data-sources.xml, how connections in the connection pool are handled by OC4J?
    3. When OC4J detects fatal error codes on one connection to Oracle database, then will OC4J restore / close the connection back to connection pool?
    4. Does OC4J really work on fatal error codes?
    Sample code of connection pool I used in data-sources.xml file where I defined fatal error codes:
    <connection-pool name="FSCMDS" inactivity-timeout="30" initial-limit="5" max-connections="5" validate-connection-statement="select * from dual">
    <connection-factory factory-class="oracle.jdbc.pool.OracleDataSource" user="" password="" url="" commit-record-table-name="">
    <proxy-interface sql-object="PreparedStatement" interface="oracle.jdbc.OraclePreparedStatement"/>
    <*fatal-error-codes*>
         <*error-code code="3113"*/>
    </*fatal-error-codes*>
    </connection-factory>
    </connection-pool>
    Please post answers on these questions...
    Thanks
    Venkat

    This forum is for general database questions, post your question here:
    OC4J
    Werner

  • OC4J Log Error Interpretation

    Hi, I am trying to debug an authentication issue using a system based on the information in this article: http://www.oracle.com/technology/products/jdev/howtos/1013/oc4jjaas/oc4j_jaas_login_module.htm
    IE database/datasource based authentication.
    I am getting the following error in the applications OC4J log every time a login attempt is made, no error is seen from the application, authentication simply fails.
    When I had the recommended code for fine logging in the j2ee-loggin.xml file (<logger name="oracle.j2ee.security.oc4j" level="FINE" useParentHandlers="false">
    <handler name="oc4j-handler"/>
    <handler name="console-handler"/>
    </logger>) there was no information at all recorded in the OC4J log, not until I removed the extra logger code from that file did entries such as the following begin appearing in the log file. What could be going wrong here? Why is the login process generating a null pointer error and why would the log file not be written too when the fine logging code was added to the config file? Any idea's? All I can really gain from this error message is that the DBTableOraDataSourceLoginModule is at some stage atleast being referenced or called.
    Log Message: September 3, 2007 10:59:51 AM EST
    Component Name OC4J Component ID j2ee
    Host Network Address 172.etc Message Level 1
    Module ID security User ID SYSTEM
    Execution Context ID 172.etc Execution Context Sequence 0
    Host Name usatl01 Thread ID 12
    Message Type Warning
    Message Text
    java.lang.NullPointerException
    at javax.naming.InitialContext.getURLScheme(InitialContext.java:228)
    at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:277)
    at javax.naming.InitialContext.lookup(InitialContext.java:351)
    at oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule.performDbAuthentication(DBTableOraDataSourceLoginModule.java:484)
    at oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule.login(DBTableOraDataSourceLoginModule.java:335)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at javax.security.auth.login.LoginContext.invoke(LoginContext.java:769)
    at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
    at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
    at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
    at oracle.security.jazn.oc4j.OC4JUtil.doJAASLogin(OC4JUtil.java:241)
    at oracle.security.jazn.oc4j.GenericUser$1.run(JAZNUserManager.java:818)
    at oracle.security.jazn.oc4j.OC4JUtil.doWithJAZNClsLdr(OC4JUtil.java:173)
    at oracle.security.jazn.oc4j.GenericUser.authenticate(JAZNUserManager.java:814)
    at oracle.security.jazn.oc4j.FilterUser.authenticate(JAZNUserManager.java:1143)
    at com.evermind.server.http.EvermindHttpServletRequest.getUserPrincipalInternal(EvermindHttpServletRequest.java:3601)
    at com.evermind.server.http.AJPHttpServletRequest.getUserPrincipalInternal(AJPHttpServletRequest.java:261)
    at com.evermind.server.http.HttpApplication.checkAuthenticationAndAuthorize(HttpApplication.java:6332)
    at com.evermind.server.http.HttpApplication.getRequestDispatcher(HttpApplication.java:3009)
    at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:736)
    at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:448)
    at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:302)
    at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:190)
    at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
    at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
    at java.lang.Thread.run(Thread.java:595)
    Supplemental Text
    javax.security.auth.login.LoginException: java.lang.NullPointerException
    at javax.naming.InitialContext.getURLScheme(InitialContext.java:228)
    at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:277)
    at javax.naming.InitialContext.lookup(InitialContext.java:351)
    at oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule.performDbAuthentication(DBTableOraDataSourceLoginModule.java:484)
    at oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule.login(DBTableOraDataSourceLoginModule.java:335)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at javax.security.auth.login.LoginContext.invoke(LoginContext.java:769)
    at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
    at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
    at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
    at oracle.security.jazn.oc4j.OC4JUtil.doJAASLogin(OC4JUtil.java:241)
    at oracle.security.jazn.oc4j.GenericUser$1.run(JAZNUserManager.java:818)
    at oracle.security.jazn.oc4j.OC4JUtil.doWithJAZNClsLdr(OC4JUtil.java:173)
    at oracle.security.jazn.oc4j.GenericUser.authenticate(JAZNUserManager.java:814)
    at oracle.security.jazn.oc4j.FilterUser.authenticate(JAZNUserManager.java:1143)
    at com.evermind.server.http.EvermindHttpServletRequest.getUserPrincipalInternal(EvermindHttpServletRequest.java:3601)
    at com.evermind.server.http.AJPHttpServletRequest.getUserPrincipalInternal(AJPHttpServletRequest.java:261)
    at com.evermind.server.http.HttpApplication.checkAuthenticationAndAuthorize(HttpApplication.java:6332)
    at com.evermind.server.http.HttpApplication.getRequestDispatcher(HttpApplication.java:3009)
    at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:736)
    at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:448)
    at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:302)
    at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:190)
    at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
    at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
    at java.lang.Thread.run(Thread.java:595)
    at javax.security.auth.login.LoginContext.invoke(LoginContext.java:872)
    at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
    at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
    at java.security.AccessController.doPrivileged(Native Method)
    at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
    at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
    at oracle.security.jazn.oc4j.OC4JUtil.doJAASLogin(OC4JUtil.java:241)
    at oracle.security.jazn.oc4j.GenericUser$1.run(JAZNUserManager.java:818)
    at oracle.security.jazn.oc4j.OC4JUtil.doWithJAZNClsLdr(OC4JUtil.java:173)
    at oracle.security.jazn.oc4j.GenericUser.authenticate(JAZNUserManager.java:814)
    at oracle.security.jazn.oc4j.FilterUser.authenticate(JAZNUserManager.java:1143)
    at com.evermind.server.http.EvermindHttpServletRequest.getUserPrincipalInternal(EvermindHttpServletRequest.java:3601)
    at com.evermind.server.http.AJPHttpServletRequest.getUserPrincipalInternal(AJPHttpServletRequest.java:261)
    at com.evermind.server.http.HttpApplication.checkAuthenticationAndAuthorize(HttpApplication.java:6332)
    at com.evermind.server.http.HttpApplication.getRequestDispatcher(HttpApplication.java:3009)
    at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:736)
    at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:448)
    at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:302)
    at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:190)
    at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
    at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
    at java.lang.Thread.run(Thread.java:595)

    Well, still struggling with this one.. although i've managed to get fine oc4j security logging enabled through the console, the error stream now follows this sequence of events at each login attempt :
    [DBTableOraDataSourceLoginModule]login called on DBTableLoginModule
    [DBTableOraDataSourceLoginModule]Calling callbackhandler ...
    [DBTableOraDataSourceLoginModule]Username returned by callback = TATKINS
    [DBTableOraDataSourceLoginModule]Username changed to case as defined by null to TATKINS
    [DBTableOraDataSourceLoginModule]Abort called on LoginModule
    java.lang.NullPointerException
    at javax.naming.InitialContext.getURLScheme(InitialContext.java:228)
    at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:277)
    at javax.naming.InitialContext.lookup(InitialContext.java:351)
    at oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule.performDbAuthentication(DBTableOraDataSourceLoginModule.java:484)
    at oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule.login(DBTableOraDataSourceLoginModule.java:335)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         etc etc...
    JAAS-OC4J: Authentication failure for user: TATKINS
    JAAS-OC4J: Membership check for group: USER failed for user: anonymous
    What i cant work out is what is causing the login module to abort and raise a null pointer exception. Could this be due to a configuration mistake in the console manager or one of the xml files prior to deployment? I just have no idea how to approach fixing this issue.
    I really would appreciate some assistance, 5+ days trying to get this working. I had this working on jdeveloper embedded oc4j, and all the tute's on standalone deployment pass off the configuration of standalone as simple compared to embedded, yet don't go into enough detail to get it working, atleast from my perspective.

  • ODL log file registration in 10.1.0.2 with B2B installed

    Hi,
    we enabled ODL to default log file for our application by adding this handler
    <!-- In live deployment useParentHandlers='false' to disable console logging -->     
    <logger name='com.gem.ws.proxy' level='INFO' useParentHandlers='true'>
    <handler name='oc4j-handler'/>
    </logger>
    to j2ee-logging.xml for our OC4J instamce.
    It seems that default ODL log file in j2ee/home/log/home_default_island_1/oc4j is not registred by OAS log viewer.
    I tried to experiment with editing files in diagnostics/config/registration and I succeeded only with adding :
    <log path='j2ee/home/log/home_default_island_1/oc4j' componentId='OC4J'>
         <logreader type='ODL'/>
         <logviewer ComponentName='home' ComponentType="OC4J"
              LogType='OC4J_APPLICATION'/>
    </log>
    to INTEGB2B.xml
    However this is not clear solution and ODL log file is registred under incorect attributes. I need to edit the OC4J_logs.xml and register my ODL file here, but I was unable to get it work after many experiments.
    Could anybody post valid XML to register default ODL file in logviewer of OAS 10.1.2???

    user469244,
    I assume you are referring to Oracle's JDBC driver. I am unfamiliar with the "oracle.jar" file. I use the "ojdbc14.jar" file and it does contain the "oracle.jdbc.driver.DatabaseError" class. What is this "oracle.jar" file you mention?
    Perhaps you could post the entire error message (and stack trace) you are getting, as well as the section of your code that is causing the error?
    Good Luck,
    Avi.

  • Urgent..................External third party security provider

    Hello!
    I am trying to deploy a web module in home OC4j on Oracle application server v.10.3.1.0 using Windows 2003 Active Directory.
    Knowing that in active directory I have a group whose DN is :CN=Administrators,CN=Builtin,DC=SWSERVER,DC=DGET,DC=COM
    and a user whose DN is CN=Administrator,CN=Users,DC=SWSERVER,DC=DGET,DC=COM
    the giving user is a member of the Group Administrators .
    In Security provider page, I add users and groups settings
    LDAP Group Name Attribute: cn
    LDAP Group Object Class: group
    LDAP Group Member Attribute:member
    LDAP User Name Attribute:name
    LDAP User Object Class :user
    I also map roles between Web application and Security provider.
    When I browse to the application in IE, I am prompted to enter user name and password. I entered Administrator password but not authenticated!!!!!!
    What should i put in security provider page????????? what should be the settings?????????????
    N.B: winodws people are encouraged to reply!!!!
    thank you in advance!!!

    several things could have gone wrong. Can you increase the logging level. Set it to TRACE:32 instead of NOTIFICATION:1 to see what is going on with your authentication.
    ../j2ee/home/config/jps-config.xml:
    <logger name='oracle.j2ee.security' level='TRACE:32'
    useParentHandlers='false'>
    <handler name='oc4j-handler'/>
    </logger>
    After restarting OC4J, you would monitor log.xml in your j2ee/home/log/oc4j directory to analyze what is going on.

  • Problem starting mig33

    How to set up my mobile phone nokia 6020. Error in http operation

    I have some progress, firs I switched on logging in j2ee-logging.xml file (changed level to TRACE:32):
    <logger name='oracle' level='TRACE:32' useParentHandlers='false'>
    <handler name='oc4j-handler'/>
    <handler name='console-handler'/>
    </logger>
    After starting oc4j, I see that it blocks when trying to start ascontrol application. So, I disabled it's autostart (in server.xml):
    <application name="ascontrol" path="../../home/applications/ascontrol.ear" parent="system" start="false" />
    And OC4J started normally - well, without the console. I'm still unable the start ascontrol application (using admin.jar).

  • Problem starting sqldeveloper over tunnel

    Hi there,
    I'm getting the following error when I try to define a connection to a database I'm connecting to over a tunnel.
    Failure -oracle/i18n/text/converter/CharacterConverterOGS
    I know the connectivity is OK, because I can connect just fine using sqlplus and another tool. I don't know for sure that this is related to the tunneling, but I know that I was connecting to another database yesterday through sqldeveloper just fine.
    Any ideas?
    Thanks in advance.

    I have some progress, firs I switched on logging in j2ee-logging.xml file (changed level to TRACE:32):
    <logger name='oracle' level='TRACE:32' useParentHandlers='false'>
    <handler name='oc4j-handler'/>
    <handler name='console-handler'/>
    </logger>
    After starting oc4j, I see that it blocks when trying to start ascontrol application. So, I disabled it's autostart (in server.xml):
    <application name="ascontrol" path="../../home/applications/ascontrol.ear" parent="system" start="false" />
    And OC4J started normally - well, without the console. I'm still unable the start ascontrol application (using admin.jar).

  • Closing Sessions

    Hello!
    I have got a Struts/ADF/BC4J application developed with JDeveloper 9.0.5.1 and deployed to oc4j 9.0.4.1!
    When i client connects to the application a new session is created. What happens when the user clicks the close icon of the browser? It seems that the connection is still alive and gets closed after a time. How should i solve this problem?
    What is the recommended way in session handling? (oc4j configuration, ...)
    Thanks
    Markus

    hello
    I noticed the same problem appearing (even more vividly) when i created a portal page using Oracle Portal for the Welcome page of the application. The main page come with Login/logout button (as a default). When the end user invokes the logout button then the login again, the application pages appears. The query function embedded in the application shows records from previous login.. Quite honestly, i was forcing the user to close the browser to avoid this behavior and usually it works, unless other instances of the browser are open, but this is not a solution
    Ammar

  • DBTableOraDataSourceLoginModule  Login-Exception

    Hello all,
    I use Frank Nimphius's LoginModule "DBTableOraDataSourceLoginModule" with embedded OC4J to authenticate.
    If my password and username are correct, the[b] LoginModule has no problem.
    Login-Information:
    18.10.2007 13:31:33 oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule login
    FEIN: [DBTableOraDataSourceLoginModule]Logon Successful = true
    18.10.2007 13:31:33 oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule commit
    FEIN: [DBTableOraDataSourceLoginModule]Subject contains 0 Principals before auth
    18.10.2007 13:31:33 oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule commit
    FEIN: [DBTableOraDataSourceLoginModule]Local LM commit succeeded
    18.10.2007 13:31:33 oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule commit
    FEIN: [DBTableOraDataSourceLoginModule]Subject contains 2 Principals after auth
    18.10.2007 13:31:33 oracle.security.jazn.login.module.db.DBTableOraDataSourceLoginModule commit
    FEIN: [DBTableOraDataSourceLoginModule]Cleaning internal state!
    My problem:
    If my password or username is wrong, an exception has been thrown:
    Exception Info:
    javax.security.auth.login.LoginException: Login Failure: all modules ignored
         at javax.security.auth.login.LoginContext.invoke(LoginContext.java:921)
         at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
         at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
         at java.security.AccessController.doPrivileged(Native Method)
         at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
         at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
         at oracle.security.jazn.oc4j.OC4JUtil.doJAASLogin(OC4JUtil.java:241)
         at oracle.security.jazn.oc4j.GenericUser$1.run(JAZNUserManager.java:818)
         at oracle.security.jazn.oc4j.OC4JUtil.doWithJAZNClsLdr(OC4JUtil.java:173)
         at oracle.security.jazn.oc4j.GenericUser.authenticate(JAZNUserManager.java:814)
         at oracle.security.jazn.oc4j.FilterUser.authenticate(JAZNUserManager.java:1143)
         at com.evermind.server.http.EvermindHttpServletRequest.getUserPrincipalInternal(EvermindHttpServletRequest.java:3659)
         at com.evermind.server.http.HttpApplication.checkAuthenticationAndAuthorize(HttpApplication.java:6332)
         at com.evermind.server.http.HttpApplication.getRequestDispatcher(HttpApplication.java:3009)
         at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:735)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:447)
         at com.evermind.server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:215)
         at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:117)
         at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:110)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at oracle.oc4j.network.ServerSocketAcceptHandler.procClientSocket(ServerSocketAcceptHandler.java:239)
         at oracle.oc4j.network.ServerSocketAcceptHandler.access$700(ServerSocketAcceptHandler.java:34)
         at oracle.oc4j.network.ServerSocketAcceptHandler$AcceptHandlerHorse.run(ServerSocketAcceptHandler.java:880)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)
    18.10.2007 13:38:33 oracle.security.jazn.oc4j.GenericUser authenticate
    How to solve the problem?
    Thanks in advance!
    Steven

    Hello Frank,
    Thanks a lot for your explaination. Now i understand, i added:
    <logger name="oracle.j2ee.security" level="FINE" useParentHandlers="false">
    <handler name="oc4j-handler"/>
    <handler name="console-handler"/>
    </logger>
    in the ...\embedded-oc4j\config\j2e-logging.xml.
    Thanks a lot for your help.
    Steven ZZD

  • The transaction-config and the  Phantom XML File

    I'm upgrading from 10.1.2 to 10.1.3, and there are some configuration changes that I can't find documentation for. My configuration is semi-complex, so I started by just using our current configuration files, and moved on from there.
    I get the following error on startup.
    06/04/26 11:10:32 Error initializing server: Unknown deployment tag in /u01/home/weblogic/lrs/server/application-deployments/orion-application.xml: <transaction-config>
    06/04/26 11:10:32 Fatal error: server exiting
    OK. That seems pretty easy on the surface. I need to pull the <transaction-config> element out of that file, right?
    So here's my problem.
    $ ls -l /u01/home/weblogic/lrs/server/application-deployments/orion-application.xml
    ls: /u01/home/weblogic/lrs/server/application-deployments/orion-application.xml: No such file or directory
    How is OC4J able to determine I have a bad configuration element in a file that doesn't exist? Where is this coming from?
    Clues for the clueless?
    Thanks!
    -Jerome

    Avi:
    What I see in the factory-default j2ee/config/j2ee-logging.xml of my oc4j 10.1.3 standalone is the following. If you take a look at it, you would believe what I suggested above is enough.
    <?xml version="1.0" encoding="iso-8859-1"?>
    <logging_configuration>
      <log_handlers>
        <log_handler name='console-handler' class='java.util.logging.ConsoleHandler' formatter='oracle.core.ojdl.logging.SimpleFormatter'/>
        <log_handler name='oc4j-handler' class='oracle.core.ojdl.logging.ODLHandlerFactory'>
          <property name='path' value='../log/oc4j'/>
          <property name='maxFileSize' value='10485760'/>
          <property name='maxLogSize' value='104857600'/>
          <property name='encoding' value='UTF-8'/>
        </log_handler>
      </log_handlers>
      <loggers>
        <!-- Default Logger, useParentHandlers should be set to false because
             the root Logger (named the empty string "") will log to console -->
        <logger name='oracle' level='NOTIFICATION:1' useParentHandlers='false'>
            <handler name='oc4j-handler'/>
            <handler name='console-handler'/>
        </logger>
      </loggers>
    </logging_configuration>.
    Actually, 'NOTIFICATION:32' also means 'FINEST' in the case of non-odl logging, which is called text logging in the related oracle documention.

  • OC4J and Handle.getEJBObject()

    Hi all,
    I am developing a Stateless session bean. I want to save its remote reference through a client so that I can call it later. The code is working fine in Websphere 6.0 but not in OC4J 10.1.3.
    The Client Code is:
    Hashtable env = new Hashtable();
    //Setting properties
    env.put(Context.INITIAL_CONTEXT_FACTORY, ctxFactory);
    env.put(Context.SECURITY_PRINCIPAL, security_principal);
    env.put(Context.SECURITY_CREDENTIALS, security_credentials);
    env.put(Context.PROVIDER_URL, serverURL);
    env.put(("dedicated.rmicontext","true");
    public void callEJB(boolean startWhile)
    InitialContext ic = new InitialContext (env);
    //Looking up Home Object
    SEJBRemoteHome homeObj =
    (SEJBRemoteHome)PortableRemoteObject.narrow (ic.lookup (SEJB_Bean),SEJBRemoteHome.class);
    SEJBRemote remObj = homeObj.create ();
    Handle EjbObjHandle = null;
    EJBObject eObj = null;
    if(startWhile)
    EjbObjHandle = remObj.getHandle();
    //Saving Ejb handle
    saveEjbObjHandle(EjbObjHandle);
    //Calling EJB method
    remObj.setPollProperty(startWhile);
    else
    //Getting Handle
    EjbObjHandle = getEjbObjHandle();
    EJBObject ejbObjRef = null;
    ejbObjRef = EjbObjHandle.getEJBObject();
    remObj = (SEJBRemote)PortableRemoteObject.narrow
    (ejbObjRef,SEJBRemote.class);
    remObj.setPollProperty(startWhile);
    ejbObjRef.remove();
    }//methos to save Handle
    public void saveEjbObjHandle(Handle o)
    try {
    ObjectOutputStream objOut = new ObjectOutputStream(new
    FileOutputStream(EJBObjPath ));
    objOut.writeObject(o);
    objOut.close();
    catch (Exception e)
    e.printStackTrace();
    //method to Get handle
    public Handle getEjbObjHandle ( )
    Handle pHandleIn=null;
    try {
    ObjectInputStream objIn = new ObjectInputStream(new
    FileInputStream(EJBObjPath));
    pHandleIn = (Handle)objIn.readObject( );
    objIn.close();
    catch (Exception e)
    e.printStackTrace();
    return pHandleIn;
    Error Msg:
    oracle.oc4j.rmi.OracleRemoteException: Error looking up EJBHome at location 'SEJB_Bean'
    at com.evermind.server.ejb.StatelessSessionHandle.getEJBObject(StatelessSessionHandle.java:42)
    at com.iflex.fcubs.ssiadservices.ejb.SSIADEJBClient.callEJB(SEJBClient.java:209)
    at com.iflex.fcubs.ssiadservices.ejb.SEJBClient.main(SEJBClient.java:361)
    Nested exception is:
    javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
    at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:645)
    at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:247)
    at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.java:284)
    at javax.naming.InitialContext.lookup(InitialContext.java:351)
    at com.evermind.server.ejb.StatelessSessionHandle.getEJBObject(StatelessSessionHandle.java:31)
    at com.iflex.fcubs.ssiadservices.ejb.SEJBClient.callEJB(SEJBClient.java:209)
    at com.iflex.fcubs.ssiadservices.ejb.SEJBClient.main(SEJBClient.java:361)
    I am getting this error while I am trying to executing else part. For if part it is initiating ejb and calling successfully the ejb method.
    Can anyone explain this to me....and solve my problem. Am I violating any rule of OC4J or J2EE. I am trying to solve this error for past 3 weeks.....but unable to solve.
    Any help will be appriciated.
    Thanks....

    Hi,
    Thank you for your reply, mean while I found this but got the error I mentioned in :]
    How to start servers after reboot ?
    Any idea ?

  • Help required in handling of Oracle BLOB and CLOB in OC4J

    Hi,
    I am in a process of porting my application from Weblogic 6 to OC4J.
    I have problem while handling CLob and Blob's in oracle. Weblogic has
    classes defined to do the same. (weblogic.jdbc.common.OracleClob)
    Does any one know how I can achieve this.
    Thanks in advance.
    Regards,
    Moin

    We have an application running on OC4J accessing an Oracle 8.1.7 db, and have no problems using BLOBs and CLOBs. It is explained quite clearly in the Oracle documentation.
    If you require further assistance let me know :-)

  • Is it possible to reload Handler files without shuting down OC4J

    Is it possible to reload the Handler files in OC4J ?
    When a new Handler file is generated by the JAG I need to restart OC4J otherwise I get a Handler not found exception.

    Handlers are java-classes so I would say yes.
    Classes (including BC4J View and Entity objects) must
    be recompiled and your server should be restarted.
    Anything XML-related (including UIX) does not immediately
    force you to restart OC4J, although the MVC Framework
    descriptor-xml should be reloaded by for instance re-
    entering the service you changed. This is where those
    home-page services become handy.
    Note that setting existing BC4J-attributes to (in)visible
    or wider/smaller mostly just changes the BC4J Jheadstart
    metadata and generates new UIX, so it doesn't change
    anything in the java-classes.

Maybe you are looking for

  • Satellite L300D boots into a blank screen with mouse cursor

    Hi, I have been asked by friends of mine to help them fix their L300D. Their son got to it and they are not sure what he did, but now when it loads into VIsta, all they get is a Black Screen with a mouse cursor in the middle. The cursor looks as if i

  • How do I get a digital compass?

    Every time I try to download an app, this notification comes up saying to download the app I need a digital compass. What is this and how do I get it?

  • ADF Mobile : sample no Vegas

    hi Please consider this tweet by Duncan Mills " @fnimphiu so it's like Vegas - "what happens in a region - stays in a region" " at https://twitter.com/DuncanMills/status/255318833412308992 I wonder how much this translates to bounded task-flows and u

  • Java Add-In Installation for EHP4 ERP system

    Hello! we successfully upgraded our SAP ERP system to EHP4 for SAP. Our system has only ABAP stack. Question 1) Is it possible to install a Java Add-In instance for the existing EHP4 system? 2) If yes, can this be done on the same Windows server? Tha

  • Identify the Button Pressed in BBP_DOC_CHANGE_BADI ?

    Hi guys, Do you know how could I identify which button was pressed in BBP_DOC_CHANGE_BADI ?    Because that badi is called a lot of times, but I would like to execute some code when the end-user pushes the "submit" button. Do you know ? Thank yoiu !!