ORA-04088 ORA-01403 and ORA-06512 errors [message #132059] |
Wed, 10 August 2005 11:22 |
vikramjogi
Messages: 71 Registered: June 2005 Location: Scranton
|
Member |
|
|
Hello All,
I have put an “after logon on trigger” on the database which is restricing a user to logon using SQLPLUS tool. The trigger works fine and is giving me the result I am expecting but it throws errors in the alert log file. Below is the trigger which works fine and is restricting the user to use SQLPLUS tool
******************Trigger***************************************
CREATE OR REPLACE TRIGGER block_eis
AFTER LOGON ON DATABASE
DECLARE
v_prog sys.V_$SESSION.program%TYPE;
v_prog1 sys.V_$SESSION.username%TYPE;
v_prog2 sys.V_$SESSION.osuser%TYPE;
BEGIN
SELECT program,username,osuser INTO v_prog,v_prog1,v_prog2 FROM sys.V_$SESSION
WHERE audsid = USERENV('SESSIONID')
AND audsid != 0; -- Allow SYS Connections;
IF UPPER(v_prog1) LIKE '%EIS%' AND UPPER(v_prog) LIKE '%SQLPLUS%' AND UPPER(v_prog2) NOT LIKE '%ZEKEPSRV%' THEN
RAISE_APPLICATION_ERROR(-20001, 'Sorry! Batch only USER');
END IF;
END;
****************************END TRIGGER *************************
The errors I get are:
ORA-04088: error during execution of trigger 'ORACLE.BLOCK_EIS'
ORA-01403: no data found
ORA-06512: at line 6
Below is the trace file that is generated:
Error in executing triggers on connect internal
*** 2005-08-08 14:29:22.859
ksedmp: internal or fatal error
ORA-04088: error during execution of trigger 'ORACLE.BLOCK_EIS'
ORA-01403: no data found
ORA-06512: at line 6
Please provide solution to this issue. Thanks in advance
Vik Jogi
|
|
|
Re: ORA-04088 ORA-01403 and ORA-06512 errors [message #132068 is a reply to message #132059] |
Wed, 10 August 2005 12:31 |
Art Metzer
Messages: 2480 Registered: December 2002
|
Senior Member |
|
|
Forget about your error; your so-called restriction is easy to circumvent.
Do this:- Go to $ORACLE_HOME/bin.
- Copy sqlplus.exe.
- Paste it into the same folder, renaming it, oh, "anythingiwant.exe".
- Double-click this copied executable to launch SQL*Plus.
- Run the following query from this copied executable, and you should see what I see:
SQL> SELECT program FROM v$session WHERE audsid = USERENV('SESSIONID')
2 /
PROGRAM
------------------------------------------------
anythingiwant.exe
SQL> For more information, please read this AskTom thread.
|
|
|
Re: ORA-04088 ORA-01403 and ORA-06512 errors [message #132075 is a reply to message #132068] |
Wed, 10 August 2005 13:42 |
vikramjogi
Messages: 71 Registered: June 2005 Location: Scranton
|
Member |
|
|
Art Metzer,
I am a new-bee as a oracle DBA. I have my own security implemented on this. I have another trigger which looks for all the EXE's that come in with a userid i want to restrict. Even though you come in with your so called "anythingiwant.exe" my trigger wont let that user because it blocks all the EXE files using this user id.
I knew even before i wrote the trigger that this is possible but i was not having no other go or no other solution.
Anyways please help me out if you have solution for the issue i have posted.Sorry if i was not polite in giving the answer. Please help me out guys.
Thanks,
Vik Jogi
|
|
|
|
|