Sean C Sullivan wrote:
>
> I've got two EJB's:
>
>         EJBA - a stateful session bean
>         EJBB - an Entity bean
>
> I implemented home and remote interfaces for both beans.
>
> I want to setup the following:
>   1) allow remote clients to call methods on EJBA
>   2) deny remote clients access to methods on EJBB
>   3) allow EJBA to call methods on EJBB
>
> #1 is easy to do.
>
> I'm looking for the best way to satisfy requirements #2 and #3.

Sean,

Transactions in an application server typically run in the security context
of the server itself or some other specific principle, but not in the
context of the client. Let me illustrate the point by example:

A payroll clerk is not allowed to issue database calls to the payroll
database, even though he IS allowed to run the IncreasePay transaction.
Likewise the programmer of IncreasePay is not allowed to execute
IncreasePay on the production application server. The IncreasePay
transaction runs under the security context of PayrollProcessing which no
human can log on as. PayrollProcessing is the only security context which
has access to the Payroll database. The (human) owner of PayrollProcessing
must satisfy herself that each version of IncreasePay as supplied by the
programmer meets the business requirements.

So in answer to your question EJBA should run with a specific security
principle giving it access to (at least) the set of resources it needs.
EJBB is one of those resources and it should require its caller to be in
that context.

Ian McCallion
CICS Business Unit
IBM Hursley
[EMAIL PROTECTED]
Tel: ++44-1962-818065
Fax: ++44-1962-818069

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to