cryptography is a package designed to expose cryptographic primitives and recipes to Python developers.
Find a file
Paul Kehrer ed32105be8 Backwards incompatible change to DNSName (#3951)
* Backwards incompatible change to DNSName

During this release cycle we decided to officially deprecate passing
U-labels to our GeneralName constructors. At first we tried changing
this in a purely backwards compatible way but get_values_for_type made
that untenable. This PR modifies DNSName to take three different types.
U-label strings (which raises a deprecation warning), A-label strings
(the new preferred type), and bytes (which are assumed to be decodable
to unicode strings). The latter, while supported, is primarily intended
for use by our parser and allows us to return the actual encoded data in
a certificate even if it has not been properly encoded to A-label before
the certificate is created. (Of course, if the certificate contains
invalid utf8 sequences this will still fail, but let's handle one
catastrophic failure at a time).

* coverage

* don't delete that asterisk from a test. it does things.

* no bytes in DNSName. Private constructor for bypassing validation

* test unicode in dnsname (yuck)

* fix docs

* empty commit, you disappoint me codecov

* CI is the worst
2017-10-10 20:11:44 -04:00
.github Fixed #3520 -- added a github issue template for bugs (#3807) 2017-07-24 15:28:56 +03:00
.jenkins remove py26 windows and macOS wheels (#3921) 2017-09-19 20:03:02 -04:00
.travis coverage pin test part deux (#3908) 2017-09-12 21:30:51 -04:00
docs Backwards incompatible change to DNSName (#3951) 2017-10-10 20:11:44 -04:00
src Backwards incompatible change to DNSName (#3951) 2017-10-10 20:11:44 -04:00
tests Backwards incompatible change to DNSName (#3951) 2017-10-10 20:11:44 -04:00
vectors add utf8 DNSName x509 vector (#3952) 2017-10-09 22:23:24 -04:00
.coveragerc properly merge pypy coverage with coveragerc paths 2016-01-07 10:41:04 -08:00
.gitignore Fix .gitignore. 2015-09-26 22:31:53 +08:00
.mention-bot @dstufft is also annoyed by the mentionbot 2016-01-02 10:25:39 -06:00
.travis.yml disable travis mac builders and add a mac jenkins build (#3933) 2017-09-20 08:49:03 -04:00
AUTHORS.rst Dh serialization changelog (#3385) 2017-02-08 12:38:42 +08:00
CHANGELOG.rst Add support for AES XTS (#3900) 2017-10-01 22:03:20 -04:00
codecov.yml revert codecov.yml workaround and pin coverage to 4.3.4 (#3662) 2017-06-03 14:26:56 -04:00
CONTRIBUTING.rst
dev-requirements.txt require a version of twine that uses pypi.org (#3743) 2017-07-01 10:50:49 -05:00
Jenkinsfile do downstream builds as part of our normal parallel jenkins pipeline (#3948) 2017-10-03 22:53:18 -04:00
LICENSE New osrandom_engine in C (#3229) 2016-12-09 10:02:26 -06:00
LICENSE.APACHE
LICENSE.BSD
LICENSE.PSF C locking callback (#3226) 2016-11-13 12:55:22 -08:00
MANIFEST.in convert to cffi 1.0 precompile system 2015-06-07 23:27:54 -05:00
README.rst remove python 3.3 from CI (#3729) 2017-06-26 21:08:33 -04:00
release.py Fixes #3821 -- improve output during release.py (#3848) 2017-08-04 12:45:11 -05:00
setup.py disable smart quotes in sphinx to workaround a spellchecker issue (#3946) 2017-10-03 21:16:50 -04:00
tox.ini coverage pin test part deux (#3908) 2017-09-12 21:30:51 -04:00

pyca/cryptography
=================

.. image:: https://img.shields.io/pypi/v/cryptography.svg
    :target: https://pypi.python.org/pypi/cryptography/
    :alt: Latest Version

.. image:: https://readthedocs.org/projects/cryptography/badge/?version=latest
    :target: https://cryptography.io
    :alt: Latest Docs

.. image:: https://travis-ci.org/pyca/cryptography.svg?branch=master
    :target: https://travis-ci.org/pyca/cryptography

.. image:: https://codecov.io/github/pyca/cryptography/coverage.svg?branch=master
    :target: https://codecov.io/github/pyca/cryptography?branch=master


``cryptography`` is a package which provides cryptographic recipes and
primitives to Python developers.  Our goal is for it to be your "cryptographic
standard library". It supports Python 2.6-2.7, Python 3.4+, and PyPy 5.3+.

``cryptography`` includes both high level recipes and low level interfaces to
common cryptographic algorithms such as symmetric ciphers, message digests, and
key derivation functions. For example, to encrypt something with
``cryptography``'s high level symmetric encryption recipe:

.. code-block:: pycon

    >>> from cryptography.fernet import Fernet
    >>> # Put this somewhere safe!
    >>> key = Fernet.generate_key()
    >>> f = Fernet(key)
    >>> token = f.encrypt(b"A really secret message. Not for prying eyes.")
    >>> token
    '...'
    >>> f.decrypt(token)
    'A really secret message. Not for prying eyes.'

You can find more information in the `documentation`_.

You can install ``cryptography`` with:

.. code-block:: console

    $ pip install cryptography

For full details see `the installation documentation`_.

Discussion
~~~~~~~~~~

If you run into bugs, you can file them in our `issue tracker`_.

We maintain a `cryptography-dev`_ mailing list for development discussion.

You can also join ``#cryptography-dev`` on Freenode to ask questions or get
involved.


.. _`documentation`: https://cryptography.io/
.. _`the installation documentation`: https://cryptography.io/en/latest/installation/
.. _`issue tracker`: https://github.com/pyca/cryptography/issues
.. _`cryptography-dev`: https://mail.python.org/mailman/listinfo/cryptography-dev