Setting session item after logon

hello,
i want to set the value of an item after an user successfully has logged on to an apex application.
where should i set the value best?
regards,
roman

A good place to do this is in the authentication scheme's post-authentication process.
Scott

Similar Messages

  • Closing DBA session in AFTER LOGON trigger

    Hello *,
    this is my first question here and my first piece of code in oracle so please don't laugh ;-)
    I'm trying to create an AFTER LOGON trigger which disconnects a user if he/she tries to log in from an incorrect host.
    What should happen?
    User tries to connect.
    If he/she is permitted, a record is added to a table.
    If not, a record is added to another table and the user is disconnected using RAISE_APPLICATION_ERROR().
    After a number of issues I've got it working, except ... I have the feeling that RAISE_APPLICATION_ERROR() doesn't effect users with DBA privileges.
    Finally, I'm testing it with one ordinary user - DEF.
    The main idea is to disallow connections from user ABC which has DBA privileges.
    Tests using DEF are successful but when ABC tries to log in from an incorrect host, a record is added in pcbaudit_failed_logins but the user is not disconnected.
    The database is 9.2.0.8.0 and I'm prepared to post RDA report if it is required.
    Thank you for your help in advance - I hope I was kind enough :P
    Here's the code for the trigger:
    DROP TABLE pcbaudit_users;
    CREATE TABLE pcbaudit_users (username VARCHAR2(32) NOT NULL, host VARCHAR2(64) NOT NULL);
    CREATE INDEX idx_pcbaudit_users_username ON pcbaudit_users(username);
    CREATE INDEX idx_pcbaudit_users_host ON pcbaudit_users(host);
    DROP TABLE pcbaudit_logins;
    CREATE TABLE pcbaudit_logins (username VARCHAR2(32), ip_address VARCHAR2(15), host VARCHAR2(64), ts DATE);
    DROP TABLE pcbaudit_failed_logins;
    CREATE TABLE pcbaudit_failed_logins (username VARCHAR2(32), ip_address VARCHAR2(15), host VARCHAR2(64), ts DATE);
    CREATE OR REPLACE PUBLIC SYNONYM pcbaudit_users FOR sys.pcbaudit_users;
    CREATE OR REPLACE PUBLIC SYNONYM pcbaudit_logins FOR sys.pcbaudit_logins;
    CREATE OR REPLACE PUBLIC SYNONYM pcbaudit_failed_logins FOR sys.pcbaudit_failed_logins;
    GRANT SELECT ON sys.pcbaudit_users TO public;
    GRANT INSERT ON sys.pcbaudit_logins TO public;
    GRANT INSERT ON sys.pcbaudit_failed_logins TO public;
    INSERT INTO pcbaudit_users VALUES ('SYS', '%');
    INSERT INTO pcbaudit_users VALUES ('SYSTEM', '%');
    INSERT INTO pcbaudit_users VALUES ('ABC', '%');
    INSERT INTO pcbaudit_users VALUES ('DEF', '%');
    COMMIT;
    CREATE OR REPLACE
    TRIGGER logon_pcbaudit_trigger AFTER LOGON ON DATABASE
    DECLARE
         v_username     VARCHAR2(32); /* variable that will hold current username */
         v_host          VARCHAR2(4000); /* variable that will hold current host */
         v_allowed     NUMBER(1) := 0;
         PRAGMA          AUTONOMOUS_TRANSACTION;
    BEGIN
         SELECT     UPPER(USER), /* current user */
              UPPER(SYS_CONTEXT('USERENV', 'HOST')) /* current user host */
         INTO     v_username,
              v_host
         FROM     dual;
         /* debug */
    --     DBMS_OUTPUT.PUT_LINE(v_username || '@' || v_host);
         SELECT     1
         INTO     v_allowed
         FROM     pcbaudit_users
         WHERE     UPPER(username) = v_username
    AND (
                   UPPER(REPLACE(v_host, CHR(0), '')) LIKE UPPER(host) ESCAPE '!' /* fuck that shit! Something appends CHR(0) to its host... */
                   OR
                   v_host IS NULL /* fuck that shit! Some hosts are NULLs! */
    /* write log (user has logged in!) */
    INSERT
    INTO pcbaudit_logins
    (username, ip_address, host, ts)
    VALUES
    (v_username, SYS_CONTEXT('USERENV', 'IP_ADDRESS'), v_host, SYSDATE);
    COMMIT;
    EXCEPTION
         WHEN     NO_DATA_FOUND     THEN /* occurs when no matches were found; i.e. current username is not permitted to login from the current host */
              /* log the failed attempt */
              INSERT
              INTO     pcbaudit_failed_logins
              (username, ip_address, host, ts)
              VALUES
              (v_username, SYS_CONTEXT('USERENV', 'IP_ADDRESS'), v_host, SYSDATE);
    COMMIT;
              /* disconnect user */
              RAISE_APPLICATION_ERROR(-20001, v_username || '@' || v_host || ' is not allowed to connect.');
         WHEN     OTHERS THEN
              NULL; /* in this case, NULL is better than an error - if an error occurs, user will not be able to login. */
    END;

    Thank you for your reply!
    The situation is quite complicated.
    I am aware that a user with DBA privileges can drop the trigger, modify it, etc.
    There's an application on top of it and (i don't know why) it requires dba privileges. The point is, there are developers with access to the production database and my task is to stop them from logging in with this username.
    Since I'm creating a trigger, I've obviously have no other choice. I can't change the user's password because of number of reasons, I can't deny developers' IP addresses using sqlnet.ora because they need read-only access and so on.
    I realize that this is not the way that things are being done (development cycle), but I have no other choice.
    So, is there any other way?

  • Setting Session item from outside of APEX

    Hi All,
    First a little background: I've been learning APEX for a couple of days now. I'm evaluating it to see if it's suitable for the application we need to make, otherwise it'll be done in PHP.
    The application needs to act as a web service client: as requirement number 1, we need to interface with a 3rd party IDP server to get a SAML2 assertion. This assertion will later need to be injected into the SOAP header of web service call, but I'm not worrying about this bit for now.
    I've gotten half way there. I've created a new page with a process at runs before the header. This can handle creating our authn request (which is a bit of xml) and forward the browser onto the IPD server for authentication (with anthn request set as a GET parameter that has been deflated and base64 encoded). Whoo!
    Once the IDP server has finished authenticating the user, a http post (with the SAML assertion we need) is done back to the application.
    Now as I understand it, I can't get the IDP to post back to an APEX page directly, as we need to access the HTTP Post data. So, I plan on writing a PL/SQL procedure (which I've added to the FLOWS ok list to be called via the PL/SQL gateway).
    So inside this procedure, I'm not in APEX, but I'll want to keep track of the SAML Assertion (which will just be a CLOB for arguments sake) such that I can use in APEX for when I make my SOAP call. If it was down to me, I'd have a table with session_id and the assertion, and just query that from APEX.
    BUT this 3rd party that we have to work with is the government, and they've given us rules. We aren't allow to store these assertions, they can only exist in the scope of a users session (no storing in files, databases, anything that could be permanently stored on the hard drive), virtual memory is ok though.
    So, after all that useless info, onto my question: Can I set an apex application item from this pl/sql procedure? If so, how would one do it? Now I understand that in the background, an item is probably written to a table, but I'm going to gloss over that for now (in the hope that the people certifying the app do the same).
    Thanks for all the help,
    Tim

    Tim,
    I am working a similar issue, but slightly different. I am trying to determine if we are trying to answer the same question.
    Here is what I understand about your initial posting...
    You are authenticating a user.. that must make a call to some "place".. then wait for that place to respond with an OK message, without storing the value. There is enough lag in this process that you want the response from "the place" that you want the response from "the place" to change the session value in the Web based UI. Is this correct?
    Issue: Even if you did have this process setting the session value, the client web browser would not respond unless it was in some type of checking loop.
    If you are in a checking loop, you would have the ability to call the "service" in some sort of checking mode from APEX.
    If this is a smooth process (no major lag), you could manage it within a custom authentication scheme. Is this the area you are working in?
    I understand your need to set from an outside connection. But if you are using the outside database connection method, you are isolated to a different session... I would believe (I do not work for Oracle) for security reasons.
    --Tim St. Hilaire                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Text in after  logon screen when logging on with"customer reserve" language

    Hello
    I wander how could I set text in after  logon screen when logging on with"customer reserve" language. Namely instead:
    SAP user name             XURUZRJ
    Last system logon         27.03.2014
                     at       11:45:17
    Copyright(c) SAP AG 2002.
    All rights reserved.
    License w/o expiration
    This software product, marketed by SAP AG
    or its distributors, includes proprietary
    software components of Oracle Corporation.
    Copyright (c) Oracle Corporation 1979, 2004.
    All rights reserved.
    Oracle is a registered trademark of Oracle
    Corporation and/or its affiliates. Various
    product names referenced herein may be
    trademarks of Oracle Corporation
    I get:
    SAP user name             XURUZRJ
    Last system logon         27.03.2014
                     at       12:23:42
    Thank you a lot in advance
    Jan

    Hi Jan,
    Refer SAP note
    1149795 Translating English Customizing entries into German
    Process specified can be used to change the text from local language to English.
    Hope this helps.
    Regards,
    Deepak Kori

  • Set Session State with Shuttle items

    Is it possible to have session state set with each item selected in a shuttle? You have a shuttle with 4 possible options, you select item 2 from the left portion of shuttle and it is moved to the right.. Can you set the session state at that point?
    What I am trying to do is take the session state after change in the control and use it to populate a text field below. The returned values are used in a sql select to populate the text box with a looked up value...
    Thank you,
    Tony Miller
    Ruckersville, VA

    TexasApexDeveloper wrote:
    Won't this just push the last items value in, as apposed to appending the value?
    Tony,
    No. Because for shuttle items the return value is stored as colon delimited string.
    Means after each change you will have a colon delimited string in the session state with selected values(moved to right).
    See this http://apex.oracle.com/pls/apex/f?p=46417:47

  • Set Item after Fetch Row

    Hi,
    i have an item in a form region with 'Display As': 'Text
    Field (Disabled, saves state)'. This item is populated by the 'Fetch
    row' process. After the fetch row process i want to set the item by
    the process 'Set Data' (Process Point: On Load - After Footer) to
    another value - but it doesn't work.
    In Debug Mode i get the following messages:
    0.05: Processing point: AFTER_FOOTER
    0.05: ...Process "Set Data": PLSQL (AFTER_FOOTER) BEGIN :P50_MARKE := #OWNER#.wav_api.getData ......
    0.05: ...Session State "P50_MARKE" - saving same value: "Walther_____"
    The value from the fetch was: 'Walther' and after setting it should be 'Walther_____'
    As you can see my function wav_api.getData works fine.
    Has somebody an idea what's wrong?
    Best regards,
    Marti

    Martin,
    Your stated requirement is: "After the fetch row process i want to set the item..."
    Your process does this and your computation does this. They both set the item's value in session state as your debug output showed. But doing either of these at the After Footer point makes no sense. That's after the item has been rendered on the page as a form input item. And that's the value that will be POSTed in the form and which will then override the value in session state that your process or computation established.
    Andy's suggestion was to use a Post Calculation Computation. This is a property of the item (see the Source section). You would not need a computation or process on the page if you do it this way.
    Another method would be to use an After-Header process or computation. For this to work, you would also need to change the item's Source Used setting to "Only, ..." from "Always, ...". If you do it that way and the process or computation always sets the value correctly then that should be all you need to do. If the process or computation runs conditionally or cannot be relied upon to set the correct value then you may need to add other logic to the page.
    Scott

  • Setting an item value before print report in BI Publisher

    Hi,
    I am having an issue with setting a page item's value once a button (that prints a BI Publisher report) is pressed. The session state for the item is set, however because the page does not re-load no value appears in the item on the page.
    I am using a button as a page Item and using a Page Branch with the Branch Point set as On Submit: After Processing(After Computation, Validation, and Processing) with the Page set to 0 and the Request set to PRINT_REPORT=REPORT
    Is there any way to set the item value on the page before branching to the report?
    Your help is greatly appreciated.
    -Marsha

    Marsha,
    You can do that as follows:
    1- create a hidden text item (P20_date_hidden) with default value set to sysdate.
    2- for your button >> edit >> Buttom display attributes >> attributes >> type in : onFocus= "set_date();" (( note: am using onFocus because it takes places before onClick ))
    3- In your page >> edit >> HTML header >> type in :
    <script language="JavaScript" type="text/javascript">
    function set_date()
    v_date = $x('P20_DATE_HIDDEN').value;
    $x('P20_DATE_LETTER_SENT').value = v_date;
    </script>
    Hope this helps,
    Sam
    Please reward good answers by marking them correct or useful!

  • Java Iview Runtime error after logon

    Hello,
    we are facing some problem regarding our EP 7.0 SP13. We have an anonymous page as our home page, with some anonymous ivews, like "help", "news", etc and one iview with authentication set to default where users log into the portal and access to the private section of the portal.
    That ivew does a redirection to /irj/portal and since the user is athenticated it will led him to the private home. The problem is that after logon, a Java iview runtime error appears, and users must refresh the browser to access the private section. (user is logged before the error appears).
    We have checked this is not happening with users with "super admin" o "content admin" role. They are able to log into the portal, and redirection is working fine. So we think there can be some problem with security zones or authentication somewhere in the portal, but since this is the standard logon component i don´t know why is this not working.
    We have checked that the redirection is working, and we have made some tests with different kind of iviews like KM iviews, URL iviews, pictures, etc. Only admin users are able to log in correctly, the others get the java iview runtime error, so we think the problem is with to standard logon...
    Here goes a trace of our problem (defaultrace.trc):
    #1.5 #000802B3F434005C00000434000024680004646E64997E00#1236325203820#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###com.sapportals.portal.prt.runtime.PortalRuntimeException: Exception in connection#
    #1.5 #000802B3F434005C00000435000024680004646E64998C55#1236325203820#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:304)#
    #1.5 #000802B3F434005C00000436000024680004646E64998E05#1236325203820#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.dispatcher.Dispatcher$doService.run(Dispatcher.java:524)#
    #1.5 #000802B3F434005C00000437000024680004646E6499900A#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at java.security.AccessController.doPrivileged(Native Method)#
    #1.5 #000802B3F434005C00000438000024680004646E64999183#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.dispatcher.Dispatcher.service(Dispatcher.java:407)#
    #1.5 #000802B3F434005C00000439000024680004646E649992D1#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)#
    #1.5 #000802B3F434005C0000043A000024680004646E6499941A#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.servlets_jsp.server.servlet.InvokerServlet.service(InvokerServlet.java:156)#
    #1.5 #000802B3F434005C0000043B000024680004646E6499955B#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)#
    #1.5 #000802B3F434005C0000043C000024680004646E64999690#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)#
    #1.5 #000802B3F434005C0000043D000024680004646E6499984F#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)#
    #1.5 #000802B3F434005C0000043E000024680004646E6499999C#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:387)#
    #1.5 #000802B3F434005C0000043F000024680004646E64999AEB#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:365)#
    #1.5 #000802B3F434005C00000440000024680004646E64999C2F#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:944)#
    #1.5 #000802B3F434005C00000441000024680004646E64999D76#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:266)#
    #1.5 #000802B3F434005C00000442000024680004646E64999EDA#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)#
    #1.5 #000802B3F434005C00000443000024680004646E6499A01D#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)#
    #1.5 #000802B3F434005C00000444000024680004646E6499A15E#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)#
    #1.5 #000802B3F434005C00000445000024680004646E6499A30A#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)#
    #1.5 #000802B3F434005C00000446000024680004646E6499A479#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)#
    #1.5 #000802B3F434005C00000447000024680004646E6499A5B7#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at java.security.AccessController.doPrivileged(Native Method)#
    #1.5 #000802B3F434005C00000448000024680004646E6499A718#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)#
    #1.5 #000802B3F434005C00000449000024680004646E6499A855#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)#
    #1.5 #000802B3F434005C0000044A000024680004646E6499B6CC#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###Caused by: com.sapportals.portal.prt.runtime.PortalRuntimeException: PortalRuntimeException#
    #1.5 #000802B3F434005C0000044B000024680004646E6499B86B#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:284)#
    #1.5 #000802B3F434005C0000044C000024680004646E6499BA7E#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     ... 20 more#
    #1.5 #000802B3F434005C0000044D000024680004646E6499CB8B#1236325203836#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###Caused by: com.sapportals.portal.prt.core.PortalRequestManagerException: PortalRuntimeException#
    #1.5 #000802B3F434005C0000044E000024680004646E6499CD54#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:143)#
    #1.5 #000802B3F434005C0000044F000024680004646E6499CE9B#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:189)#
    #1.5 #000802B3F434005C00000450000024680004646E6499CFDD#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.component.PortalComponentResponse.include(PortalComponentResponse.java:215)#
    #1.5 #000802B3F434005C00000451000024680004646E6499D130#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.connection.ContentExceptionHandler.handleException(ContentExceptionHandler.java:100)#
    #1.5 #000802B3F434005C00000452000024680004646E6499D277#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.connection.ContentExceptionHandler.handlePortalRuntimeException(ContentExceptionHandler.java:27)#
    #1.5 #000802B3F434005C00000453000024680004646E6499D512#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.core.PortalRequestManager.handleRequestException(PortalRequestManager.java:917)#
    #1.5 #000802B3F434005C00000454000024680004646E6499D677#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.core.PortalRequestManager.runRequestCycle(PortalRequestManager.java:803)#
    #1.5 #000802B3F434005C00000455000024680004646E6499D7F3#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.connection.ServletConnection.handleRequest(ServletConnection.java:240)#
    #1.5 #000802B3F434005C00000456000024680004646E6499D943#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     ... 20 more#
    #1.5 #000802B3F434005C00000457000024680004646E6499EB58#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###Caused by: java.lang.UnsupportedOperationException: this implementation does not support getComponentContext()#
    #1.5 #000802B3F434005C00000458000024680004646E6499ECFD#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.service.hook.RedirectNode.getComponentContext(RedirectNode.java:50)#
    #1.5 #000802B3F434005C00000459000024680004646E6499EE40#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.component.PortalComponentRequest.getComponentContext(PortalComponentRequest.java:343)#
    #1.5 #000802B3F434005C0000045A000024680004646E6499EF97#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.core.PortalRequestManager.callPortalComponent(PortalRequestManager.java:238)#
    #1.5 #000802B3F434005C0000045B000024680004646E6499F0E1#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     at com.sapportals.portal.prt.core.PortalRequestManager.dispatchRequest(PortalRequestManager.java:136)#
    #1.5 #000802B3F434005C0000045C000024680004646E6499F21D#1236325203852#System.err#sap.com/irj#System.err#javier#7063####017208f00a2211de8d53000802b3f434#SAPEngine_Application_Thread[impl:3]_23##0#0#Error##Plain###     ... 27 more#
    can anyone help us with this problem?
    Thanks in advance

    The problem was solved, it was a permission problem.
    The anonymous role which allow access to the anonymous section of the portal was assigned to anonymous user, but it hasn´t everyone permission. So anonymous users were able to see anonymous pages, but when they login they lose the role, and java iview error happened, unless they had admin rights.
    Solved assigned by assigning everyone to that role.
    Thanks

  • Trace users by after logon trigger

    Hi.
    I have to trace some users application to find the source of problems.
    Oracle8i Enterprise Edition Release 8.1.7.0.0
    connect system/manager@testdb
    create or replace trigger login_trigger
    after logon on database
    begin
    if (USER in ('BLAKE','SCOTT')) then
    execute immediate
    'ALTER SESSION SET EVENTS ''10046 TRACE NAME CONTEXT FOREVER, LEVEL 12''';
    end if;
    end;
    show error;
    SQL> connect scott/tiger@testdb
    ERROR:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-01031: insufficient privileges
    ORA-06512: at line 3
    OK, I'll grant a priv.
    SQL> connect system/manager@testdb
    SQL> GRANT administer DATABASE TRIGGER TO "SCOTT";
    SQL> connect scott/tiger@testdb
    Connected.
    Good, only *.trc file is empty after that and there is no trace information for analyse.
    Could you please give me a solution?
    Mikhail

    can't find any *.trc & alert files relevant current time 20080329:20.34
    only this
    29.03.2008 18:20 72 583 nmuALRT.LOG
    25.03.2008 22:22 600 nmuARC0.TRC
    but the last connection I've made
    20080329:20.34
    SQL> connect SCOTT/[email protected]
    ERROR:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-01031: insufficient privileges
    ORA-06512: at line 3
    this is the files
    ---nmuALRT.LOG---
    Dump file C:\oracle\admin\nmu\bdump\nmuALRT.LOG
    Sat Mar 22 17:58:46 2008
    ORACLE V8.1.7.0.0 - Production vsnsta=0
    vsnsql=e vsnxtr=3
    Windows 2000 Version 5.1 Service Pack 2, CPU type 586
    Starting up ORACLE RDBMS Version: 8.1.7.0.0.
    System parameters with non-default values:
    processes = 150
    shared_pool_size = 52428800
    large_pool_size = 614400
    java_pool_size = 20971520
    control_files = C:\oracle\oradata\nmu\control01.ctl, C:\oracle\oradata\nmu\control02.ctl, C:\oracle\oradata\nmu\control03.ctl
    db_block_buffers = 19200
    db_block_size = 8192
    compatible = 8.1.0
    log_buffer = 32768
    log_checkpoint_interval = 10000
    log_checkpoint_timeout = 1800
    db_files = 1024
    db_file_multiblock_read_count= 8
    max_enabled_roles = 30
    remote_login_passwordfile= EXCLUSIVE
    global_names = TRUE
    distributed_transactions = 500
    instance_name = nmu
    service_names = nmu
    mts_dispatchers = (PROTOCOL=TCP)(PRE=oracle.aurora.server.SGiopServer)
    open_links = 4
    sort_area_size = 65536
    sort_area_retained_size = 65536
    db_name = nmu
    open_cursors = 300
    os_authent_prefix =
    job_queue_processes = 0
    job_queue_interval = 10
    parallel_max_servers = 5
    background_dump_dest = C:\oracle\admin\nmu\bdump
    user_dump_dest = C:\oracle\admin\nmu\udump
    max_dump_file_size = 10240
    oracle_trace_collection_name=
    Sat Mar 29 18:20:39 2008
    Errors in file C:\oracle\admin\nmu\udump\ORA02288.TRC:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-01031: insufficient privileges
    ORA-06512: at line 3
    ---nmuARC0.TRC-----------------------------------------
    Dump file C:\oracle\admin\nmu\bdump\nmuARC0.TRC
    Tue Mar 25 22:22:38 2008
    ORACLE V8.1.7.0.0 - Production vsnsta=0
    vsnsql=e vsnxtr=3
    Windows 2000 Version 5.1 Service Pack 2, CPU type 586
    Oracle8i Enterprise Edition Release 8.1.7.0.0 - Production
    With the Partitioning option
    JServer Release 8.1.7.0.0 - Production
    Windows 2000 Version 5.1 Service Pack 2, CPU type 586
    Instance name: nmu
    Redo thread mounted by this instance: 0 <none>
    Oracle process number: 14
    Windows thread id: 2592, image: ORACLE.EXE
    *** SESSION ID:(11.1) 2008-03-25 22:22:38.428
    *** 2008-03-25 22:22:38.428

  • Calling set_context() outside after logon trigger?

    Hello all
    I'm trying out and learning on using the application context so I tried out the tutorials from: Oracle® Database Security Guide 11g Release 1 (11.1) B28531-06 document (well, very similar examples that is)
    I made a procedure which should retreive the employee_id based on the provided user_name (a logical user_name stored in a table) and set an (attribute, value) pair using the dbms_session.set_context()...
    select employee_id into emp_id from user_pswd_table where user_name like p_user_name;
    DBMS_SESSION.SET_CONTEXT('employee_id_ctx', 'employee_id', emp_id);
    and (the tester) the call of the procedure looked like something like this:
    declare usernm varchar2(30);
    begin
    usernm :='user_name_which_will_be_provided';
    set_employee_id_pck.set_employee_id_ctx(usernm);
    end;
    but as it seams like it is only working if the call is made from the after logon on database trigger...if that's the case after the next log on I have the needed information retrieved with select sys_context(...) from dual, but if that's not the case if I call that procedure from anywhere else it results with no_data_found.
    Could someone please explain to me why is that???
    Thx in advance :D
    Ildiko

    Sorry Frank, the message for Ildiko.
    You found below context example
    Login with  user  scott :
    -- creation table  dossiers
    SQL> connect scott/tiger@oratest
    Connected.
    --creation de la table dossiers
    CREATE TABLE DOSSIER(
      NO_DOS    NUMBER(6),
      DT_DOS    DATE,
      TYPE_DOS  VARCHAR2(50) CHECK (TYPE_DOS IN ('SECRET','NORMAL'))
    --Insertions in table dossiers
    SQL> insert into dossier values(1,trunc(sysdate),'SECRET');
    1 row created.
    SQL> insert into dossier values(2,trunc(sysdate),'SECRET');
    1 row created.
    SQL> insert into dossier values(3,trunc(sysdate),'SECRET');
    1 row created.
    SQL> insert into dossier values(4,trunc(sysdate),'NORMAL');
    1 row created.
    SQL> insert into dossier values(5,trunc(sysdate),'NORMAL');
    1 row created.
    SQL> commit;
    Commit complete.
    SQL> select * from dossier;
        NO_DOS DT_DOS    TYPE_DOS
             1 22-MAY-07 SECRET
             2 22-MAY-07 SECRET
             3 22-MAY-07 SECRET
             4 22-MAY-07 NORMAL
             5 22-MAY-07 NORMAL
    -- Logon with  user sys :
    -- Attribution  grants
    grant execute on dbms_rls to scott;
    grant execute on dbms_session to scott;
    grant ADMINISTER DATABASE TRIGGER  to scott;
    grant alter session to scott ;
    --Logon with user system : 
    --Création et attribution  rôles
    Create role sec_employe ;
    Create role sec_manager;
    Grant select, update,insert, delete on scott.dossier to sec_employe ;
    Grant select, update,insert, delete on scott.dossier to sec_manager;
    Grant sec_manager to scott;
    Grant create any context to scott;
    grant create table to scott;
    grant create procedure to scott;
    -Logon with  user  scott :
    -- Création context  package 
    SQL> create or replace package pkg_dossier_context
      2   is
      3     procedure set_manager;
      4     procedure set_employe;
      5    end;
    Package created.
    SQL> create or replace package body pkg_dossier_context
      2       as
      3   procedure set_manager
      4      is
      5    begin
      6       dbms_session.set_context('scott_dossier','app_role','manager');
      7    end;
      8           --
      9    procedure set_employe
    10       is
    11     begin
    12       dbms_session.set_context('scott_dossier','app_role','employe');
    13     end;
    14   end;
    Package body created.
    -- Création  context
    SQL> create or replace context scott_dossier using pkg_dossier_context;
    Context created.
    -- Création du  package de sécurité
    SQL> create or replace package pkg_dossier_sec
      2    as
      3       function dossier_predicate(schema_name in varchar2, object_name in varchar2)
      4         return varchar2;
      5   end;
    Package created.
    SQL> create or replace package body pkg_dossier_sec
      2     as
      3        function dossier_predicate(schema_name in varchar2,object_name in varchar2)
      4         return varchar2
      5         is
      6                 lv_predicate varchar2(1000):='';
      7         begin
      8                 if sys_context('scott_dossier','app_role') = 'manager' then
      9                         lv_predicate:='type_dos=''SECRET'''; -- a le droit de voir uniquement
                                              --     les dossiers de type SECRET
    10                elsif sys_context('scott_dossier','app_role') = 'employe' then
    11                        lv_predicate:='type_dos=''NORMAL'''; -- a le droit de voir uniquement
                                          --les dossiers de type NORMAL
    12                 else
    13                        lv_predicate:='1=2'; -- block access
    14                end if;
    15               return lv_predicate;
    16        end;
    17     end;
    Package body created.
    -- Add la policy (politique)
    SQL> begin
    2        dbms_rls.add_policy(
    3                  object_schema => 'SCOTT',
    4                  object_name => 'DOSSIER',
    5                  policy_name => 'SCOTT_DOSSIER_POLICY',
    6                  function_schema => 'SCOTT',
    7                  policy_function => 'pkg_dossier_sec.dossier_predicate',
    8                   statement_types => 'select, insert, update, delete',
    9                   update_check => TRUE,
    10                  enable => TRUE,
    11                  static_policy => FALSE);
    12   end;
    PL/SQL procedure successfully completed.
    -- Création du trigger on logon
    SQL>  create or replace trigger scott_logon_trigger
      2     after logon on database
      3    declare
      4     NB VARCHAR2(30) ;
      5   begin
      6       select granted_role
      7        into nb
      8        from dba_role_privs
      9        where grantee='SCOTT' and granted_role='SEC_MANAGER' ;
    10        pkg_dossier_context.set_manager;
    11      exception
    12         when no_data_found then
    13         pkg_dossier_context.set_employe;
    14   end;
    Trigger created.
    PL/SQL procedure successfully completed.
    SQL> SELECT * FROM DOSSIER;
        NO_DOS DT_DOS    TYPE_DOS
             1 22-MAY-07 SECRET
             2 22-MAY-07 SECRET
             3 22-MAY-07 SECRET
    Explication :
    Scott a le rôle sec_manager donc il a le droit de voir uniquement  les dossiers  de type SECRET,
    une clause de restriction  se rajoute à ma requête initiale,
    elle devient :SELECT * FROM DOSSIERS  WHERE  type_dos='SECRET' ;
    -- Connect with user system :  
    SQL> revoke sec_manager from scott;
    Revoke succeeded.
    SQL> grant sec_employe to scott;
    Grant succeeded.
    --Connect with  user  scott :
    SQL> connect scott/tiger@oratest;
    Connected.
    SQL> select * from dossier;
        NO_DOS DT_DOS    TYPE_DOS
             4 22-MAY-07 NORMAL
             5 22-MAY-07 NORMAL
    --Pour enlever le policy
    SQL>  begin
      2          dbms_rls.drop_policy(
      3           object_schema => 'SCOTT',
      4           object_name => 'DOSSIER',
      5           policy_name => 'SCOTT_DOSSIER_POLICY');
      6   end;
    PL/SQL procedure successfully completed.
    SQL> select * from dossier;
        NO_DOS DT_DOS    TYPE_DOS
             1 22-MAY-07 SECRET
             2 22-MAY-07 SECRET
             3 22-MAY-07 SECRET
             4 22-MAY-07 NORMAL
             5 22-MAY-07 NORMALEdited by: Salim Chelabi on 2008-12-16 10:54
    Edited by: Salim Chelabi on 2008-12-16 11:26

  • Can't Set Session State from the Login Page

    I have a dilema. On the standard login page I enter values in 2 fields namely, CAMPUS (Select List) and USERNAME (text field).
    After clicking on the login button I want to navigate to PAGE 1 and use the values of CAMPUS and USERNAME to filter data. I have created two APPLICATION Level items (A_USERNAME,A_CAMPUS) to which I assign the values of USERNAME and CAMPUS in two AFTER SUBMIT computations on the login page.
    When I arrive on PAGE 1 the session state values of A_USERNAME,A_CAMPUS are still both null therefore the query returns null. It seems that the login process does not issue a SUBMIT for session state to be saved. How do I save the values in session state on login?
    In the Login PROCESS, can I specify the Page 1 items to be set and the values to set them in a URL somewhere? Is it here?
    wwv_flow_custom_auth_std.login(
    P_UNAME => :P101_USERNAME,
    P_PASSWORD => :P101_PASSWORD,
    P_SESSION_ID => v('APP_SESSION'),
    P_FLOW_PAGE => :APP_ID||':1' <<========here?
    If so what is the correct syntax?
    If I revisit the login page a second time, a submit is issued and the values are set in session state.
    Anyone got any ideas??
    I tried creating a standard position button which issues a submit but this didn't work either.
    regards
    Paul J Platt

    Unfortunately your solution is causing problems with retrieving cookies that I try to get for the campus and username during a "Before Header Process" as well. The cookies are normally set on an "After Submit" process. When I return to the login page I get
    Error ERR-1029 Unable to store session info. session=10760914996048113736 item=8561939526127479
    ORA-02291: integrity constraint (FLOWS_010600.WWV_FLOW_DATA_FK) violated - parent key not found
    But if I turn the cookies off, it seems to work OK.
    regards
    Paul JP

  • Custom SharePoint 2010 designer page throws "The data source control failed to execute the insert command" exception while adding the new item after the August 13, 2013 CU has installed

    We have the SharePoint Server 2010 with SP1 environment on which the custom SP2010 designer pages were working as expected before the
    August 13, 2013 CU has installed. But, getting the below exception while trying to add the new item after the CU has installed.
    Error while executing web part: System.NullReferenceException: Object reference not set to an instance of an object.     at Microsoft.SharePoint.WebControls.SPDataSourceView.ExecuteInsert(IDictionary values)     at
    System.Web.UI.DataSourceView.Insert(IDictionary values, DataSourceViewOperationCallback callback) 3b64c3a0-48f3-4d4a-af54-d0a2fc4553cc
    06/19/2014 16:49:37.65  w3wp.exe (0x1240)                        0x1300 SharePoint Foundation        
     Runtime                        tkau Unexpected Microsoft.SharePoint.WebPartPages.DataFormWebPartException: The data source control
    failed to execute the insert command. 3b64c3a0-48f3-4d4a-af54-d0a2fc4553cc    at Microsoft.SharePoint.WebPartPages.DataFormWebPart.InsertCallback(Int32 affectedRecords, Exception ex)     at System.Web.UI.DataSourceView.Insert(IDictionary
    values, DataSourceViewOperationCallback callback)     at Microsoft.SharePoint.WebPartPages.DataFormWebPart.FlatCommit()     at Microsoft.SharePoint.WebPartPages.DataFormWebPart.HandleOnSave(Object sender, EventArgs e)    
    at Microsoft.SharePoint.WebPartPages.DataFormWebPart.RaisePostBackEvent(String eventArgument)     at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)     at System.Web.UI.Page.ProcessRequestMain(Boolean
    inclu... 3b64c3a0-48f3-4d4a-af54-d0a2fc4553cc
    06/19/2014 16:49:37.65* w3wp.exe (0x1240)                        0x1300 SharePoint Foundation        
     Runtime                        tkau Unexpected ...deStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) 3b64c3a0-48f3-4d4a-af54-d0a2fc4553cc
    I have tried changing the "DataSourceMode" as below, now the insert command is working, but update command is not working.
    <SharePoint:SPDataSource runat="server" DataSourceMode="ListItem" />
    Also, the lookup dropdown fields are displaying the value as "<a href="Daughterhttp://cpsp10/sites/Employees/_layouts/listform.aspx?PageType=4&ListId={8F62F444-FB6A-4F03-9522-C4696B45DCD1}&ID=10&RootFolder=*">Daughter</a>"
    instead of only "Daughter".
    Please provide the solution to get rid of this issue.
    Thanks
    Ramasubbu

    Try below:
    http://social.technet.microsoft.com/Forums/en-US/ae910269-3a0c-4506-844b-e8bc89d95b71/data-source-control-failed-to-execute-the-insert-command
    http://blog.jussipalo.com/2012/01/sharepoint-2010-data-source-control.html
    While there can be many causes for this generic error message, in my case the first parameter or ddwrt:DataBind function inside the SharePoint:FormFields element was
    'i' and I was working with an Edit Form. Changing it to
    'u' as it was with every other FormField fixed the issue.
    <SharePoint:FormField runat="server" id="ff1{$Pos}" ControlMode="Edit" FieldName="Esittaja" __designer:bind="{ddwrt:DataBind('u',concat('ff1',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Esittaja')}"
    />
    Explanation:
    DataBind operation type parameters (the first parameter) are listed below:
    'i' stands for INSERT,
    'u' stands for UPDATE,
    'd' stands for DELETE.
    http://webcache.googleusercontent.com/search?q=cache:d9HHY4I7omgJ:thearkfloats.blogspot.com/2014/03/sharepoint-2010-data-source-control.html+&cd=4&hl=en&ct=clnk&gl=in
    If this helped you resolve your issue, please mark it Answered

  • System should not allow to delete PO line Item after GR/IR

    Hi,
    I am working on a SAP Retail Implementation project.
    Currently the system is allowing us to delete the PO line items after doing GR or IR against that PO line item. But the clients requirement is that the system should not allow to delete PO line item after doing GR/IR.
    We are using Account Assignment Category-N, Item Category-S.
    Please let me know if you have the solution for this requirement.
    Thanks in advance
    Thanks & Regards,
    Suresh

    Hi,
    Standard SAP will not allowed the PO to be deleted once it was GR done. The controlled is on the attributes of message to set as "E"
    Message no. 06115
    But if invoiced takes place, the is the point that PO can be deleted.
    You have to do have a Enhancement using MM06E005, insert you logic here to check PO history tables like EKBE, then check if invoice " Q" (BEWTP) exist, the PO cannot be deleted once the user delete the PO line and SAVE it. Ask you developer to help you on the following coding.
    Use MM06E005 and EXIT_SAPMM06E_012
    IF SY-TCODE = 'ME22N'.
    IF sy-ucomm = 'MESAVE' OR SY-UCOMM = 'YES'..
    LOOP AT TEKPO.
    IF TEKPO-LOEKZ = 'L'.
    SELECT SINGLE BELNR FROM EKBE INTO BELNR1 WHERE EBELN = TEKPO-EBELN AND EBELP = TEKPO-EBELP AND BEWTP = 'E'.
    IF SY-SUBRC = 0.
    SELECT SINGLE BELNR FROM EKBE INTO BELNR2 WHERE EBELN = TEKPO-EBELN AND EBELP = TEKPO-EBELP AND BEWTP = 'Q'.
    IF SY-SUBRC = 0.
    Regards,

  • Error In After Logon Trigger

    Hi,
        I am using Release 11.2.0.3.0 of oracle.
    I have created a trigger for restricting specific users(logging from specific program and having specific OSUSER) from loging into the database.
    I created below trigger in SYS schema.
    CREATE OR REPLACE TRIGGER t1
    AFTER
    LOGON
    ON DATABASE
    DECLARE
    trg_program varchar2(4000);
    trg_user varchar2(4000);
    trg_osuser varchar2(4000);
    v_killsession  VARCHAR2(4000);
    v_sid   VARCHAR2(4000);
    v_serial   VARCHAR2(4000);
    BEGIN
    SELECT UPPER (program), UPPER (USERNAME), UPPER (OSUSER),SID,serial#
      INTO trg_program, trg_user, trg_osuser,v_sid,v_serial
      FROM v$session
    WHERE audsid = SYS_CONTEXT ('USERENV', 'SESSIONID') AND ROWNUM = 1;
    IF  trg_program IN ('SQLPLUS.EXE','SQLPLUSW.EXE','TOAD.EXE')
        AND  trg_user in ('USER1','USER2')--,'SYS','SYSTEM')
        --AND trg_osuser  not in ('O12345')
    THEN
           raise_application_error(-20001,'You are not authorized to connect to this schema directly!!');
    END IF;   
    END;
    when i am logging into USER1 through sqlplus/toad it works fine, i am getting required message which is mentioned as 'raise application error'
    but when i am compiling the trigger by uncommenting extra condition for OSUSER i.e trg_osuser  not in ('O12345') in the trigger code, so that it wont affect the highly provileged user(i.e OSUSER O12345).During logging in to user USER1 i am getting below error
    ERROR:
    ORA-04045: errors during recompilation/revalidation of
    XIGNCMN.RESTRICT_UNAUTH_ACCESS
    ORA-01031: insufficient privileges
    it should alow me to login because i am OSUSER 'O12345', so why its not working?

    Thanks John.
    Actually currently we are having database server installed in each of the developers machine so having DBA privilege and having business data, thats why i am planning to configure common database to which all will connect and i wont allow them to connect to the database directly through the functional schema(2 schemas). Now i am planning to restrict the developers access to only 'SELECT+DMLS' for the functional schema and i will do that by creating another user through which they will get connected to the actual functional schema with restricted privilege.
    But here the issue is that, for JAVA application, they are having local source code in each of their machine and will also need the connection string/password for the functional schema, so they will know the password for the functional schema, but i want to restrict their access through all the program except 'Jdbc thin client' so i thought of above trigger.
    kindly suggest if any other way out?

  • Insufficient privileges using execute immediate in after logon trigger

    I have an after logon trigger that executes a package/procedure in the schema it was created in.
    One of the procedures runs the following:
    EXECUTE IMMEDIATE 'AUDIT INSERT TABLE, UPDATE TABLE, DELETE TABLE, EXECUTE PROCEDURE BY ' || USER;
    The procedure is throwing an insufficient privileges error when executing this.
    However - the schema owner has audit any and audit system privileges and - the statement works fine independently.
    When I login as another user this issue arises. The package/procedure are created with definers rights... So - i'm not sure why this is happenening.
    Any help is appreciated.

    privileges acquired via ROLE do NOT apply within named PL/SQL procedures.
    SQL> SET ROLE NONE
    SQL> --issue AUDIT again now                                                                                                                                                                                                                                                               

Maybe you are looking for

  • Generating delimited file from a report in reports 6i gives error rep-1814

    Hi all, We are using reports 6i. We have a report from which we are trying to generate a delimited file. We are encounterign the error REP-1814 The object vertically can never fit. After looking into forums we came to know that there is something lik

  • How to see Open TO's & TR's

    Dear Experts, How to see the open TO's & TR's other than from activity Monitor(LL01). Also how to tackle with open TO's & TR's. Thanks & Regards, Olet Malla.

  • Tabular Form - new row at top not working

    I'm trying to add a new row to the top of a tabular form (not manual) vs the bottom using Denes example - http://apex.oracle.com/pls/otn/f?p=31517:215 but it's not working. I absolutely need the records to sort on the date and time, but when I add a

  • Cannot open chess applet in yahoo

    i am having an issue with yahoo chess ( my fave game and i cannot seem to be able to access the rooms for it.i can pick an actual room like the " rat pack " but it says " please wait while the applet loads (could take 3 minutes) if it does not click

  • Weblogic.management.internal.RemoteMBeanServerImpl.invoke

    Hello, I' d like to use Spotlight for Weblogic on our production system, which containes 4 wls node with 1 admin srv (WLS 7.0 sp2). When I start monitor the system with Spotlight, I get the following messages continously in my servers' logs for every