:: com :: sun :: star :: security ::
|
interface XAccessController |
|
- Description
- Interface for checking permissions and invoking privileged or restricted
actions.
- Since
- OOo 1.1.2
|
Methods' Summary |
checkPermission |
Determines whether the access request indicated by the specified
permission should be allowed or denied, based on the security policy
currently in effect.
The semantics are equivalent to the security permission classes of
the Java platform.
|
doRestricted |
Perform the specified action restricting permissions to the given
XAccessControlContext.
The action is performed with the intersection of the permissions of the currently installed
XAccessControlContext, the given XAccessControlContext and the security policy currently
in effect. The latter includes static security, e.g. based on user credentials.
|
doPrivileged |
Perform the specified action adding a set of permissions defined by the given
XAccessControlContext.
The action is performed with the union of the permissions of the currently installed
XAccessControlContext, the given XAccessControlContext and the security policy currently
in effect. The latter includes static security, e.g. based on user credentials.
|
getContext |
This method takes a "snapshot" of the current calling context
and returns it.
|
Methods' Details |
checkPermission
- Description
- Determines whether the access request indicated by the specified
permission should be allowed or denied, based on the security policy
currently in effect.
The semantics are equivalent to the security permission classes of
the Java platform.
You can also pass a sequence of permissions (sequence< any >) to check
a set of permissions, e.g. for performance reasons.
This method quietly returns if the access request is permitted,
or throws a suitable AccessControlException otherwise.
- Parameter perm
- permission to be checked
- Throws
- AccessControlException
thrown if access is denied
- See also
- AccessControlException, AllPermission, RuntimePermission, ::com::sun::star::io::FilePermission, ::com::sun::star::connection::SocketPermission
|
|
doRestricted
- Description
- Perform the specified action restricting permissions to the given
XAccessControlContext.
The action is performed with the intersection of the permissions of the currently installed
XAccessControlContext, the given XAccessControlContext and the security policy currently
in effect. The latter includes static security, e.g. based on user credentials.
If the specified XAccessControlContext is null, then the action is performed
with unmodified permissions, i.e. the call makes no sense.
- Parameter action
- action object to be executed
- Parameter restriction
- access control context to restrict permission; null for no restriction
- Returns
- result
- Throws
- com::sun::star::uno::Exception
any UNO exception may be thrown
|
|
doPrivileged
- Description
- Perform the specified action adding a set of permissions defined by the given
XAccessControlContext.
The action is performed with the union of the permissions of the currently installed
XAccessControlContext, the given XAccessControlContext and the security policy currently
in effect. The latter includes static security, e.g. based on user credentials.
If the given XAccessControlContext is null, then the action is performed
only with the permissions of the security policy currently in effect.
@attention
Do carefully use this method only for well known use-cases to avoid exploits!
Script engines executing sandboxed scripts should generally deny calling this
method.
- Parameter action
- action object to be executed
- Parameter restriction
- access control context to restrict permission; null for no restriction
- Returns
- result
- Throws
- com::sun::star::uno::Exception
any UNO exception may be thrown
|
|
getContext
- Description
- This method takes a "snapshot" of the current calling context
and returns it.
This context may then be checked at a later point, possibly in another thread.
- Returns
- snapshot of context
|
|
Top of Page
Copyright © 2000, 2014 LibreOffice contributors and/or their affiliates. All rights reserved.
LibreOffice was created by The Document Foundation, based on OpenOffice.org, which is Copyright 2000, 2010 Oracle and/or its affiliates.
The Document Foundation acknowledges all community members, please find more info at our website.
Privacy Policy | Impressum (Legal Info) | Copyright information: The source code of LibreOffice is licensed under the GNU Lesser General Public License (LGPLv3). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.