{ "info": { "author": "Zope Foundation and Contributors", "author_email": "zope-dev@zope.org", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Environment :: Web Environment", "Framework :: Zope3", "Intended Audience :: Developers", "License :: OSI Approved :: Zope Public License", "Natural Language :: English", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Internet :: WWW/HTTP" ], "description": "This package provides a trused layer setup for Zope3. Truted means you can \ntravers over objects which you don't have permission for. This is needed if you\nhave a setup with more then one IAuthentication utility. Otherwise you don't\nhav a chance to traverse to the IAthentication utility in the subsite without\nto authenticate at the parent IAuthentication.\n\n\n.. contents::\n\n\n======\nREADME\n======\n\nThis package contains the trusted layer. This layer support a correct set of\ncomponent registration and can be used for inheritation in custom skins.\n\nThe ITrustedBrowserLayer supports the same registration set like the\nIMinimalBrowserLayer. The only difference is, that the trusted layer offers\ntrusted traversal adapters. This means a skin using this layer can traverse\nover a PAU (pluggable IAuthentication utility) without to run into a\nUnautorized exception.\n\nFor more information see also the README.txt in z3c.layer.minimal.\n\n\nTesting\n-------\n\nFor testing the ITrustedBrowserLayer we use the testing skin defined in the\ntests package which uses the ITrustedBrowserLayer. This means, that our\ntesting skin provides also the views defined in the minimal package\nand it's testing views defined in the minimal tests.\n\nLogin as manager first:\n\n >>> from zope.testbrowser.testing import Browser\n >>> manager = Browser()\n >>> manager.addHeader('Authorization', 'Basic mgr:mgrpw')\n\nCheck if we can access the public page.html view which is registred in the\nftesting.zcml file with our skin:\n\n >>> skinURL = 'http://localhost/++skin++TrustedTesting'\n >>> manager.open(skinURL + '/page.html')\n >>> manager.url\n 'http://localhost/++skin++TrustedTesting/page.html'\n\n >>> print manager.contents\n \n \n \n testing\n \n \n \n test page\n \n \n \n \n \n\nNow check the not found page which is a exception view on the exception\n``zope.publisher.interfaces.INotFound``:\n\n >>> manager.open(skinURL + '/foobar.html')\n Traceback (most recent call last):\n ...\n HTTPError: HTTP Error 404: Not Found\n\n >>> print manager.contents\n \n \n \n testing\n \n \n
\n
\n
\n

\n The page you are trying to access is not available\n

\n
\n \n Please try the following:\n \n
\n
    \n
  1. \n Make sure that the Web site address is spelled correctly.\n
  2. \n
  3. \n \n Go back and try another URL.\n \n
  4. \n
\n
\n \n \n \n \n\nAnd check the user error page which is a view registred for\n``zope.exceptions.interfaces.IUserError`` exceptions:\n\n >>> manager.open(skinURL + '/@@usererror.html')\n >>> print manager.contents\n \n \n \n testing\n \n \n
\n
simply user error
\n
\n \n \n \n \n\nAnd check error view registred for\n``zope.interface.common.interfaces.IException``:\n\n >>> manager.open(skinURL + '/@@systemerror.html')\n >>> print manager.contents\n \n \n \n testing\n \n \n
\n
\n
\n

A system error occurred

\n
\n Please contact the administrator.\n \n Go back and try another URL.\n \n
\n \n \n \n \n\nAnd check the ``zope.security.interfaces.IUnauthorized`` view, use a new\nunregistred user (test browser) for this:\n\n >>> unauthorized = Browser()\n >>> unauthorized.open(skinURL + '/@@forbidden.html')\n Traceback (most recent call last):\n ...\n HTTPError: HTTP Error 401: Unauthorized\n\n >>> print unauthorized.contents\n \n \n \n testing\n \n \n
\n \n

Unauthorized

\n \n

You are not authorized

\n \n
\n \n \n \n \n\nWhen an object gets traversed, its security proxy is removed, so its\nsub-objects can be publically accessed, too:\n\n >>> import zope.site.folder\n >>> getRootFolder()['test'] = zope.site.folder.Folder()\n >>> manager.open(skinURL + '/container_contents.html')\n\nThe view displays the types of the content objects inside the root\nfolder. The content objects are not security proxied:\n\n >>> print manager.contents\n []\n\n=======\nCHANGES\n=======\n\n1.1.0 (2009-02-21)\n------------------\n\n- Doctests show that removing security proxies from traversed\n objects is the desired behavior.\n\n- Using ``zope.container`` instead of ``zope.app.container``.\n\n- Made sure that long_description renders properly on pypi.\n\n- Cleaned up dependencies.\n\n\n1.0.1 (2008-01-24)\n------------------\n\n- Bug: Corrected and improved meta-data and documentation.\n\n\n1.0.0 (2008-01-21)\n------------------\n\n- Restructure: Move ``z3c.layer.trusted`` package to it's own top level\n package form ``zope.layer`` to ``z3c.layer.trusted``.\n\n- Bug: Reflect changes in ``zope.app.securitypolicy`` ZCML\n configuration. Prevent loading deprecated module configuration.\n\n- Restructure: Moved implementation from ``z3c.layer`` to\n ``z3c.layer.trusted``.\n\n\n0.2.3 (2007-11-07)\n------------------\n\n- Forward-Bug: Due to a bug in mechanize, the testbrowser throws\n ``httperror_seek_wrapper`` instead of ``HTTPError`` errors. Thanks to RE\n normalizers, the code will now work whether the bug is fixed or not in\n mechanize.\n\n\n0.2.2 (2007-10-31)\n------------------\n\n- Bug: Fixed package meta-data.\n\n- Bug: Fixed test failures due to depency updates.\n\n- Restructure: Fixed deprecation warninf for ``ZopeSecurityPolicy``.\n\n\n0.2.1 (2007-??-??)\n------------------\n\n- Changes unknown.\n\n\n0.2.0 (2007-??-??)\n------------------\n\n- Initial release.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "dynamic": null, "home_page": "http://pypi.python.org/pypi/z3c.layer.trusted", "keywords": "z3c trusted layer zope zope3", "license": "ZPL 2.1", "maintainer": null, "maintainer_email": null, "name": "z3c.layer.trusted", "package_url": "https://pypi.org/project/z3c.layer.trusted/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/z3c.layer.trusted/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://pypi.python.org/pypi/z3c.layer.trusted" }, "provides_extra": null, "release_url": "https://pypi.org/project/z3c.layer.trusted/1.1.0/", "requires_dist": null, "requires_python": null, "summary": "Trusted layer setup for Zope3", "version": "1.1.0", "yanked": false, "yanked_reason": null }, "last_serial": 23499178, "releases": { "1.0.0": [ { "comment_text": "", "digests": { "blake2b_256": "844d15c4352bba794cd443fdda3adeda9c8fa1752e0d76dd29c85cd0bff29ff0", "md5": "880b59948ab35773668f65b50ffb15d4", "sha256": "431ed8bcd15a20c451d29671fd0d599aa7339e44a5235e63a17a5a1ba6cbea2c" }, "downloads": -1, "filename": "z3c.layer.trusted-1.0.0.tar.gz", "has_sig": false, "md5_digest": "880b59948ab35773668f65b50ffb15d4", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6674, "upload_time": "2008-01-21T05:14:22", "upload_time_iso_8601": "2008-01-21T05:14:22Z", "url": "https://files.pythonhosted.org/packages/84/4d/15c4352bba794cd443fdda3adeda9c8fa1752e0d76dd29c85cd0bff29ff0/z3c.layer.trusted-1.0.0.tar.gz", "yanked": false, "yanked_reason": null } ], "1.0.1": [ { "comment_text": "", "digests": { "blake2b_256": "e9c4520af6ad2c1e399ed699505888b5bdd9b9f89ad976e05ccada07f6ec5a8c", "md5": "d03aadf98ac45c6bcfc9116e0a8cd9f1", "sha256": "33aa1d2d9ac3aaef2b2f2fb5b07074fc2b52a3bf836d07c6885f76248a64dd94" }, "downloads": -1, "filename": "z3c.layer.trusted-1.0.1.tar.gz", "has_sig": false, "md5_digest": "d03aadf98ac45c6bcfc9116e0a8cd9f1", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7413, "upload_time": "2008-01-25T03:31:39", "upload_time_iso_8601": "2008-01-25T03:31:39Z", "url": "https://files.pythonhosted.org/packages/e9/c4/520af6ad2c1e399ed699505888b5bdd9b9f89ad976e05ccada07f6ec5a8c/z3c.layer.trusted-1.0.1.tar.gz", "yanked": false, "yanked_reason": null } ], "1.1.0": [ { "comment_text": "", "digests": { "blake2b_256": "617dd585ab9eae65c44ff061ed2351a90e677dfdaf078aa77ec6dbf1c054d289", "md5": "03d59bdf95d9e4da54cd06414fc8e9d3", "sha256": "e9ce5e6f3a4407f5c6f4389a682ef0bf347adeee110e3ef7c2a94783fe688b79" }, "downloads": -1, "filename": "z3c.layer.trusted-1.1.0.tar.gz", "has_sig": false, "md5_digest": "03d59bdf95d9e4da54cd06414fc8e9d3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8465, "upload_time": "2009-02-21T15:40:46", "upload_time_iso_8601": "2009-02-21T15:40:46.099260Z", "url": "https://files.pythonhosted.org/packages/61/7d/d585ab9eae65c44ff061ed2351a90e677dfdaf078aa77ec6dbf1c054d289/z3c.layer.trusted-1.1.0.tar.gz", "yanked": false, "yanked_reason": null } ] }, "urls": [ { "comment_text": "", "digests": { "blake2b_256": "617dd585ab9eae65c44ff061ed2351a90e677dfdaf078aa77ec6dbf1c054d289", "md5": "03d59bdf95d9e4da54cd06414fc8e9d3", "sha256": "e9ce5e6f3a4407f5c6f4389a682ef0bf347adeee110e3ef7c2a94783fe688b79" }, "downloads": -1, "filename": "z3c.layer.trusted-1.1.0.tar.gz", "has_sig": false, "md5_digest": "03d59bdf95d9e4da54cd06414fc8e9d3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8465, "upload_time": "2009-02-21T15:40:46", "upload_time_iso_8601": "2009-02-21T15:40:46.099260Z", "url": "https://files.pythonhosted.org/packages/61/7d/d585ab9eae65c44ff061ed2351a90e677dfdaf078aa77ec6dbf1c054d289/z3c.layer.trusted-1.1.0.tar.gz", "yanked": false, "yanked_reason": null } ], "vulnerabilities": [] }