Table of Contents

Class: BasicUser Zope-2.2.1-src/lib/python/AccessControl/User.py

Base class for all User objects

Base Classes   
Implicit
Methods   
__allow_access_to_unprotected_subobjects__
__init__
__len__
__str__
_getPassword
_shared_roles
allowed
authenticate
getDomains
getId
getRoles
getRolesInContext
getUserName
has_permission
has_role
  __allow_access_to_unprotected_subobjects__ 
__allow_access_to_unprotected_subobjects__ (
        self,
        name,
        value=None,
        )

Maybe allow access to unprotected attributes. Note that this is temporary to avoid exposing information but without breaking everyone's current code. In the future the security will be clamped down and permission-protected here. Because there are a fair number of user object types out there, this method denies access to names that are private parts of the standard User interface or implementation only. The other approach (only allowing access to public names in the User interface) would probably break a lot of other User implementations with extended functionality that we cant anticipate from the base scaffolding.

  __init__ 
__init__ (
        self,
        name,
        password,
        roles,
        domains,
        )

Exceptions   
NotImplemented
  __len__ 
__len__ ( self )

  __str__ 
__str__ ( self )

  _getPassword 
_getPassword ( self )

Return the password of the user.

Exceptions   
NotImplemented
  _shared_roles 
_shared_roles ( self,  parent )

  allowed 
allowed (
        self,
        parent,
        roles=None,
        )

Check whether the user has access to parent, assuming that parent.__roles__ is the given roles.

  authenticate 
authenticate (
        self,
        password,
        request,
        )

  getDomains 
getDomains ( self )

Return the list of domain restrictions for a user

Exceptions   
NotImplemented
  getId 
getId ( self )

Get the ID of the user. The ID can be used, at least from Python, to get the user from the user's UserDatabase

  getRoles 
getRoles ( self )

Return the list of roles assigned to a user.

Exceptions   
NotImplemented
  getRolesInContext 
getRolesInContext ( self,  object )

Return the list of roles assigned to the user, including local roles assigned in context of the passed in object.

  getUserName 
getUserName ( self )

Return the username of a user

Exceptions   
NotImplemented
  has_permission 
has_permission (
        self,
        permission,
        object,
        )

Check to see if a user has a given permission on an object.

  has_role 
has_role (
        self,
        roles,
        object=None,
        )

Check to see if a user has a given role or roles.


Table of Contents

This document was automatically generated on Mon Sep 4 07:33:06 2000 by HappyDoc version r0_6