Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Restricting user access to a database?

Re: Restricting user access to a database?

From: stefano biotto <sbiotto_at_tiscali.it>
Date: 18 Jul 2003 08:38:37 -0700
Message-ID: <f0c9a526.0307180738.78905281@posting.google.com>

  1. Create a role APPLROLE protected by a password (do not tell to user of application!)
  2. give all privileges on table of application to this role (insert,update,delete,select,..and everything your need..)
  3. grant this role to user of application but non as default role
  4. put some code like this below in the menu module (.mmb) the fist thing oracle form executes

function auth return boolean is

	ret			number;
	txt_set_role		varchar2(100);	
BEGIN
	txt_set_role:=const.role_name||' IDENTIFIED BY '||const.role_passwd;
  dbms_session.set_role(txt_set_role);
  return(true);
EXCEPTION
	WHEN OTHERS THEN
	   RETURN(false);

END; e) put the same code in every befor-parameter-form trigger

   in your report

I've done and works! Received on Fri Jul 18 2003 - 10:38:37 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US