Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(209)  |  Call(123)  |  Derive(0)  |  Import(86)
Allow a module and all its contents to be used from a
restricted Script. The argument module_name may be a simple
or dotted module or package name. Note that if a package
path is given, all modules in the path will be available.

        def allow_module(module_name):
    """Allow a module and all its contents to be used from a
    restricted Script. The argument module_name may be a simple
    or dotted module or package name. Note that if a package
    path is given, all modules in the path will be available."""
    ModuleSecurityInfo(module_name).setDefaultAccess(1)
    dot = module_name.find('.')
    while dot > 0:
        ModuleSecurityInfo(module_name[:dot]).setDefaultAccess(1)
        dot = module_name.find('.', dot + 1)
        


src/p/l/plumi.app-4.5/src/plumi.app/plumi/app/install.py   plumi.app(Download)
from DateTime import DateTime
from hashlib import sha1 as sha
from AccessControl import allow_module
 
from zope.location.interfaces import ISite
from plumi.app.translations import createTranslations, deleteTranslations
 
allow_module('plumi.app.member_area.py')
 
_ = MessageFactory("plumi")

src/p/l/plumi.app-HEAD/src/plumi.app/plumi/app/install.py   plumi.app(Download)
from DateTime import DateTime
from hashlib import sha1 as sha
from AccessControl import allow_module
 
from zope.location.interfaces import ISite
from plumi.app.translations import createTranslations, deleteTranslations
 
allow_module('plumi.app.member_area.py')
 
_ = MessageFactory("plumi")

src/c/y/cyn.in-HEAD/src/ubify.cyninv2theme/ubify/cyninv2theme/__init__.py   cyn.in(Download)
#Mumbai-400064, India
###############################################################################
from AccessControl import allow_module
from AccessControl import ModuleSecurityInfo
from AccessControl import ClassSecurityInfo

src/a/r/arecibo-HEAD/clients/plone/clearwind.arecibo/clearwind/arecibo/__init__.py   arecibo(Download)
from AccessControl import allow_module, allow_class, allow_type
from AccessControl import ModuleSecurityInfo, ClassSecurityInfo
 
ModuleSecurityInfo('clearwind.arecibo.wrapper').declarePublic('arecibo')
 

src/c/l/clearwind.arecibo-0.7/clearwind/arecibo/__init__.py   clearwind.arecibo(Download)
from AccessControl import allow_module, allow_class, allow_type
from AccessControl import ModuleSecurityInfo, ClassSecurityInfo
 
ModuleSecurityInfo('clearwind.arecibo.wrapper').declarePublic('arecibo')
 

src/c/y/cyn.in-HEAD/src/ubify.recyclebin/ubify/recyclebin/__init__.py   cyn.in(Download)
from ubify.recyclebin.config import *
 
from AccessControl import allow_module
from AccessControl import ModuleSecurityInfo
ModuleSecurityInfo("ubify.recyclebin").declarePublic("movetotrash")

src/e/r/erp5-HEAD/product/TimerService/__init__.py   erp5(Download)
 
from App.ImageFile import ImageFile
from AccessControl import ModuleSecurityInfo, allow_module
from AccessControl.Permissions import view
 

src/p/r/Products.AttachmentField-1.4.5/Products/AttachmentField/__init__.py   Products.AttachmentField(Download)
 
import Globals
from AccessControl import ModuleSecurityInfo, allow_module
 
import AccessControl.Permissions

src/b/e/betahaus.memberprofile-0.2rc1/betahaus/memberprofile/utilities.py   betahaus.memberprofile(Download)
from zope.interface import implements
from zope.event import notify
from AccessControl import ModuleSecurityInfo, allow_module, allow_class
from Products.Archetypes.event import ObjectInitializedEvent
from Products.Archetypes.utils import shasattr

src/b/i/bika.lims-3.01a/bika/lims/idserver.py   bika.lims(Download)
from AccessControl import ModuleSecurityInfo, allow_module
from DateTime import DateTime
from Products.Archetypes.public import DisplayList
from Products.CMFCore.utils import getToolByName
from Products.CMFPlone.TranslationServiceTool import TranslationServiceTool

Previous  1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9  Next