{ "info": { "author": "SUNSCRAPERS", "author_email": "info@sunscrapers.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Web Environment", "Framework :: Django :: 1.10", "Framework :: Django :: 1.8", "Framework :: Django :: 1.9", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Topic :: Communications :: File Sharing" ], "description": "-----------------------------------------------\nDjamazing - a safe storage for AWS\n-----------------------------------------------\n\nDjamazing [d\u0361\u0292\u0259\u02c8me\u026az\u026a\u014b] offers a way to use S3+Cloudfront as Django Storage. It has the\nbenefit over conventional storages, that it generates signed URLs, so only the\nuser who was able to display the URL is also able to access it. Djamazing\ncan work in two modes:\n\n unprotected mode\n In this mode the storage simply generates URL-s to cloudfront. The\n cloudfront distribution should be publicly accessible. This can be used\n for files that don't require special security.\n\n protected mode\n The URLs are signed in this model using the ``SECRET_KEY``. These\n signatures are only valid for the current user. Please remember that\n it is *up to the developer* to ensure that the signed URLs are created\n only when the user that can access them is logged in (some kind of\n per-row authorization should probably be in place). After clicking\n these a special view redirects the user to a signed cloudfront URL.\n This URL is only valid for a very small amount of time.\n\nAWS configuration\n-------------------------\n\n1. Create an S3 bucket.\n2. Generate a keypair for the user that can access the bucket.\n3. Create a cloudfront distribution that has origin in the bucket and is\n restricted to signed URLs.\n4. (for protected mode) Generate a cloudfront keypair that can be used in\n the distribution.\n\nInstallation\n------------------------\n\n1. Install djamazing by pip::\n\n $ pip install djamazing\n\n NOTE: If you are using `djamazing` with Django 1.10 you need a yet\n unpublished version of `django-threadlocals`::\n\n $ pip install git+https://github.com/nebstrebor/django-threadlocals.git\n\n2. Set ``\"djamazing.storage.DjamazingStorage\"`` as your DEFAULT_FILE_STORAGE.\n3. Configure Djamazing::\n \n DJAMAZING = {\n 'CLOUDFRONT_KEY': b\"\"\"-----BEGIN RSA PRIVATE KEY----- \n (...)\n -----END RSA PRIVATE KEY-----\"\"\",\n 'CLOUDFRONT_KEY_ID': '...',\n 'CLOUDFRONT_URL': 'http://....cloudfront.net/', \n 'S3_KEY_ID': '...',\n 'S3_SECRET_KEY': '...',\n 'S3_BUCKET': '...',\n 'SIGNATURE_TIMEOUT': datetime.timedelta(seconds=2),\n }\n\n For unprotected mode omit the ``CLOUDFRONT_KEY`` and ``CLOUDFRONT_KEY_ID``\n keys.\n If you want to store a cloudfornt key in the file ``CLOUDFRONT_KEY_FILE``\n parameter may be also used with file path.\n Note that the `SIGNATURE_TIMEOUT` is the time that doesn't require any human\n interaction, only the browser to handle the redirection. If unspecified - it\n defaults to 1.5 second.\n4. Add threadlocals middleware\n ``'threadlocals.middleware.ThreadLocalMiddleware'`` to your ``MIDDLEWARE``\n5. Add djamazing URLs to ``urls.py``::\n\n url(r'^djamazing/', include(djamazing.urls)),\n\nUsing various configurations in one project\n---------------------------------------------\n\nIf you want to use various configurations in one project (e.g. unprotected for\nstatic file and protected for uploads), you can use inheritance. Create a\nsimple subclass of ``DjamazingStorage`` like::\n\n class StaticStorage(DjamazingStorage):\n \"\"\"Storage for static files\"\"\"\n\n def __init__(self):\n super(StaticStorage, self).__init__(settings.STATIC_DJAMAZING)\n\nnow you can use it as your storage like::\n\n STATICFILES_STORAGE = 'some.path.StaticStorage'\n STATIC_DJAMAZING = { ... }\n\nand the ``STATIC_DJAMAZING`` configuration would override ``DJAMAZING``\nconfiguration for this storage.\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/sunscrapers/djamazing", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "djamazing", "package_url": "https://pypi.org/project/djamazing/", "platform": "", "project_url": "https://pypi.org/project/djamazing/", "project_urls": { "Homepage": "https://github.com/sunscrapers/djamazing" }, "release_url": "https://pypi.org/project/djamazing/0.1.0/", "requires_dist": null, "requires_python": "", "summary": "Safe storage for django using AWS S3+CloudFront", "version": "0.1.0" }, "last_serial": 3553409, "releases": { "0.0.2": [ { "comment_text": "", "digests": { "md5": "fca867a1a3259936dd5c1b61561bce15", "sha256": "8bf8fbb67ecba97d0498459bb3962909807057e011c1173deb557648c689af3e" }, "downloads": -1, "filename": "djamazing-0.0.2.tar.gz", "has_sig": false, "md5_digest": "fca867a1a3259936dd5c1b61561bce15", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5344, "upload_time": "2017-04-20T08:54:01", "url": "https://files.pythonhosted.org/packages/2b/04/830399aea4d53ac36dc71657ed154ffcc75bbe9ff5bef5bceacd416007d1/djamazing-0.0.2.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "e861b44ca5c359835b7346e8ff4d5ce7", "sha256": "745a9dcb78f218c05fba9fa20bf205c0dd5a2a55adaf80c6e869fcf8f51df833" }, "downloads": -1, "filename": "djamazing-0.0.3.tar.gz", "has_sig": false, "md5_digest": "e861b44ca5c359835b7346e8ff4d5ce7", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5392, "upload_time": "2018-01-07T15:31:09", "url": "https://files.pythonhosted.org/packages/c4/c8/ee442f77008a7dead07b327ae7da36e4f9d694dbc8da7b1e876eda7085c2/djamazing-0.0.3.tar.gz" } ], "0.1.0": [ { "comment_text": "", "digests": { "md5": "02ca9b437a8017d100989c1fd9d9f2ac", "sha256": "e30d4ee19824253ed88c0dac7da8fec0606e8b329afb5fe779c457a5f1c7affd" }, "downloads": -1, "filename": "djamazing-0.1.0.tar.gz", "has_sig": false, "md5_digest": "02ca9b437a8017d100989c1fd9d9f2ac", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5557, "upload_time": "2018-02-05T13:58:13", "url": "https://files.pythonhosted.org/packages/10/29/7bc9ebc639097bdd77341ed9e8e56ed479684b59e2d51e83a2cc81014382/djamazing-0.1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "02ca9b437a8017d100989c1fd9d9f2ac", "sha256": "e30d4ee19824253ed88c0dac7da8fec0606e8b329afb5fe779c457a5f1c7affd" }, "downloads": -1, "filename": "djamazing-0.1.0.tar.gz", "has_sig": false, "md5_digest": "02ca9b437a8017d100989c1fd9d9f2ac", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 5557, "upload_time": "2018-02-05T13:58:13", "url": "https://files.pythonhosted.org/packages/10/29/7bc9ebc639097bdd77341ed9e8e56ed479684b59e2d51e83a2cc81014382/djamazing-0.1.0.tar.gz" } ] }