Top   Module   Use   Manual   Index 
 EXPORTING SERVICES | METHODS' SUMMARY | METHODS' DETAILS 

com :: sun :: star :: security :: auth ::

interface XSubject

Base Interface
com::sun::star::uno::XInterface

Description

WARNING: this is just a draft and may be changed!

A XSubject represents a grouping of related information for a single entity, such as a person.

Such information includes the subject's identities as well as its security-related attributes (passwords and cryptographic keys, for example). Subjects may potentially have multiple identities. Each identity is represented as a principal within the subject. Principals simply bind names to a subject.

For example, a subject that happens to be a person, Alice, might have two principals: one which binds "Alice Bar", the name on her driver license, to the subject, and another which binds, "999-99-9999", the number on her student identification card, to the subject. Both principals refer to the same subject even though each has a different name.



Methods' Summary

doAs Perform work as a particular subject, i.e. restriction applies to intersection of all caller's permissions and subject's permissions.
doAsPrivileged Perform privileged work as a particular subject, i.e. restrictions applies to intersection of subject's permissions along with the given XAccessControlContext.
logout Logs out the subject.

Methods' Details

doAs
 
any
doAs(
[ in ] com::sun::star::security::auth::XPrivilegedAction action )
raises ( com::sun::star::uno::Exception );

Description
Perform work as a particular subject, i.e. restriction applies to intersection of all caller's permissions and subject's permissions.
Parameter action
action to be performed
Returns
value returned by the privileged action
Throws
com::sun::star::uno::Exception any UNO exception may be thrown by the privileged action
doAsPrivileged
 
any
doAsPrivileged(
[ in ] com::sun::star::security::auth::XPrivilegedAction action,
[ in ] com::sun::star::security::XAccessControlContext restriction )
raises ( com::sun::star::uno::Exception );

Description
Perform privileged work as a particular subject, i.e. restrictions applies to intersection of subject's permissions along with the given XAccessControlContext.

If the given one is null, then it won't be taken for permission checks.

Parameter action
action to be performed
Parameter restriction
access control context to restrict permission; null for no restriction
Returns
value returned by the privileged action
Throws
com::sun::star::uno::Exception any UNO exception may be thrown by the privileged action
logout
 
void
logout();
Description
Logs out the subject.

Top of Page