You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

97 lines
2.8KB

  1. Metadata-Version: 2.1
  2. Name: itsdangerous
  3. Version: 2.0.1
  4. Summary: Safely pass data to untrusted environments and back.
  5. Home-page: https://palletsprojects.com/p/itsdangerous/
  6. Author: Armin Ronacher
  7. Author-email: armin.ronacher@active-4.com
  8. Maintainer: Pallets
  9. Maintainer-email: contact@palletsprojects.com
  10. License: BSD-3-Clause
  11. Project-URL: Donate, https://palletsprojects.com/donate
  12. Project-URL: Documentation, https://itsdangerous.palletsprojects.com/
  13. Project-URL: Changes, https://itsdangerous.palletsprojects.com/changes/
  14. Project-URL: Source Code, https://github.com/pallets/itsdangerous/
  15. Project-URL: Issue Tracker, https://github.com/pallets/itsdangerous/issues/
  16. Project-URL: Twitter, https://twitter.com/PalletsTeam
  17. Project-URL: Chat, https://discord.gg/pallets
  18. Platform: UNKNOWN
  19. Classifier: Development Status :: 5 - Production/Stable
  20. Classifier: Intended Audience :: Developers
  21. Classifier: License :: OSI Approved :: BSD License
  22. Classifier: Operating System :: OS Independent
  23. Classifier: Programming Language :: Python
  24. Requires-Python: >=3.6
  25. Description-Content-Type: text/x-rst
  26. ItsDangerous
  27. ============
  28. ... so better sign this
  29. Various helpers to pass data to untrusted environments and to get it
  30. back safe and sound. Data is cryptographically signed to ensure that a
  31. token has not been tampered with.
  32. It's possible to customize how data is serialized. Data is compressed as
  33. needed. A timestamp can be added and verified automatically while
  34. loading a token.
  35. Installing
  36. ----------
  37. Install and update using `pip`_:
  38. .. code-block:: text
  39. pip install -U itsdangerous
  40. .. _pip: https://pip.pypa.io/en/stable/quickstart/
  41. A Simple Example
  42. ----------------
  43. Here's how you could generate a token for transmitting a user's id and
  44. name between web requests.
  45. .. code-block:: python
  46. from itsdangerous import URLSafeSerializer
  47. auth_s = URLSafeSerializer("secret key", "auth")
  48. token = auth_s.dumps({"id": 5, "name": "itsdangerous"})
  49. print(token)
  50. # eyJpZCI6NSwibmFtZSI6Iml0c2Rhbmdlcm91cyJ9.6YP6T0BaO67XP--9UzTrmurXSmg
  51. data = auth_s.loads(token)
  52. print(data["name"])
  53. # itsdangerous
  54. Donate
  55. ------
  56. The Pallets organization develops and supports ItsDangerous and other
  57. popular packages. In order to grow the community of contributors and
  58. users, and allow the maintainers to devote more time to the projects,
  59. `please donate today`_.
  60. .. _please donate today: https://palletsprojects.com/donate
  61. Links
  62. -----
  63. - Documentation: https://itsdangerous.palletsprojects.com/
  64. - Changes: https://itsdangerous.palletsprojects.com/changes/
  65. - PyPI Releases: https://pypi.org/project/ItsDangerous/
  66. - Source Code: https://github.com/pallets/itsdangerous/
  67. - Issue Tracker: https://github.com/pallets/itsdnagerous/issues/
  68. - Website: https://palletsprojects.com/p/itsdangerous/
  69. - Twitter: https://twitter.com/PalletsTeam
  70. - Chat: https://discord.gg/pallets