././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4808931
django-registration-3.3/ 0000755 0000767 0000024 00000000000 00000000000 014316 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1516537948.0
django-registration-3.3/AUTHORS 0000644 0000767 0000024 00000002116 00000000000 015366 0 ustar 00james staff The primary author of django-registration is James Bennett, who may
be found online at .
Over the many years of django-registration's development, however,
many others have contributed code, documentation and translations, and
django-registration would not be what it is without their help. Below
is a list of contributors who can be identified from the development
history:
* Samuel Adam
* A. Al-Ibrahim
* Adam Alton
* Luis Felipe Álvarez Burgos
* Florian Apolloner
* Carles Barrobés
* Nico den Boer
* Rune Bromer
* Joost Cassee
* Flavio Curella
* Baptiste Darthenay
* Nebojsa Djordjevic
* Liang Feng
* Ilya Filippov
* Rapahel Hertzog
* Recep Kirmizi
* Domen Kožar
* Meir Kriheli
* Björn Kristinsson
* Panos Laganakos
* Nicola Larosa
* Jannis Leidel
* Jon Lønne
* João Luiz Lorencetti
* Italo Maia
* Mohsen Mansouryar
* Leonardo Manuel Rocha
* Nuno Mariz
* Andy Mikhailenko
* Vladislav Mitov
* Marko Mrdjenovic
* Michael Niewöhner
* Shinya Okano
* Young Gyu Park
* Duncan Parkes
* Patrick Samson
* Daniel Samuels
* Ernesto Rico Schmidt
* Emil Stenström
* Jarek Zgoda
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1653721498.0
django-registration-3.3/LICENSE 0000644 0000767 0000024 00000002763 00000000000 015333 0 ustar 00james staff Copyright (c) 2007-2022, James Bennett
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials provided
with the distribution.
* Neither the name of the author nor the names of other
contributors may be used to endorse or promote products derived
from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1581881094.0
django-registration-3.3/MANIFEST.in 0000644 0000767 0000024 00000000207 00000000000 016053 0 ustar 00james staff include LICENSE
include MANIFEST.in
include AUTHORS
recursive-include docs *
include tox.ini
include runtests.py
graft src
graft tests
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4810357
django-registration-3.3/PKG-INFO 0000644 0000767 0000024 00000003236 00000000000 015417 0 ustar 00james staff Metadata-Version: 2.1
Name: django-registration
Version: 3.3
Summary: An extensible user-registration application for Django
Home-page: https://github.com/ubernostrum/django-registration/
Author: James Bennett
Author-email: james@b-list.org
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Web Environment
Classifier: Framework :: Django
Classifier: Framework :: Django :: 3.1
Classifier: Framework :: Django :: 3.2
Classifier: Framework :: Django :: 4.0
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: BSD License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Topic :: Utilities
Requires-Python: >=3.7
License-File: LICENSE
.. -*-restructuredtext-*-
.. image:: https://github.com/ubernostrum/django-registration/workflows/CI/badge.svg
:alt: CI status image
:target: https://github.com/ubernostrum/django-registration/actions?query=workflow%3ACI
This is a user-registration application for `Django
`_. There are two registration
workflows (one-step, and two-step with activation) built in, and it's
designed to be extensible and support building additional workflows.
To get started, check out `the documentation
`_.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1607766037.0
django-registration-3.3/README.rst 0000644 0000767 0000024 00000001102 00000000000 015777 0 ustar 00james staff .. -*-restructuredtext-*-
.. image:: https://github.com/ubernostrum/django-registration/workflows/CI/badge.svg
:alt: CI status image
:target: https://github.com/ubernostrum/django-registration/actions?query=workflow%3ACI
This is a user-registration application for `Django
`_. There are two registration
workflows (one-step, and two-step with activation) built in, and it's
designed to be extensible and support building additional workflows.
To get started, check out `the documentation
`_.
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4438365
django-registration-3.3/docs/ 0000755 0000767 0000024 00000000000 00000000000 015246 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1516537948.0
django-registration-3.3/docs/Makefile 0000644 0000767 0000024 00000005713 00000000000 016714 0 ustar 00james staff # Makefile for Sphinx documentation
#
# You can set these variables from the command line.
SPHINXOPTS =
SPHINXBUILD = sphinx-build
PAPER =
# Internal variables.
PAPEROPT_a4 = -D latex_paper_size=a4
PAPEROPT_letter = -D latex_paper_size=letter
ALLSPHINXOPTS = -d _build/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
.PHONY: help clean html dirhtml pickle json htmlhelp qthelp latex changes linkcheck doctest
help:
@echo "Please use \`make ' where is one of"
@echo " html to make standalone HTML files"
@echo " dirhtml to make HTML files named index.html in directories"
@echo " pickle to make pickle files"
@echo " json to make JSON files"
@echo " htmlhelp to make HTML files and a HTML help project"
@echo " qthelp to make HTML files and a qthelp project"
@echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
@echo " changes to make an overview of all changed/added/deprecated items"
@echo " linkcheck to check all external links for integrity"
@echo " doctest to run all doctests embedded in the documentation (if enabled)"
clean:
-rm -rf _build/*
html:
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) _build/html
@echo
@echo "Build finished. The HTML pages are in _build/html."
dirhtml:
$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) _build/dirhtml
@echo
@echo "Build finished. The HTML pages are in _build/dirhtml."
pickle:
$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) _build/pickle
@echo
@echo "Build finished; now you can process the pickle files."
json:
$(SPHINXBUILD) -b json $(ALLSPHINXOPTS) _build/json
@echo
@echo "Build finished; now you can process the JSON files."
htmlhelp:
$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) _build/htmlhelp
@echo
@echo "Build finished; now you can run HTML Help Workshop with the" \
".hhp project file in _build/htmlhelp."
qthelp:
$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) _build/qthelp
@echo
@echo "Build finished; now you can run "qcollectiongenerator" with the" \
".qhcp project file in _build/qthelp, like this:"
@echo "# qcollectiongenerator _build/qthelp/django-registration.qhcp"
@echo "To view the help file:"
@echo "# assistant -collectionFile _build/qthelp/django-registration.qhc"
latex:
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) _build/latex
@echo
@echo "Build finished; the LaTeX files are in _build/latex."
@echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \
"run these through (pdf)latex."
changes:
$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) _build/changes
@echo
@echo "The overview file is in _build/changes."
linkcheck:
$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) _build/linkcheck
@echo
@echo "Link check complete; look for any errors in the above output " \
"or in _build/linkcheck/output.txt."
doctest:
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) _build/doctest
@echo "Testing of doctests in the sources finished, look at the " \
"results in _build/doctest/output.txt."
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1580075032.0
django-registration-3.3/docs/activation-workflow.rst 0000644 0000767 0000024 00000023141 00000000000 022012 0 ustar 00james staff .. _activation-workflow:
.. module:: django_registration.backends.activation
The two-step activation workflow
================================
The two-step activation workflow, found in
`django_registration.backends.activation`, implements a two-step
registration process: a user signs up, an inactive account is created,
and an email is sent containing an activation link which must be
clicked to make the account active.
Behavior and configuration
--------------------------
A default URLconf is provided, which you can
:func:`~django.urls.include` in your URL configuration; that URLconf
is `django_registration.backends.activation.urls`. For example, to
place user registration under the URL prefix `/accounts/`, you could
place the following in your root URLconf:
.. code-block:: python
from django.urls import include, path
urlpatterns = [
# Other URL patterns ...
path('accounts/', include('django_registration.backends.activation.urls')),
path('accounts/', include('django.contrib.auth.urls')),
# More URL patterns ...
]
That also sets up the views from `django.contrib.auth` (login, logout,
password reset, etc.).
This workflow makes use of up to three settings (click for details on
each):
* :data:`~django.conf.settings.ACCOUNT_ACTIVATION_DAYS`
* :data:`~django.conf.settings.REGISTRATION_OPEN`
* :data:`~django.conf.settings.REGISTRATION_SALT` (see also :ref:`note
below `)
By default, this workflow uses
:class:`~django_registration.forms.RegistrationForm` as its form class
for user registration; this can be overridden by passing the keyword
argument `form_class` to the registration view.
Views
-----
.. currentmodule:: django_registration.backends.activation.views
Two views are provided to implement the signup/activation
process. These subclass :ref:`the base views of django-registration
`, so anything that can be overridden/customized there can
equally be overridden/customized here. There are some additional
customization points specific to this implementation, which are listed
below.
For an overview of the templates used by these views (other than those
specified below), and their context variables, see :ref:`the quick
start guide `.
.. class:: RegistrationView
A subclass of :class:`django_registration.views.RegistrationView`
implementing the signup portion of this workflow.
Important customization points unique to this class are:
.. method:: create_inactive_user(form)
Creates and returns an inactive user account, and calls
:meth:`send_activation_email()` to send the email with the
activation key. The argument `form` is a valid registration
form instance passed from
:meth:`~django_registration.views.RegistrationView.register()`.
:param django_registration.forms.RegistrationForm form: The registration form.
:rtype: django.contrib.auth.models.AbstractUser
.. method:: get_activation_key(user)
Given an instance of the user model, generates and returns an
activation key (a string) for that user account.
:param django.contrib.auth.models.AbstractUser user: The new user account.
:rtype: str
.. method:: get_email_context(activation_key)
Returns a dictionary of values to be used as template context
when generating the activation email.
:param str activation_key: The activation key for the new user account.
:rtype: dict
.. method:: send_activation_email(user)
Given an inactive user account, generates and sends the
activation email for that account.
:param django.contrib.auth.models.AbstractUser user: The new user account.
:rtype: None
.. attribute:: email_body_template
A string specifying the template to use for the body of the
activation email. Default is
`"django_registration/activation_email_body.txt"`.
.. attribute:: email_subject_template
A string specifying the template to use for the subject of the
activation email. Default is
`"django_registration/activation_email_subject.txt"`. Note that, to
avoid `header-injection vulnerabilities
`_, the result of
rendering this template will be forced into a single line of
text, stripping newline characters.
.. class:: ActivationView
A subclass of :class:`django_registration.views.ActivationView`
implementing the activation portion of this workflow.
Errors in activating the user account will raise
:exc:`~django_registration.exceptions.ActivationError`, with one
of the following values for the exception's `code`:
`"already_activated"`
Indicates the account has already been activated.
`"bad_username"`
Indicates the username decoded from the activation key is
invalid (does not correspond to any user account).
`"expired"`
Indicates the account/activation key has expired.
`"invalid_key"`
Generic indicator that the activation key was invalid.
Important customization points unique to this class are:
.. method:: get_user(username)
Given a username (determined by the activation key), looks up
and returns the corresponding instance of the user model. If no
such account exists, raises
:exc:`~django_registration.exceptions.ActivationError` as
described above. In the base implementation, checks the
:attr:`~django.contrib.auth.models.User.is_active` field to
avoid re-activating already-active accounts, and raises
:exc:`~django_registration.exceptions.ActivationError` with code
`already_activated` to indicate this case.
:param str username: The username of the new user account.
:rtype: django.contrib.auth.models.AbstractUser
:raises django_registration.exceptions.ActivationError: if no
matching inactive user account exists.
.. method:: validate_key(activation_key)
Given the activation key, verifies that it carries a valid
signature and a timestamp no older than the number of days
specified in the setting `ACCOUNT_ACTIVATION_DAYS`, and
returns the username from the activation key. Raises
:exc:`~django_registration.exceptions.ActivationError`, as
described above, if the activation key has an invalid signature
or if the timestamp is too old.
:param str activation_key: The activation key for the new user account.
:rtype: str
:raises django_registration.exceptions.ActivationError: if the
activation key has an invalid signature or is expired.
.. note:: **URL patterns for activation**
Although the actual value used in the activation key is the new
user account's username, the URL pattern for
:class:`~views.ActivationView` does not need to match all
possible legal characters in a username. The activation key that
will be sent to the user (and thus matched in the URL) is
produced by :func:`django.core.signing.dumps()`, which
base64-encodes its output. Thus, the only characters this
pattern needs to match are those from `the URL-safe base64
alphabet `_, plus
the colon ("`:`") which is used as a separator.
The default URL pattern for the activation view in
`django_registration.backends.activation.urls` handles this for
you.
How it works
------------
When a user signs up, the activation workflow creates a new user
instance to represent the account, and sets the `is_active` field to
:data:`False`. It then sends an email to the address provided during
signup, containing a link to activate the account. When the user
clicks the link, the activation view sets `is_active` to :data:`True`,
after which the user can log in.
The activation key is the username of the new account, signed using
`Django's cryptographic signing tools
`_
(specifically, :func:`~django.core.signing.dumps()` is used, to
produce a guaranteed-URL-safe value). The activation process includes
verification of the signature prior to activation, as well as
verifying that the user is activating within the permitted window (as
specified in the setting
:data:`~django.conf.settings.ACCOUNT_ACTIVATION_DAYS`, mentioned
above), through use of Django's
:class:`~django.core.signing.TimestampSigner`.
Security considerations
-----------------------
The activation key emailed to the user in the activation workflow
is a value obtained by using Django's cryptographic signing tools. The
activation key is of the form::
encoded_username:timestamp:signature
where `encoded_username` is the username of the new account,
`timestamp` is the timestamp of the time the user registered, and
`signature` is an HMAC of the username and timestamp. The username and
HMAC will be URL-safe base64 encoded; the timestamp will be base62
encoded.
Django's implementation uses the value of the
:data:`~django.conf.settings.SECRET_KEY` setting as the key for HMAC;
additionally, it permits the specification of a salt value which can
be used to "namespace" different uses of HMAC across a Django-powered
site.
.. _salt-security:
The activation workflow will use the value (a string) of the setting
:data:`~django.conf.settings.REGISTRATION_SALT` as the salt,
defaulting to the string `"registration"` if that setting is not
specified. This value does *not* need to be kept secret (only
:data:`~django.conf.settings.SECRET_KEY` does); it serves only to
ensure that other parts of a site which also produce signed values
from user input could not be used as a way to generate activation keys
for arbitrary usernames (and vice-versa).
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1653721512.0
django-registration-3.3/docs/conf.py 0000644 0000767 0000024 00000002413 00000000000 016545 0 ustar 00james staff import os
import sys
on_rtd = os.environ.get("READTHEDOCS", None) == "True"
extensions = ["sphinx.ext.intersphinx"]
templates_path = ["_templates"]
source_suffix = ".rst"
master_doc = "index"
project = "django-registration"
copyright = "2007-2022, James Bennett"
version = "3.3"
release = "3.3"
exclude_trees = ["_build"]
pygments_style = "sphinx"
htmlhelp_basename = "django-registrationdoc"
latex_documents = [
(
"index",
"django-registration.tex",
"django-registration Documentation",
"James Bennett",
"manual",
)
]
intersphinx_mapping = {
"django": (
"https://docs.djangoproject.com/en/stable/",
"https://docs.djangoproject.com/en/stable/_objects/",
),
"python": ("https://docs.python.org/3", None),
}
if not on_rtd:
import sphinx_rtd_theme
html_theme = "sphinx_rtd_theme"
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
# Spelling check needs an additional module that is not installed by default.
# Add it only if spelling check is requested so docs can be generated without it.
if "spelling" in sys.argv:
extensions.append("sphinxcontrib.spelling")
# Spelling language.
spelling_lang = "en_US"
# Location of word list.
spelling_word_list_filename = "spelling_wordlist.txt"
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1580073510.0
django-registration-3.3/docs/custom-user.rst 0000644 0000767 0000024 00000023067 00000000000 020276 0 ustar 00james staff .. _custom-user:
Custom user models
==================
Django's built-in auth system provides a default model for user
accounts, but also supports replacing that default with `a custom user
model
`_. Many
projects choose to use a custom user model from the start of their
development, even if it begins as a copy of the default model, in
order to avoid the difficulty of migrating to a custom user model
later on.
In general, django-registration will work with a custom user model,
though at least some additional configuration is always required in
order to do so. If you are using a custom user model, please read this
document thoroughly *before* using django-registration, in order to
ensure you've taken all the necessary steps to ensure support.
The process for using a custom user model with django-registration can
be summarized as follows:
1. Compare your custom user model to the assumptions made by the
built-in registration workflows.
2. If your user model is compatible with those assumptions, write a
short subclass of
:class:`~django_registration.forms.RegistrationForm` pointed at
your user model, and instruct django-registration to use that form.
3. If your user model is *not* compatible with those assumptions,
either write subclasses of the appropriate views in
django-registration which will be compatible with your user model,
or modify your user model to be compatible with the built-in views.
These steps are covered in more detail below.
Compatibility of the built-in workflows with custom user models
---------------------------------------------------------------
Django provides a number of helpers to make it easier for code to
generically work with custom user models, and django-registration
makes use of these. However, the built-in registration workflows must
still make *some* assumptions about the structure of your user model
in order to work with it. If you intend to use one of
django-registration's built-in registration workflows, please
carefully read the appropriate section to see what it expects from
your user model.
The two-step activation workflow
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
:ref:`The two-step activation workflow ` requires
that the following be true of your user model:
* Your user model must set the attribute
:attr:`~django.contrib.auth.models.CustomUser.USERNAME_FIELD` to
indicate the field used as the username.
* Your user model must have a field (of some textual type, ideally
:class:`~django.db.models.EmailField`) for storing an email address,
and it must define the method
:meth:`~django.contrib.auth.models.AbstractBaseUser.get_email_field_name`
to indicate the name of the email field.
* The username and email fields must be distinct. If you wish to use
the email address as the username, you will need to write your own
completely custom registration form.
* Your user model must have a field named
:attr:`~django.contrib.auth.models.User.is_active`, and that field
must be a :class:`~django.db.models.BooleanField` indicating whether
the user's account is active.
If your user model is a subclass of Django's
:class:`~django.contrib.auth.models.AbstractBaseUser`, all of the
above will be automatically handled for you.
If your custom user model defines additional fields beyond the minimum
requirements, you'll either need to ensure that all of those fields
are optional (i.e., can be `NULL` in your database, or provide a
suitable default value defined in the model), or specify the correct
list of fields to display in your
:class:`~django_registration.forms.RegistrationForm` subclass.
The one-step workflow
~~~~~~~~~~~~~~~~~~~~~
:ref:`The one-step workflow ` places the following
requirements on your user model:
* Your user model must set the attribute
:attr:`~django.contrib.auth.models.CustomUser.USERNAME_FIELD` to
indicate the field used as the username.
* It must define a textual field named `password` for storing the
user's password.
Also note that the base
:class:`~django_registration.forms.RegistrationForm` includes and
requires an email field, so either provide that field on your model
and set the
:meth:`~django.contrib.auth.models.AbstractBaseUser.get_email_field_name`
attribute to indicate which field it is, or subclass
:class:`~django_registration.forms.RegistrationForm` and override to
remove the `email` field or make it optional.
If your user model is a subclass of Django's
:class:`~django.contrib.auth.models.AbstractBaseUser`, all of the
above will be automatically handled for you.
If your custom user model defines additional fields beyond the minimum
requirements, you'll either need to ensure that all of those fields
are optional (i.e., can be `NULL` in your database, or provide a
suitable default value defined in the model), or specify the correct
list of fields to display in your
:class:`~django_registration.forms.RegistrationForm` subclass.
Because the one-step workflow logs in the new account immediately
after creating it, you also must either use Django's
:class:`~django.contrib.auth.backends.ModelBackend` as an
`authentication backend
`_,
or use an authentication backend which accepts a combination of
`USERNAME_FIELD` and `password` as sufficient credentials to
authenticate a user.
Writing your form subclass
--------------------------
The base :class:`~django_registration.views.RegistrationView` contains
code which compares the declared model of your registration form with
the user model of your Django installation. If these are not the same
model, the view will deliberately crash by raising an
:exc:`~django.core.exceptions.ImproperlyConfigured` exception, with an
error message alerting you to the problem.
This will happen automatically if you attempt to use
django-registration with a custom user model and also attempt to use
the default, unmodified
:class:`~django-registration.forms.RegistrationForm`. This is, again,
a deliberate design feature of django-registration, and not a bug:
django-registration has no way of knowing in advance if your user
model is compatible with the assumptions made by the built-in
registration workflows (see above), so it requires you to take the
explicit step of replacing the default registration form as a way of
confirming you've manually checked the compatibility of your user
model.
In the case where your user model is compatible with the default
behavior of django-registration, you will be able to subclass
:class:`~django_registration.forms.RegistrationForm`, set it to use
your custom user model as the model, and then configure the views in
django-registration to use your form subclass. For example, you might
do the following (in a `forms.py` module somewhere in your codebase --
do **not** directly edit django-registration's code):
.. code-block:: python
from django_registration.forms import RegistrationForm
from mycustomuserapp.models import MyCustomUser
class MyCustomUserForm(RegistrationForm):
class Meta(RegistrationForm.Meta):
model = MyCustomUser
You may also need to specify the fields to include in the form, if the
set of fields to include is different from the default set specified
by the base :class:`~django_registration.forms.RegistrationForm`.
Then in your URL configuration (example here uses the two-step
activation workflow), configure the registration view to use the form
class you wrote:
.. code-block:: python
from django.urls import include, path
from django_registration.backends.activation.views import RegistrationView
from mycustomuserapp.forms import MyCustomUserForm
urlpatterns = [
# ... other URL patterns here
path('accounts/register/',
RegistrationView.as_view(
form_class=MyCustomUserForm
),
name='django_registration_register',
),
path('accounts/',
include('django_registration.backends.activation.urls')
),
# ... more URL patterns
]
Incompatible user models
------------------------
If your custom user model is not compatible with the built-in
workflows of django-registration, you have several options.
One is to subclass the built-in form and view classes of
django-registration and make the necessary adjustments to achieve
compatibility with your user model. For example, if you want to use
the two-step activation workflow, but your user model uses a
completely different way of marking accounts active/inactive (compared
to the the assumed `is_active` field), you might write subclasses of
that workflow's
:class:`~django_registration.backends.activation.views.RegistrationView`
and
:class:`~django_registration.backends.activation.views.ActivationView`
which make use of your user model's mechanism for marking accounts
active/inactive, and then use those views along with an appropriate
subclass of :class:`~django_registration.forms.RegistrationForm`.
Or, if the incompatibilities are relatively minor and you don't mind
making the change, you might use Django's migration framework to
adjust your custom user model to match the assumptions made by
django-registration's built-in workflows, thus allowing them to be
used unmodified.
Finally, it may sometimes be the case that a given user model requires
a completely custom set of form and view classes to
support. Typically, this will also involve an account-registration
process far enough from what django-registration's built-in workflows
provide that you would be writing your own workflow in any case. ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/docs/deprecations.rst 0000644 0000767 0000024 00000000441 00000000000 020457 0 ustar 00james staff .. _deprecations:
Feature and API deprecation cycle
=================================
This document will list any features or APIs of django-registration
which are deprecated and scheduled to be removed in future releases.
As of |release|, no features or APIs are currently deprecated. ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/docs/exceptions.rst 0000644 0000767 0000024 00000002105 00000000000 020157 0 ustar 00james staff .. _exceptions:
.. module:: django_registration.exceptions
Exception classes
=================
django-registration provides two base exception classes to signal
errors which occur during the signup or activation processes.
.. exception:: RegistrationError(message, code, params)
Base exception class for all exceptions raised in
django-registration. No code in django-registration will raise this
exception directly; it serves solely to provide a distinguishing
parent class for other errors. Arguments passed when the exception
is raised will be stored and exposed as attributes of the same
names on the exception object:
:param str message: A human-readable error message.
:param str code: A short but unique identifier used by subclasses
to distinguish different error conditions.
:param dict params: Arbitrary key-value data to associate with the error.
.. exception:: ActivationError(message, code, params)
Exception class to indicate errors during account
activation. Subclass of :exc:`RegistrationError` and inherits its
attributes. ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1653721574.0
django-registration-3.3/docs/faq.rst 0000644 0000767 0000024 00000024502 00000000000 016552 0 ustar 00james staff .. _faq:
Frequently-asked questions
==========================
The following are miscellaneous common questions and answers related
to installing/using django-registration, culled from bug reports,
emails and other sources.
General
-------
This doesn't work with custom user models! It crashes as soon as I try to use one!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
django-registration can work perfectly well with a custom user model,
but this does require you to do a bit more work. Please thoroughly
read :ref:`the documentation for how to use custom user models
` before filing a bug.
Please also note that, as explained in that documentation, by default
django-registration will crash if you try to use a custom user model
without following the documentation. This is not a bug; it is done
deliberately to ensure you read and follow the documentation.
How can I support social-media and other auth schemes, like Facebook or GitHub?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
By using `django-allauth
`_. No single application
can or should provide a universal API for every authentication system
ever developed; django-registration sticks to making it easy to
implement typical signup workflows using Django's default model-based
authentication system, while apps like `django-allauth` handle
integration with third-party authentication services far more
effectively.
What license is django-registration under?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
django-registration is offered under a three-clause BSD-style license;
this is `an OSI-approved open-source license
`_, and allows you
a large degree of freedom in modifying and redistributing the
code. For the full terms, see the file `LICENSE` which came with
your copy of django-registration; if you did not receive a copy of
this file, you can view it online at
.
What versions of Django and Python are supported?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
As of django-registration |release|, Django 3.2 and 4.0 are
supported, on Python 3.7 (Django 3.2 only), 3.8, 3.9, and 3.10. Note
that Django 3.2's support for Python 3.10 was added in Django 3.2.9,
so you may experience issues with Python 3.10 and earlier Django 3.2
versions.
I found a bug or want to make an improvement!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. important:: **Reporting security issues**
If you believe you have found a security issue in
django-registration, please do *not* use the public GitHub issue
tracker to report it. Instead, you can `contact the author
privately `_ to report the issue.
The canonical development repository for django-registration is online
at . Issues and
pull requests can both be filed there.
If you'd like to contribute to django-registration, that's great! Just
please remember that pull requests should include tests and
documentation for any changes made, and that following `PEP 8
`_ is mandatory. Pull
requests without documentation won't be merged, and PEP 8 style
violations or test coverage below 100% are both configured to break
the build.
How secure is django-registration?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Over the course of django-registration's history so far, there has
been one security issue reported which required a new release to
remedy. This doesn't mean, though, that django-registration is
perfectly secure: much will depend on ensuring best practices in
deployment and server configuration, and there could always be
security issues that just haven't been recognized yet.
django-registration does, however, try to avoid common security
issues:
* django-registration |release| only supports versions of Django which
were receiving upstream security support at the time of release.
* django-registration does not attempt to generate or store passwords,
and does not transmit credentials which could be used to log in (the
only "credential" ever sent out by django-registration is an
activation key used in the two-step activation workflow, and that
key can only be used to make an account active; it cannot be used to
log in).
* django-registration works with Django's own security features
(including cryptographic features) where possible, rather than
reinventing its own.
For more details, see :ref:`the security guide `.
How do I run the tests?
~~~~~~~~~~~~~~~~~~~~~~~
django-registration's tests are run using `tox
`_, but typical installation of
django-registration (via `pip install django-registration`) will not
install the tests.
To run the tests, download the source (`.tar.gz`) distribution of
django-registration |release| from `its page on the Python Package
Index `_, unpack it
(`tar zxvf django-registration-|release|.tar.gz` on most Unix-like
operating systems), and in the unpacked directory run `tox`.
Note that you will need to have `tox` installed already (`pip
install tox`), and to run the full test matrix you will need to have
each supported version of Python available. To run only the tests for
a specific Python version and Django version, you can invoke `tox`
with the `-e` flag. For example, to run tests for Python 3.6 and
Django 2.0: `tox -e py36-django20`.
Installation and setup
----------------------
How do I install django-registration?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Full instructions are available in :ref:`the installation guide
`. For configuration, see :ref:`the quick start guide
`.
Does django-registration come with any sample templates I can use right away?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
No, for two reasons:
1. Providing default templates with an application is ranges from hard
to impossible, because different sites can have such wildly
different design and template structure. Any attempt to provide
templates which would work with all the possibilities would
probably end up working with none of them.
2. A number of things in django-registration depend on the specific
registration workflow you use, including the variables which end up
in template contexts. Since django-registration has no way of
knowing in advance what workflow you're going to be using, it also
has no way of knowing what your templates will need to look like.
Fortunately, however, django-registration has good documentation which
explains what context variables will be available to templates, and so
it should be easy for anyone who knows Django's template system to
create templates which integrate with their own site.
Configuration
-------------
Do I need to rewrite the views to change the way they behave?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Not always. Any behavior controlled by an attribute on a class-based
view can be changed by passing a different value for that attribute in
the URLconf. See `Django's class-based view documentation
`_
for examples of this.
For more complex or fine-grained control, you will likely want to
subclass :class:`~django_registration.views.RegistrationView` or
:class:`~django_registration.views.ActivationView`, or both, add your
custom logic to your subclasses, and then create a URLconf which makes
use of your subclasses.
I don't want to write my own URLconf because I don't want to write patterns for all the auth views!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
You're in luck, then; Django provides a URLconf for this, at
`django.contrib.auth.urls`.
I don't like the names you've given to the URL patterns!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In that case, you should feel free to set up your own URLconf which
uses the names you want.
I'm using a custom user model; how do I make that work?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
See :ref:`the custom user documentation `.
Tips and tricks
---------------
How do I close user signups?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you haven't modified the behavior of the
:meth:`~django_registration.views.RegistrationView.registration_allowed`
method in :class:`~django_registration.views.RegistrationView`, you can
use the setting :data:`~django.conf.settings.REGISTRATION_OPEN` to
control this; when the setting is `True`, or isn't supplied,
user registration will be permitted. When the setting is
`False`, user registration will not be permitted.
How do I log a user in immediately after registration or activation?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Take a look at the implementation of :ref:`the one-step workflow
`, which logs a user in immediately after
registration.
How do I manually activate a user?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In :ref:`the two-step activation workflow `,
toggle the `is_active` field of the user in the admin.
How do I delete expired unactivated accounts?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Perform a query for those accounts, and call the `delete()` method
of the resulting `QuerySet`. Since django-registration doesn't know
in advance what your definition of "expired" will be, it leaves this
step to you.
How do I allow Unicode in usernames?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Use Python 3. Django's username validation allows any word character
plus some additional characters, but the definition of "word
character" depends on the Python version in use. On Python 2, only
ASCII will be permitted; on Python 3, usernames containing word
characters matched by a regex with the :data:`re.UNICODE` flag will be
accepted.
How do I tell why an account's activation failed?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you're using :ref:`the two-step activation workflow
`, the template context will contain a variable
`activation_error` containing the information passed when the
:exc:`~django_registration.exceptions.ActivationError` was
raised. This will indicate what caused the failure. ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1580076236.0
django-registration-3.3/docs/forms.rst 0000644 0000767 0000024 00000010644 00000000000 017133 0 ustar 00james staff .. _forms:
.. module:: django_registration.forms
Base form classes
=================
Several form classes are provided with django-registration,
covering common cases for gathering account information and
implementing common constraints for user registration. These forms
were designed with django-registration's built-in registration
workflows in mind, but may also be useful in other situations.
.. class:: RegistrationForm
A form for registering an account. This is a subclass of Django's
built-in :class:`~django.contrib.auth.forms.UserCreationForm`, and
has the following fields, all of which are required:
`username`
The username to use for the new account.
`email`
The email address to use for the new account.
`password1`
The password to use for the new account.
`password2`
The password to use for the new account, repeated to catch
typos.
.. note:: **Validation of usernames**
Django supplies a default regex-based validator for usernames in
its base :class:`~django.contrib.auth.models.AbstractBaseUser`
implementation, allowing any word character along with the
following set of additional characters: `.`, `@`, `+`, and
`-`.
Because it's a subclass of Django's
:class:`~django.contrib.auth.forms.UserCreationForm`,
:class:`RegistrationForm` will inherit the base validation
defined by Django. It also applies some custom validators to the
username:
:class:`~django_registration.validators.ReservedNameValidator`,
and
:func:`~django_registration.validators.validate_confusables`.
.. note:: **Validation of email addresses**
django-registration applies two additional validators --
:class:`~django_registration.validators.HTML5EmailValidator` and
:func:`~django_registration.validators.validate_confusables_email`
-- to the email address.
The HTML5 validator uses `the HTML5 email-validation rule
`_
(as implemented on HTML's `input type="email"`), which is more
restrictive than the email RFCs. The purpose of this validator
is twofold: to match the behavior of HTML5, and to simplify
django-registration's other validators. The full RFC grammar for
email addresses is enormously complex despite most of its
features rarely if ever being used legitimately, so disallowing
those features allows other validators to interact with a much
simpler format, ensuring performance, reliability and safety.
.. note:: **Custom user models**
If you are using `a custom user model
`_,
you **must** subclass this form and tell it to use your custom
user model instead of Django's default user model. If you do
not, django-registration will deliberately crash with an error
message reminding you to do this. See :ref:`the custom user
compatibility guide ` for details.
.. class:: RegistrationFormCaseInsensitive
A subclass of :class:`RegistrationForm` which enforces
case-insensitive uniqueness of usernames, by applying
:class:`~django_registration.validators.CaseInsensitiveUnique`
to the username field.
.. note:: **Unicode case handling**
This form will normalize the username value to form NFKC,
matching Django's default approach to Unicode normalization. it
will then case fold the value, and use a case-insensitive
(`iexact`) lookup to determine if a user with the same username
already exists; the results of this query may depend on the
quality of your database's Unicode implementation, and on
configuration details. The results may also be surprising to
developers who are primarily used to English/ASCII text, as
Unicode's case rules can be quite complex.
.. class:: RegistrationFormTermsOfService
A subclass of :class:`RegistrationForm` which adds one additional,
required field:
`tos`
A checkbox indicating agreement to the site's terms of
service/user agreement.
.. class:: RegistrationFormUniqueEmail
A subclass of :class:`RegistrationForm` which enforces uniqueness
of email addresses in addition to uniqueness of usernames, by
applying
:class:`~django_registration.validators.CaseInsensitiveUnique` to
the email field.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1600763542.0
django-registration-3.3/docs/index.rst 0000644 0000767 0000024 00000003243 00000000000 017111 0 ustar 00james staff .. _index:
django-registration |release|
=============================
django-registration is an extensible application providing user
registration functionality for `Django
`_-powered Web sites.
Although nearly all aspects of the registration process are
customizable, out-of-the-box support is provided for two common use
cases:
* Two-phase registration, consisting of initial signup followed by a
confirmation email with instructions for activating the new account.
* One-phase registration, where a user signs up and is immediately
active and logged in.
To get up and running quickly, :ref:`install django-registration
`, then read :ref:`the quick start guide `, which
describes the steps necessary to configure django-registration for the
built-in workflows. For more detailed information, including how to
customize the registration process (and support for alternate
registration systems), read through the documentation listed below.
.. toctree::
:caption: Installation and configuration
:maxdepth: 1
install
quickstart
.. toctree::
:caption: Built-in registration workflows
:maxdepth: 1
activation-workflow
one-step-workflow
.. toctree::
:caption: For developers
:maxdepth: 1
views
forms
custom-user
validators
exceptions
settings
signals
deprecations
.. toctree::
:caption: Other documentation
:maxdepth: 1
security
upgrade
faq
.. seealso::
* `Django's authentication documentation
`_. Django's
authentication system is used by django-registration's default
configuration.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1653721545.0
django-registration-3.3/docs/install.rst 0000644 0000767 0000024 00000003451 00000000000 017451 0 ustar 00james staff .. _install:
Installation guide
==================
The |release| release of django-registration supports Django 3.2 and
4.0 on Python 3.7 (Django 3.2 only), 3.8, 3.9, and 3.10. Note that
Django 3.2's support for Python 3.10 was added in Django 3.2.9, so you
may experience issues with Python 3.10 and earlier Django 3.2
versions.
Normal installation
-------------------
The preferred method of installing django-registration is via `pip`,
the standard Python package-installation tool. If you don't have
`pip`, instructions are available for `how to obtain and install it
`_, though if you're
using a supported version of Python, `pip` should have come bundled
with your installation of Python.
Once you have `pip`, type::
pip install django-registration
If you don't have a copy of a compatible version of Django, this will
also automatically install one for you, and will install a third-party
library required by some of django-registration's validation code.
Installing from a source checkout
---------------------------------
If you want to work on django-registration, you can obtain a source
checkout.
The development repository for django-registration is at
. If you have `git
`_ installed, you can obtain a copy of the
repository by typing::
git clone https://github.com/ubernostrum/django-registration.git
From there, you can use git commands to check out the specific
revision you want, and perform an "editable" install (allowing you to
change code as you work on it) by typing::
pip install -e .
Next steps
----------
To get up and running quickly, check out :ref:`the quick start guide
`. For full documentation, see :ref:`the documentation
index `. ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1516537948.0
django-registration-3.3/docs/make.bat 0000644 0000767 0000024 00000005651 00000000000 016662 0 ustar 00james staff @ECHO OFF
REM Command file for Sphinx documentation
set SPHINXBUILD=sphinx-build
set ALLSPHINXOPTS=-d _build/doctrees %SPHINXOPTS% .
if NOT "%PAPER%" == "" (
set ALLSPHINXOPTS=-D latex_paper_size=%PAPER% %ALLSPHINXOPTS%
)
if "%1" == "" goto help
if "%1" == "help" (
:help
echo.Please use `make ^` where ^ is one of
echo. html to make standalone HTML files
echo. dirhtml to make HTML files named index.html in directories
echo. pickle to make pickle files
echo. json to make JSON files
echo. htmlhelp to make HTML files and a HTML help project
echo. qthelp to make HTML files and a qthelp project
echo. latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter
echo. changes to make an overview over all changed/added/deprecated items
echo. linkcheck to check all external links for integrity
echo. doctest to run all doctests embedded in the documentation if enabled
goto end
)
if "%1" == "clean" (
for /d %%i in (_build\*) do rmdir /q /s %%i
del /q /s _build\*
goto end
)
if "%1" == "html" (
%SPHINXBUILD% -b html %ALLSPHINXOPTS% _build/html
echo.
echo.Build finished. The HTML pages are in _build/html.
goto end
)
if "%1" == "dirhtml" (
%SPHINXBUILD% -b dirhtml %ALLSPHINXOPTS% _build/dirhtml
echo.
echo.Build finished. The HTML pages are in _build/dirhtml.
goto end
)
if "%1" == "pickle" (
%SPHINXBUILD% -b pickle %ALLSPHINXOPTS% _build/pickle
echo.
echo.Build finished; now you can process the pickle files.
goto end
)
if "%1" == "json" (
%SPHINXBUILD% -b json %ALLSPHINXOPTS% _build/json
echo.
echo.Build finished; now you can process the JSON files.
goto end
)
if "%1" == "htmlhelp" (
%SPHINXBUILD% -b htmlhelp %ALLSPHINXOPTS% _build/htmlhelp
echo.
echo.Build finished; now you can run HTML Help Workshop with the ^
.hhp project file in _build/htmlhelp.
goto end
)
if "%1" == "qthelp" (
%SPHINXBUILD% -b qthelp %ALLSPHINXOPTS% _build/qthelp
echo.
echo.Build finished; now you can run "qcollectiongenerator" with the ^
.qhcp project file in _build/qthelp, like this:
echo.^> qcollectiongenerator _build\qthelp\django-registration.qhcp
echo.To view the help file:
echo.^> assistant -collectionFile _build\qthelp\django-registration.ghc
goto end
)
if "%1" == "latex" (
%SPHINXBUILD% -b latex %ALLSPHINXOPTS% _build/latex
echo.
echo.Build finished; the LaTeX files are in _build/latex.
goto end
)
if "%1" == "changes" (
%SPHINXBUILD% -b changes %ALLSPHINXOPTS% _build/changes
echo.
echo.The overview file is in _build/changes.
goto end
)
if "%1" == "linkcheck" (
%SPHINXBUILD% -b linkcheck %ALLSPHINXOPTS% _build/linkcheck
echo.
echo.Link check complete; look for any errors in the above output ^
or in _build/linkcheck/output.txt.
goto end
)
if "%1" == "doctest" (
%SPHINXBUILD% -b doctest %ALLSPHINXOPTS% _build/doctest
echo.
echo.Testing of doctests in the sources finished, look at the ^
results in _build/doctest/output.txt.
goto end
)
:end
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1600671777.0
django-registration-3.3/docs/one-step-workflow.rst 0000644 0000767 0000024 00000005653 00000000000 021413 0 ustar 00james staff .. _one-step-workflow:
.. module:: django_registration.backends.one_step
The one-step workflow
=====================
As an alternative to :ref:`the two-step (registration and activation)
workflow `, django-registration bundles a
one-step registration workflow in
`django_registration.backends.one_step`. This workflow consists of
as few steps as possible:
1. A user signs up by filling out a registration form.
2. The user's account is created and is active immediately, with no
intermediate confirmation or activation step.
3. The new user is logged in immediately.
Configuration
-------------
To use this workflow, include the URLconf
`django_registration.backends.one_step.urls` somewhere in your site's
own URL configuration. For example:
.. code-block:: python
from django.urls import include, path
urlpatterns = [
# Other URL patterns ...
path('accounts/', include('django_registration.backends.one_step.urls')),
path('accounts/', include('django.contrib.auth.urls')),
# More URL patterns ...
]
To control whether registration of new accounts is allowed, you can
specify the setting :data:`~django.conf.settings.REGISTRATION_OPEN`.
Upon successful registration, the user will be redirected to the
site's home page -- the URL `/`. This can be changed by subclassing
:class:`django_registration.backends.one_step.views.RegistrationView`
and overriding the method
:meth:`~django_registration.views.RegistrationView.get_success_url`
or setting the attribute
:attr:`~django_registration.views.RegistrationView.success_url`. You
can also do this in a URLconf. For example:
.. code-block:: python
from django.conf.urls import include, url
from django_registration.backends.one_step.views import RegistrationView
urlpatterns = [
# Other URL patterns ...
path('accounts/register/',
RegistrationView.as_view(success_url='/profile/'),
name='django_registration_register'),
path('accounts/', include('django_registration.backends.one_step.urls')),
path('accounts/', include('django.contrib.auth.urls')),
# More URL patterns ...
]
The default form class used for account registration will be
:class:`django_registration.forms.RegistrationForm`, although this can
be overridden by supplying a custom URL pattern for the registration
view and passing the keyword argument `form_class`, or by subclassing
:class:`django_registration.backends.one_step.views.RegistrationView`
and either overriding
:attr:`~django_registration.views.RegistrationView.form_class` or
implementing
:meth:`~django_registration.views.RegistrationView.get_form_class()`,
and specifying the custom subclass in your URL patterns.
Templates
---------
The one-step workflow uses two templates:
* `django_registration/registration_form.html`.
* `django_registration/registration_closed.html`
See :ref:`the quick start guide ` for details
of these templates.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1624231636.0
django-registration-3.3/docs/quickstart.rst 0000644 0000767 0000024 00000027653 00000000000 020207 0 ustar 00james staff .. _quickstart:
Quick start guide
=================
First you'll need to have Django and django-registration
installed; for details on that, see :ref:`the installation guide
`.
The next steps will depend on which registration workflow you'd like
to use. There are two workflows built into django-registration:
* :ref:`The two-step activation workflow `, which
implements a two-step process: a user signs up, then is emailed an
activation link and must click it to activate the account.
* :ref:`The one-step workflow `, in which a user
signs up and their account is immediately active and logged in.
If you want a signup process other than what's provided by these
built-in workflows, please see the documentation for the base
:ref:`view ` and :ref:`form ` classes, which you can
subclass to implement your own preferred user registration flow and
rules. The guide below covers use of the built-in workflows.
Regardless of which registration workflow you choose to use, you
should add `"django_registration"` to your
:data:`~django.conf.settings.INSTALLED_APPS` setting.
.. important:: **Django's authentication system must be installed**
Before proceeding with either of the recommended built-in
workflows, you'll need to ensure `django.contrib.auth` has been
installed (by adding it to
:data:`~django.conf.settings.INSTALLED_APPS` and running `manage.py
migrate` to install needed database tables). Also, if you're making
use of `a custom user model
`_,
you'll probably want to pause and read :ref:`the custom user
compatibility guide ` before using
django-registration.
.. note:: **Additional steps for account security**
While django-registration does what it can to secure the user
signup process, its scope is deliberately limited; please read
:ref:`the security documentation ` for recommendations on
steps to secure user accounts beyond what django-registration alone
can do.
Configuring the two-step activation workflow
--------------------------------------------
The configuration process for using the two-step activation workflow
is straightforward: you'll need to specify a couple of settings,
connect some URLs and create a few templates.
Required settings
~~~~~~~~~~~~~~~~~
Begin by adding the following setting to your Django settings file:
:data:`~django.conf.settings.ACCOUNT_ACTIVATION_DAYS`
This is the number of days users will have to activate their
accounts after registering. If a user does not activate within
that period, the account will remain permanently inactive unless a
site administrator manually activates it.
For example, you might have something like the following in your
Django settings::
ACCOUNT_ACTIVATION_DAYS = 7 # One-week activation window
Setting up URLs
~~~~~~~~~~~~~~~
Each bundled registration workflow in django-registration includes a
Django URLconf which sets up URL patterns for :ref:`the views in
django-registration `. The URLconf for the two-step activation
workflow can be found at
`django_registration.backends.activation.urls`. For example, to place
the registration URLs under the prefix `/accounts/`, you could add the
following to your project's root URLconf:
.. code-block:: python
from django.urls import include, path
urlpatterns = [
# Other URL patterns ...
path('accounts/', include('django_registration.backends.activation.urls')),
path('accounts/', include('django.contrib.auth.urls')),
# More URL patterns ...
]
Users would then be able to register by visiting the URL
`/accounts/register/`, log in (once activated) at
`/accounts/login/`, etc.
The sample URL configuration above also sets up the built-in auth
views included in Django (login, logout, password reset, etc.) via the
`django.contrib.auth.urls` URLconf.
The following URL names are defined by
`django_registration.backends.activation.urls`:
* `django_registration_register` is the account-registration view.
* `django_registration_complete` is the post-registration success
message.
* `django_registration_activate` is the account-activation view.
* `django_registration_activation_complete` is the post-activation
success message.
* `django_registration_disallowed` is a message indicating registration is
not currently permitted.
.. _default-templates:
Required templates
~~~~~~~~~~~~~~~~~~
You will also need to create several templates required by
django-registration, and possibly additional templates required by
views in `django.contrib.auth`. The templates required by
django-registration are as follows; note that, with the exception of
the templates used for account activation emails, all of these are
rendered using a :class:`~django.template.RequestContext` and so will
also receive any additional variables provided by `context processors
`_.
.. _default-form-template:
`django_registration/registration_form.html`
````````````````````````````````````````````
Used to show the form users will fill out to register. By default, has
the following context:
`form`
The registration form. This will likely be a subclass of
:class:`~django_registration.forms.RegistrationForm`; consult
`Django's forms documentation
`_ for
information on how to display this in a template.
`django_registration/registration_complete.html`
````````````````````````````````````````````````
Used after successful completion of the registration form. This
template has no context variables of its own, and should inform the
user that an email containing account-activation information has been
sent.
`django_registration/registration_closed.html`
``````````````````````````````````````````````````
Used when registration of new user accounts is disabled. This template
has no context variables of its own.
`django_registration/activation_failed.html`
````````````````````````````````````````````
Used if account activation fails. Has the following context:
`activation_error`
A :class:`dict` containing the information supplied to the
:exc:`~django_registration.exceptions.ActivationError` which
occurred during activation. See the documentation for that
exception for a description of the keys, and the documentation for
:class:`~django_registration.backends.activation.views.ActivationView`
for the specific values used in different failure situations.
`django_registration/activation_complete.html`
``````````````````````````````````````````````
Used after successful account activation. This template has no context
variables of its own, and should inform the user that their account is
now active.
`django_registration/activation_email_subject.txt`
``````````````````````````````````````````````````
Used to generate the subject line of the activation email. Because the
subject line of an email must be a single line of text, any output
from this template will be forcibly condensed to a single line before
being used. This template has the following context:
`activation_key`
The activation key for the new account, as a string.
`expiration_days`
The number of days remaining during which the account may be
activated, as an integer.
`request`
The :class:`~django.http.HttpRequest` object representing the
request in which the user registered.
`scheme`
The protocol scheme used during registration, as a string; will be
either `'http'` or `'https'`.
`site`
An object representing the site on which the user registered;
depending on whether `django.contrib.sites` is installed, this may
be an instance of either :class:`django.contrib.sites.models.Site`
(if the sites application is installed) or
:class:`django.contrib.sites.requests.RequestSite` (if
not). Consult `the documentation for the Django sites framework
`_
for details regarding these objects' interfaces.
`user`
The newly-created user object.
`django_registration/activation_email_body.txt`
```````````````````````````````````````````````
Used to generate the body of the activation email. Should display a
link the user can click to activate the account. This template has the
following context:
`activation_key`
The activation key for the new account, as a string.
`expiration_days`
The number of days remaining during which the account may be
activated, as an integer.
`request`
The :class:`~django.http.HttpRequest` object representing the
request in which the user registered.
`scheme`
The protocol scheme used during registration, as a string; will be
either `'http'` or `'https'`.
`site`
An object representing the site on which the user registered;
depending on whether `django.contrib.sites` is installed, this may
be an instance of either :class:`django.contrib.sites.models.Site`
(if the sites application is installed) or
:class:`django.contrib.sites.requests.RequestSite` (if
not). Consult `the documentation for the Django sites framework
`_
for details regarding these objects.
`user`
The newly-created user object.
Note that the templates used to generate the account activation email
use the extension `.txt`, not `.html`. Due to widespread antipathy
toward and interoperability problems with HTML email,
django-registration produces plain-text email, and so these templates
should output plain text rather than HTML.
To make use of the views from `django.contrib.auth` (which are set up
for you by the example URL configuration above), you will also need to
create the templates required by those views. Consult `the
documentation for Django's authentication system
`_ for details
regarding these templates.
Configuring the one-step workflow
--------------------------------------------
Also included is a :ref:`one-step registration workflow
`, where a user signs up and their account is
immediately active and logged in.
You will need to configure URLs to use the one-step workflow; the
easiest way is to :func:`~django.urls.include` the URLconf
`django_registration.backends.one_step.urls` somewhere in your URL
configuration. For example, to place the URLs under the prefix
`/accounts/` in your URL structure:
.. code-block:: python
from django.urls import include, path
urlpatterns = [
# Other URL patterns ...
path('accounts/', include('django_registration.backends.one_step.urls')),
path('accounts/', include('django.contrib.auth.urls')),
# More URL patterns ...
]
Users could then register accounts by visiting the URL
`/accounts/register/`.
The following URL names are defined by
`django_registration.backends.one_step.urls`:
* `django_registration_register` is the account-registration view.
* `django_registration_complete` is the post-registration success
message.
* `django_registration_disallowed` is a message indicating registration is
not currently permitted.
This URLconf will also configure the appropriate URLs for the rest of
the built-in `django.contrib.auth` views (log in, log out, password
reset, etc.).
Finally, you will need to create following templates:
* `django_registration/registration_form.html`
* `django_registration/registration_complete.html`
* `django_registration/registration_closed.html`
See :ref:`the documentation above ` for details
of these templates.
To make use of the views from `django.contrib.auth` (which are set up
for you by the example URL configuration above), you will also need to
create the templates required by those views. Consult `the
documentation for Django's authentication system
`_ for details
regarding these templates.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1580076461.0
django-registration-3.3/docs/security.rst 0000644 0000767 0000024 00000016067 00000000000 017661 0 ustar 00james staff .. _security:
Security guide
==============
.. important:: **Reporting security issues**
If you believe you have found a security issue in
django-registration, please do *not* use the public GitHub issue
tracker to report it. Instead, you can `contact the author
privately `_ to report the issue.
Anything related to users or user accounts has security implications
and represents a large source of potential security issues. This
document is not an exhaustive guide to those implications and issues,
and makes no guarantees that your particular use of Django or
django-registration will be safe; instead, it provides a set of
recommendations, and explanations for why django-registration does
certain things or recommends particular approaches. Using this
software responsibly is, ultimately, up to you.
Before continuing with this document, you should ensure that you've
read and understood `Django's security documentation
`_. Django
provides a good overview of common security issues in the general
field of web development, and an explanation of how it helps to
protect against them or provides tools to help you do so.
You should also ensure you're following Django's security
recommendations. You can check for many common issues by running::
python manage.py check --tag security
on your codebase.
Recommendation: use the two-step activation workflow
----------------------------------------------------
Two user-signup workflows are included in django-registration, along
with support for writing your own. If you choose to use one of the
included workflows, :ref:`the two-step activation workflow
` is the recommended default.
The activation workflow provides a verification step -- the user must
click a link sent to the email address they used to register -- which
can serve as an impediment to automated account creation for malicious
purposes.
The activation workflow generates an activation key which consists of
the new account's username and the timestamp of the signup, verified
using `Django's cryptographic signing tools
`_ which in
turn use `the HMAC implementation from the Python standard library
`_. Thus,
django-registration is not inventing or building any new cryptography,
but only using existing/vetted implementations in an approved and
standard manner.
Additionally, the activation workflow takes steps to ensure that its
use of HMAC does not act as an `oracle
`_. Several parts of
Django use the signing tools, and third-party applications are free to
use them as well, so django-registration makes use of the ability to
supply a salt value for the purpose of "namespacing" HMAC usage. Thus
an activation token generated by django-registration's activation
workflow should not be usable for attacks against other HMAC-carrying
values generated by the same installation of Django.
Restrictions on user names: reserved names
------------------------------------------
By default, django-registration applies a list of reserved names, and
does not permit users to create accounts using those names (see
:class:`~django_registration.validators.ReservedNameValidator`). The
default list of reserved names includes many names that could cause
confusion or even inappropriate access. These reserved names fall into
several categories:
* Usernames which could allow a user to impersonate or be seen as a
site administrator. For example, `'admin'` or `'administrator'`.
* Usernames corresponding to standard/protocol-specific email
addresses (relevant for sites where creating an account also creates
an email address with that username). For example, `'webmaster'`.
* Usernames corresponding to standard/sensitive subdomain names
(relevant for sites where creating an account also creates a
subdomain corresponding to the username). For example, `'ftp'` or
`'autodiscover'`.
* Usernames which correspond to sensitive URLs (relevant for sites
where user profiles appear at a URL containing the username). For
example, `'contact'` or `'buy'`.
It is strongly recommended that you leave the reserved-name validation
enabled.
Restrictions on user names and email addresses: Unicode
-------------------------------------------------------
By default, django-registration permits the use of a wide range of
Unicode in usernames and email addresses. However, to prevent some
types of Unicode-related attacks, django-registration will not permit
certain specific uses of Unicode characters.
For example, while the username `'admin'` cannot normally be
registered (see above), a user might still attempt to register a name
that appears visually identical, by substituting a Cyrillic 'a' or
other similar-appearing character for the first character. This is a
`homograph attack
`_.
To prevent homograph attacks, django-registration applies the
following rule to usernames, and to the local-part and the domain of
email addresses:
* If the submitted value is mixed-script (contains characters from
multiple different scripts, as in the above example which would mix
Cyrillic and Latin characters), and
* If the submitted value contains characters appearing in the Unicode
Visually Confusable Characters file,
* Then the value will be rejected.
See :func:`~django_registration.validators.validate_confusables` and
:func:`~django_registration.validators.validate_confusables_email`.
This should not interfere with legitimate use of Unicode, or of
non-English/non-Latin characters in usernames and email addresses. To
avoid a common false-positive situation, the local-part and domain of
an email address are checked independently of each other.
It is strongly recommended that you leave this validation enabled.
Additional steps to secure user accounts
----------------------------------------
The scope of django-registration is solely the implementation of
user-signup workflows, which limits the ways in which
django-registration alone can protect your users. Other features of
Django itself, or of other third-party applications, can provide
significant increases in protection.
In particular, it is recommended that you:
* Prevent the use of common passwords. You can catch some common
passwords by enabling Django's
:class:`~django.contrib.auth.password_validation.CommonPasswordValidator`,
which uses a list of twenty thousand common passwords. A more
comprehensive option is the password validator and other utilities
from `pwned-passwords-django
`_, which
checks against a database containing (as of mid-2018) over half a
billion passwords found in data breaches.
* Use two-factor authentication via authenticator applications or
hardware security keys (*not* SMS). The package `django-two-factor
`_
provides integration for two-factor authentication into Django's
auth framework.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535974254.0
django-registration-3.3/docs/settings.rst 0000644 0000767 0000024 00000003452 00000000000 017644 0 ustar 00james staff .. _settings:
.. module:: django.conf.settings
Custom settings
===============
Although the choice of registration workflow does not necessarily
require changes to your Django settings (as registration workflows are
selected by including the appropriate URL patterns in your root
URLconf), the built-in workflows of django-registration make use
of several custom settings.
.. data:: ACCOUNT_ACTIVATION_DAYS
An :class:`int` indicating how long (in days) after signup an
account has in which to activate.
Used by:
* :ref:`The two-step activation workflow `
.. data:: REGISTRATION_OPEN
A :class:`bool` indicating whether registration of new accounts is
currently permitted.
A default of `True` is assumed when this setting is not supplied,
so specifying it is optional unless you want to temporarily close
registration (in which case, set it to `False`).
Used by:
* :ref:`The two-step activation workflow `
* :ref:`The one-step workflow `
Third-party workflows wishing to use an alternate method of
determining whether registration is allowed should subclass
:class:`django_registration.views.RegistrationView` (or a subclass of it
from an existing workflow) and override
:meth:`~django_registration.views.RegistrationView.registration_allowed`.
.. data:: REGISTRATION_SALT
A :class:`str` used as an additional "salt" in the process of
generating signed activation keys.
This setting is optional, and a default of `"registration"` will
be used if not specified. The value of this setting does not need
to be kept secret; see :ref:`the note about this salt value and
security ` for details.
Used by:
* :ref:`The two-step activation workflow `
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535974282.0
django-registration-3.3/docs/signals.rst 0000644 0000767 0000024 00000005164 00000000000 017446 0 ustar 00james staff .. _signals:
.. module:: django_registration.signals
Signals used by django-registration
===================================
Much of django-registration's customizability comes through the
ability to write and use different workflows for user
registration. However, there are many cases where only a small bit of
additional logic needs to be injected into the registration process,
and writing a custom workflow to support this represents an
unnecessary amount of work. A more lightweight customization option is
provided through two custom signals which the built-in registration
workflows send, and custom workflows are encouraged to send, at
specific points during the registration process; functions listening
for these signals can then add whatever logic is needed.
For general documentation on signals and the Django dispatcher,
consult `Django's signals documentation
`_. This
documentation assumes that you are familiar with how signals work and
the process of writing and connecting functions which will listen for
signals.
.. data:: user_activated
Sent when a user account is activated (not applicable to all
workflows). Provides the following arguments:
`sender`
The :class:`~django_registration.views.ActivationView` subclass used
to activate the user.
`user`
A user-model instance representing the activated account.
`request`
The :class:`~django.http.HttpRequest` in which the account was
activated.
This signal is automatically sent for you by the base
:class:`~django_registration.views.ActivationView`, so unless
you've overridden its
:meth:`~django.views.generic.base.TemplateView.get` method in a
subclass you should not need to explicitly send it.
.. data:: user_registered
Sent when a new user account is registered. Provides the following
arguments:
`sender`
The :class:`~django_registration.views.RegistrationView` subclass used
to register the account.
`user`
A user-model instance representing the new account.
`request`
The :class:`~django.http.HttpRequest` in which the new account
was registered.
This signal is **not** automatically sent for you by the base
:class:`~django_registration.views.RegistrationView`. It is sent by
the subclasses implemented for the three included registration
workflows, but if you write your own subclass of
:class:`~django_registration.views.RegistrationView`, you'll need
to send this signal as part of the implementation of the
:meth:`~django_registration.views.RegistrationView.register`
method. ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1653722691.0
django-registration-3.3/docs/spelling_wordlist.txt 0000644 0000767 0000024 00000001156 00000000000 021556 0 ustar 00james staff а
a
admin
apps
auth
authenticator
autoconfig
backend
backends
Backend
Backends
blog
boolean
bugfixes
checkbox
cleanupregistration
codebase
confusable
cryptographic
customizability
customizable
dev
django
Facebook
favicon
filenames
hostnames
https
ico
interoperability
login
logout
lookup
metaclass
Morgenstern
namespace
namespacing
noreply
online
parsers
paypal
pаypаl
pre
regex
registrationview
runtime
serializable
signup
signups
spambots
subclassed
subclasses
subclassing
subdomain
subdomains
timestamp
timestamped
tuple
txt
unactivated
username
usernames
Usernames
validator
validators
versa
workflow
workflows
www
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1653722284.0
django-registration-3.3/docs/upgrade.rst 0000644 0000767 0000024 00000033041 00000000000 017430 0 ustar 00james staff .. _upgrade:
Upgrading from previous versions
================================
The current release series of django-registration is the 3.x series,
which is not backwards-compatible with the django-registration 2.x
release series.
Changes within the 3.x series
-----------------------------
Within the 3.x release series, there have been several minor changes
and improvements, documented here along with the version in which they
occurred.
django-registration 3.3
~~~~~~~~~~~~~~~~~~~~~~~
This release contains no new features or bugfixes. The supported
Python and Django versions are changed to:
* Django 3.2 and 4.0, on Python 3.7 (Django 3.2 only), 3.8, 3.9, and 3.10.
django-registration 3.2
~~~~~~~~~~~~~~~~~~~~~~~
This release contains no new features or bugfixes. The supported
Python and Django versions are changed to:
* Django 2.2, 3.1, and 3.2, on Python 3.6, 3.7, 3.8, and 3.9.
Python 3.5 reached the end of its upstream support cycle in September
2020, and is no longer supported. Django 3.0 reached the end of its
upstream support cycle in May 2021, and is no longer supported.
django-registration 3.1.2
~~~~~~~~~~~~~~~~~~~~~~~~~
This release fixes a security issue with low severity.
Prior to 3.1.2, django-registration did not apply Django's
:func:`~django.views.decorators.debug.sensitive_post_parameters`
decorator to the base
:class:`~django_registration.views.RegistrationView`. This meant that
if detailed error reports, such as `Django's error reports emailed to
site staff
`_,
were enabled, and a server-side error occurred during account
registration, the generated error report would include all fields
submitted in the HTTP request, some of which are potentially sensitive
depending on the user-account model and registration workflow in use.
This issue is CVE-2021-21416 and GitHub security advisory
GHSA-58c7-px5v-82hh.
Thanks to Martin Morgenstern for reporting this issue.
Django-registration 3.1
~~~~~~~~~~~~~~~~~~~~~~~
* When an attempt was made to use django-registration with a custom
user model, but *without* explicitly subclassing
:class:`~django_registration.forms.RegistrationForm` to point to
that user model, previously the result would be a cryptic exception
and error message raised from within Django, complaining about
trying to work with the swapped-out user
model. :class:`~django_registration.views.RegistrationView` now
explicitly raises
:exc:`~django.core.exceptions.ImproperlyConfigured` with an
informative error message to make it clear what has happened, and
directs the developer to the documentation for using custom user
models in django-registration.
* A new validator,
:class:`~django_registration.validators.HTML5EmailValidator`, is
included and is applied by default to the email field of
:class:`~django_registration.forms.RegistrationForm`. The HTML5
email address grammar is more restrictive than the RFC grammar, but
primarily in disallowing rare and problematic features.
* Support for Python 2 was dropped, as Python 2 is EOL as of
2020-01-01. As a result, support for Django 1.11 (EOL April 2020)
was also dropped; the minimum supported Django version is now 2.2.
django-registration 3.0.1
~~~~~~~~~~~~~~~~~~~~~~~~~
* The :ref:`custom validators ` are now serializable.
* Although no code changes were required, this release officially
marks itself compatible with Python 3.7 and with django 2.2.
Changes between django-registration 2.x and 3.x
-----------------------------------------------
Module renaming
~~~~~~~~~~~~~~~
Prior to 3.x, django-registration installed a Python module named
`registration`. To avoid silent incompatibilities, and to conform to
more recent best practices, django-registration 3.x now installs a
module named `django_registration`. Attempts to import from the
`registration` module will immediately fail with :exc:`ImportError`.
Many installations will be able to adapt by replacing references to
`registration` with references to `django_registration`.
Removal of model-based workflow
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The two-step model-based signup workflow, which has been present since
the first public release of django-registration in 2007, has now been
removed. In its place, it is recommended that you use :ref:`the
two-step activation workflow ` instead, as that
workflow requires no server-side storage of additional data beyond the
user account itself.
Renaming of two-step activation workflow
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
:ref:`The two-step activation workflow ` was
previously found at `registration.backends.hmac`; it has been
renamed and is now found at `registration.backends.activation`.
Renaming of one-step workflow
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
:ref:`The one-step workflow ` was previously found
at `registration.backends.simple`; it has been renamed and is now
found at `registration.backends.one_step`.
Removal of auth URLs
~~~~~~~~~~~~~~~~~~~~
Prior to 3.x, django-registration's default URLconf modules for its
built-in workflows would attempt to include the Django auth views
(login, logout, password reset, etc.) for you. This became untenable
with the rewrite of Django's auth views to be class-based, as it
required detecting the set of auth views and choosing a set of URL
patterns at runtime.
As a result, auth views are no longer automatically configured for
you; if you want them, :func:`~django.urls.include` the URLconf
`django.contrib.auth.urls` at a location of your choosing.
Distinguishing activation failure conditions
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Prior to 3.x, failures to activate a user account (in workflows which
use activation) all simply returned `None` in place of the activated
account. This meant it was not possible to determine, from inspecting
the result, what exactly caused the failure.
In django-registration 3.x, activation failures raise an exception --
:exc:`~django_registration.exceptions.ActivationError` -- with a
message and code (such as `"expired"`), to indicate the cause of
failure. This exception is caught by
:class:`~django_registration.views.ActivationView` and turned into the
template context variable `activation_error`.
Changes to custom user support
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Support for custom user models has been brought more in line with the
features Django offers. This affects compatibility of custom user
models with django-registration's default forms and views. In
particular, custom user models should now provide, in addition to
:attr:`~django.contrib.auth.CustomUser.USERNAME_FIELD`, the
:meth:`~django.contrib.auth.models.AbstractBaseUser.get_username` and
:meth:`~django.contrib.auth.models.AbstractBaseUser.get_email_field_name`
methods. See :ref:`the custom user documentation ` for
details.
Changes to `success_url`
~~~~~~~~~~~~~~~~~~~~~~~~~~
Both the registration and activation views mimic Django's own generic
views in supporting a choice of ways to specify where to redirect
after a successful registration or activation; you can either set the
attribute
:attr:`~django_registration.views.RegistrationView.success_url` on the
view class, or implement the method
:meth:`~django_registration.views.RegistrationView.get_success_url`
. However, there is a key difference between the base Django
generic-view version of this, and the version in django-registration:
when calling a
:meth:`~django_registration.views.RegistrationView.get_success_url`
method, django-registration passes the user account as an argument.
This is incompatible with the behavior of Django's base
:class:`~django.views.generic.edit.FormMixin`, which expects
:meth:`~django.views.generic.edit.FormMixin.get_success_url` to take
zero arguments.
Also, earlier versions of django-registration allowed
:attr:`~django_registration.views.RegistrationView.success_url` and
:meth:`~django_registration.views.RegistrationView.get_success_url` to
provide either a string URL, or a tuple of `(viewname, args,
kwargs)` to pass to Django's :func:`~django.urls.reverse` helper, in
order to work around issues caused by calling
:func:`~django.urls.reverse` at the level of a class attribute.
In django-registration 3.x, the `user` argument to
:meth:`~django_registration.views.RegistrationView.get_success_url` is
now optional, meaning :class:`~django.views.generic.edit.FormMixin`'s
default behavior is now compatible with any
:meth:`~django_registration.views.RegistrationView.get_success_url`
implementation that doesn't require the user object; as a result,
implementations which don't rely on the user object should either
switch to specifying
:attr:`~django_registration.views.RegistrationView.success_url` as an
attribute, or change their own signature to `get_success_url(self,
user=None)`.
Also, the ability to supply the 3-tuple of arguments for
:func:`~django.urls.reverse` has been removed; both
:attr:`~django_registration.views.RegistrationView.success_url` and
:meth:`~django_registration.views.RegistrationView.get_success_url`
now *must* be/return either a string, or a lazy object that resolves
to a string. To avoid class-level calls to
:func:`~django.urls.reverse`, use `django.urls.reverse_lazy()`
instead.
Removed "no free email" form
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Earlier versions of django-registration included a form class,
`RegistrationFormNoFreeEmail`, which attempted to forbid user
signups using common free/throwaway email providers. Since this is a
pointless task (the number of possible domains of such providers is
ever-growing), this form class has been removed.
Template names
~~~~~~~~~~~~~~
Since django-registration's Python module has been renamed from
`registration` to `django_registration`, its default template
folder has also been renamed, from `registration` to
`django_registration`. Additionally, the following templates have
undergone name changes:
* The default template name for the body of the activation email in
the two-step activation workflow is now
`django_registration/activation_email_body.txt` (previously, it
was `registration/activation_email.txt`)
* The default template name for
:class:`~django_registration.views.ActivationView` and its
subclasses is now `django_registration/activation_failed.html`
(previously, it was `registration/activate.html`).
Renaming of URL patterns
~~~~~~~~~~~~~~~~~~~~~~~~
Prior to 3.x, django-registration's included URLconf modules provided
URL pattern names beginning with `"registration"`. For example:
`"registration_register"`. In 3.x, these are all renamed to begin
with `"django_registration"`. For example:
`"django_registration_register"`.
Removal of `cleanupregistration` management command
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The "cleanupregistration" management command, and the
RegistrationProfile.objects.delete_expired_users() and
RegistrationProfile.objects.expired() methods, were removed
in django-registration 3.0.
Deployments which need a way to identify and delete
expired accounts should determine how they wish to do so
and implement their own methods for this.
Other changes
~~~~~~~~~~~~~
The URLconf `registration.urls` has been removed; it was an alias
for the URLconf of the model-based workflow, which has also been
removed.
The compatibility alias `registration.backends.default`, which also
pointed to the model-based workflow, has been removed.
Changes during the 2.x release series
-------------------------------------
One major change occurred between django-registration 2.0 and 2.1: the
addition in version 2.1 of the
:class:`~django_registration.validators.ReservedNameValidator`, which is now
used by default on :class:`~django_registration.forms.RegistrationForm` and
its subclasses.
This is technically backwards-incompatible, since a set of usernames
which previously could be registered now cannot be registered, but was
included because the security benefits outweigh the edge cases of the
now-disallowed usernames. If you need to allow users to register with
usernames forbidden by this validator, see its documentation for notes
on how to customize or disable it.
In 2.2, the behavior of the `RegistrationProfile.expired()` method
was clarified to accommodate user expectations; it does *not* return
(and thus, `RegistrationProfile.delete_expired_users()` does not
delete) profiles of users who had successfully activated.
In django-registration 2.3, the new validators
:func:`~django_registration.validators.validate_confusables` and
:func:`~django_registration.validators.validate_confusables_email` were
added, and are applied by default to the username field and email
field, respectively, of registration forms. This may cause some
usernames which previously were accepted to no longer be accepted, but
like the reserved-name validator this change was made because its
security benefits significantly outweigh the edge cases in which it
might disallow an otherwise-acceptable username or email address. If
for some reason you need to allow registration with usernames or email
addresses containing potentially dangerous use of Unicode, you can
subclass the registration form and remove these validators, though
doing so is not recommended.
Versions prior to 2.0
---------------------
A 1.0 release of django-registration existed, but the 2.x series was
compatible with it.
Prior to 1.0, the most widely-adopted version of django-registration
was 0.8; the changes from 0.8 to 2.x were large and significant, and
if any installations on 0.8 still exist and wish to upgrade to more
recent versions, it is likely the most effective route will be to
discard all code using 0.8 and start over from scratch with a 3.x
release.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1577949953.0
django-registration-3.3/docs/validators.rst 0000644 0000767 0000024 00000020144 00000000000 020151 0 ustar 00james staff .. _validators:
.. module:: django_registration.validators
Validation utilities
====================
To ease the process of validating user registration data,
django-registration includes some validation-related data and
utilities.
Error messages
--------------
Several error messages are available as constants. All of them are
marked for translation; most have translations already provided in
django-registration.
.. data:: DUPLICATE_EMAIL
Error message raised by
:class:`~django_registration.forms.RegistrationFormUniqueEmail` when the
supplied email address is not unique.
.. data:: DUPLICATE_USERNAME
Error message raised by
:class:`~django_registration.validators.CaseInsensitiveValidator`
when the supplied username is not unique. This is the same string
raised by Django's default
:class:`~django.contrib.auth.models.User` model for a non-unique
username.
.. data:: RESERVED_NAME
Error message raised by
:class:`~django_registration.validators.ReservedNameValidator` when it is
given a value that is a reserved name.
.. data:: TOS_REQUIRED
Error message raised by
:class:`~django_registration.forms.RegistrationFormTermsOfService` when
the terms-of-service field is not checked.
Rejecting "reserved" usernames
------------------------------
By default, django-registration treats some usernames as reserved.
.. note:: **Why reserved names are reserved**
Many Web applications enable per-user URLs (to display account
information), and some may also create email addresses or even
subdomains, based on a user's username. While this is often useful,
it also represents a risk: a user might register a name which
conflicts with an important URL, email address or subdomain, and
this might give that user control over it.
django-registration includes a list of reserved names, and rejects
them as usernames by default, in order to avoid this issue.
.. class:: ReservedNameValidator(reserved_names)
A callable validator class (see `Django's validators documentation
`_) which
prohibits the use of a reserved name as the value.
By default, this validator is applied to the username field of
:class:`django_registration.forms.RegistrationForm` and all of its
subclasses. This validator is attached to the list of validators
for the username field, so to remove it (not recommended), subclass
:class:`~django_registration.forms.RegistrationForm` and override
`__init__()` to change the set of validators on the username field.
If you want to supply your own custom list of reserved names, you
can subclass :class:`~django_registration.forms.RegistrationForm`
and set the attribute `reserved_names` to the list of values you
want to disallow.
The default list of reserved names, if you don't specify one, is
:data:`~django_registration.validators.DEFAULT_RESERVED_NAMES`. The
validator will also reject any value beginning with the string
`".well-known"` (see `RFC 5785
`_).
:param list reserved_names: A list of reserved names to forbid.
:raises django.core.exceptions.ValidationError: if the provided
value is reserved.
Several constants are provided which are used by this validator:
.. data:: CA_ADDRESSES
A list of email usernames commonly used by certificate authorities
when verifying identity.
.. data:: NOREPLY_ADDRESSES
A list of common email usernames used for automated messages from a
Web site (such as "noreply" and "mailer-daemon").
.. data:: PROTOCOL_HOSTNAMES
A list of protocol-specific hostnames sites commonly want to
reserve, such as "www" and "mail".
.. data:: OTHER_SENSITIVE_NAMES
Other names, not covered by any of the other lists, which have the
potential to conflict with common URLs or subdomains, such as
"blog" and "docs".
.. data:: RFC_2142
A list of common email usernames specified by `RFC 2142
`_.
.. data:: SENSITIVE_FILENAMES
A list of common filenames with important meanings, such that
usernames should not be allowed to conflict with them (such as
"favicon.ico" and "robots.txt").
.. data:: SPECIAL_HOSTNAMES
A list of hostnames with reserved or special meaning (such as
"autoconfig", used by some email clients to automatically discover
configuration data for a domain).
.. data:: DEFAULT_RESERVED_NAMES
A list made of the concatenation of all of the above lists, used as
the default set of reserved names for
:class:`~django_registration.validators.ReservedNameValidator`.
Protecting against homograph attacks
------------------------------------
By default, Django permits a broad range of Unicode to be used in
usernames; while this is useful for serving a worldwide audience, it
also creates the possibility of `homograph attacks
`_ through the use
of characters which are easily visually confused for each other (for
example: "pаypаl" containing a Cyrillic "а", visually
indistinguishable in many fonts from a Latin "а").
To protect against this, django-registration applies some validation
rules to usernames and email addresses.
.. function:: validate_confusables(value)
A custom validator which prohibits the use of
dangerously-confusable usernames.
This validator will reject any mixed-script value (as defined by
Unicode 'Script' property) which also contains one or more
characters that appear in the Unicode Visually Confusable
Characters file.
This validator is enabled by default on the username field of
registration forms.
:param str value: The username value to validate (non-string
usernames will not be checked)
:raises django.core.exceptions.ValidationError: if the value is mixed-script confusable
.. function:: validate_confusables_email(value)
A custom validator which prohibits the use of
dangerously-confusable email address.
This validator will reject any email address where either the
local-part of the domain is -- when considered in isolation --
dangerously confusable. A string is dangerously confusable if it is
a mixed-script value (as defined by Unicode 'Script' property)
which also contains one or more characters that appear in the
Unicode Visually Confusable Characters file.
This validator is enabled by default on the email field of
registration forms.
:param str value: The email address to validate
:raises django.core.exceptions.ValidationError: if the value is mixed-script confusable
Other validators
----------------
.. class:: CaseInsensitiveUnique(model, field_name)
A callable validator class (see `Django's validators documentation
`_) which
enforces case-insensitive uniqueness on a given field of a
particular model. Used by
:class:`~django_registration.forms.RegistrationFormCaseInsensitive`
for case-insensitive username uniqueness, and
:class:`~django_registration.forms.RegistrationFormUniqueEmail` for
unique email addresses.
:param django.db.models.Model model: The model class to query
against for uniqueness checks.
:param str field_name: The field name to perform the uniqueness
check against.
:raises django.core.exceptions.ValidationError: if the value is not
unique.
.. class:: HTML5EmailValidator
A callable validator class (see `Django's validators documentation
`_) which
enforces the `HTML5 email address format
`_. The
format used by HTML5's `input type="email"` is deliberately more
restrictive than what is permitted by the latest email RFCs;
specifically, HTML5's validation rule disallows a number of rare
and problematic features -- such as embedded comments and
quoted-string inclusion of otherwise-illegal characters -- which
are technically legal to have in an email address but which now
mostly serve to confuse or complicate parsers, rather than to
provide actual utility.
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1580075525.0
django-registration-3.3/docs/views.rst 0000644 0000767 0000024 00000014254 00000000000 017143 0 ustar 00james staff .. _views:
.. module:: django_registration.views
Base view classes
=================
In order to allow the utmost flexibility in customizing and supporting
different workflows, django-registration makes use of Django's
support for `class-based views
`_. Included
in django-registration are two base classes which can be
subclassed to implement many types of registration workflows.
The built-in workflows in django-registration provide their own
subclasses of these views, and the documentation for those workflows
will indicate customization points specific to those subclasses. The
following reference covers useful attributes and methods of the base
classes, for use in writing your own custom registration workflows.
.. class:: RegistrationView
A subclass of Django's :class:`~django.views.generic.edit.FormView`
which provides the infrastructure for supporting user registration.
Standard attributes and methods of
:class:`~django.views.generic.edit.FormView` can be overridden to
control behavior as described in Django's documentation, with the
exception of :meth:`get_success_url`, which must use the signature
documented below.
When writing your own subclass, one method is required:
.. method:: register(form)
Implement your registration logic here. `form` will be the
(already-validated) form filled out by the user during the
registration process (i.e., a valid instance of
:class:`~django_registration.forms.RegistrationForm` or a subclass of
it).
This method should return the newly-registered user instance,
and should send the signal
:data:`django_registration.signals.user_registered`. Note that this is
not automatically done for you when writing your own custom
subclass, so you must send this signal manually.
:param django_registration.forms.RegistrationForm form: The registration form to use.
:rtype: django.contrib.auth.models.AbstractUser
Useful optional places to override or customize on subclasses are:
.. attribute:: disallowed_url
The URL to redirect to when registration is disallowed. Can be a
hard-coded string, the string resulting from calling Django's
:func:`~django.urls.reverse` helper, or the lazy object produced
by Django's :func:`~django.urls.reverse_lazy` helper. Default
value is the result of calling :func:`~django.urls.reverse_lazy`
with the URL name `'registration_disallowed'`.
.. attribute:: form_class
The form class to use for user registration. Can be overridden
on a per-request basis (see below). Should be the actual class
object; by default, this class is
:class:`django_registration.forms.RegistrationForm`.
.. attribute:: success_url
The URL to redirect to after successful registration. Can be a
hard-coded string, the string resulting from calling Django's
:func:`~django.urls.reverse` helper, or the lazy object produced
by Django's :func:`~django.urls.reverse_lazy` helper. Can be
overridden on a per-request basis (see below). Default value is
`None`; subclasses must override and provide this.
.. attribute:: template_name
The template to use for user registration. Should be a
string. Default value is
`'django_registration/registration_form.html'`.
.. method:: get_form_class()
Select a form class to use on a per-request basis. If not
overridden, will use :attr:`~form_class`. Should be the actual
class object.
:rtype: django_registration.forms.RegistrationForm
.. method:: get_success_url(user)
Return a URL to redirect to after successful registration, on a
per-request or per-user basis. If not overridden, will use
:attr:`~success_url`. Should return a value of the same type as
:attr:`success_url` (see above).
:param django.contrib.auth.models.AbstractUser user: The new user account.
:rtype: str
.. method:: registration_allowed()
Should indicate whether user registration is allowed, either in
general or for this specific request. Default value is the value
of the setting :data:`~django.conf.settings.REGISTRATION_OPEN`.
:rtype: bool
.. class:: ActivationView
A subclass of Django's
:class:`~django.views.generic.base.TemplateView` which provides
support for a separate account-activation step, in workflows which
require that.
One method is required:
.. method:: activate(*args, **kwargs)
Implement your activation logic here. You are free to configure
your URL patterns to pass any set of positional or keyword
arguments to :class:`ActivationView`, and they will in turn be
passed to this method.
This method should return the newly-activated user instance (if
activation was successful), or raise
:class:`~django_registration.exceptions.ActivationError` (if
activation was not successful).
:rtype: django.contrib.auth.models.AbstractUser
:raises django_registration.exceptions.ActivationError: if activation fails.
Useful places to override or customize on an
:class:`ActivationView` subclass are:
.. attribute:: success_url
The URL to redirect to after successful activation. Can be a
hard-coded string, the string resulting from calling Django's
:func:`~django.urls.reverse` helper, or the lazy object produced
by Django's :func:`~django.urls.reverse_lazy` helper. Can be
overridden on a per-request basis (see below). Default value is
`None`; subclasses must override and provide this.
.. attribute:: template_name
The template to use after failed user activation. Should be a
string. Default value is
`'django_registration/activation_failed.html'`.
.. method:: get_success_url(user)
Return a URL to redirect to after successful activation, on a
per-request or per-user basis. If not overridden, will use
:attr:`~success_url`. Should return a value of the same type as
:attr:`success_url` (see above).
:param django.contrib.auth.models.AbstractUser user: The activated user account.
:rtype: str
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1624320753.0
django-registration-3.3/runtests.py 0000644 0000767 0000024 00000005250 00000000000 016561 0 ustar 00james staff """
A standalone test runner script, configuring the minimum settings
required for tests to execute.
Re-use at your own risk: many Django applications will require
different settings and/or templates to run their tests.
"""
import os
import sys
from django.utils.crypto import get_random_string
APP_DIR = os.path.abspath(os.path.dirname(__file__))
# Minimum settings required for the app's tests.
SETTINGS_DICT = {
"BASE_DIR": APP_DIR,
"INSTALLED_APPS": (
"django.contrib.auth",
"django.contrib.contenttypes",
"django.contrib.sessions",
"django.contrib.sites",
"django_registration",
"tests",
),
# Test cases will override this liberally.
"ROOT_URLCONF": "django_registration.backends.activation.urls",
"DATABASES": {
"default": {"ENGINE": "django.db.backends.sqlite3", "NAME": ":memory:"}
},
"DEFAULT_AUTO_FIELD": "django.db.models.AutoField",
"MIDDLEWARE": (
"django.middleware.common.CommonMiddleware",
"django.middleware.csrf.CsrfViewMiddleware",
"django.contrib.sessions.middleware.SessionMiddleware",
"django.contrib.auth.middleware.AuthenticationMiddleware",
),
"SECRET_KEY": get_random_string(12),
"SITE_ID": 1,
"TEMPLATES": [
{
"BACKEND": "django.template.backends.django.DjangoTemplates",
"DIRS": [os.path.join(APP_DIR, "tests/templates")],
"OPTIONS": {
"context_processors": [
"django.contrib.auth.context_processors.auth",
"django.template.context_processors.debug",
"django.template.context_processors.i18n",
"django.template.context_processors.media",
"django.template.context_processors.static",
"django.template.context_processors.tz",
"django.contrib.messages.context_processors.messages",
]
},
}
],
}
def run_tests():
# Making Django run this way is a two-step process. First, call
# settings.configure() to give Django settings to work with:
from django.conf import settings
settings.configure(**SETTINGS_DICT)
# Then, call django.setup() to initialize the application cache
# and other bits:
import django
django.setup()
# Now we instantiate a test runner...
from django.test.utils import get_runner
TestRunner = get_runner(settings)
# And then we run tests and return the results.
test_runner = TestRunner(verbosity=2, interactive=True)
failures = test_runner.run_tests(["tests"])
sys.exit(bool(failures))
if __name__ == "__main__":
run_tests()
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4817152
django-registration-3.3/setup.cfg 0000644 0000767 0000024 00000000632 00000000000 016140 0 ustar 00james staff [metadata]
license_file = LICENSE
[coverage:paths]
source =
src
.tox/*/site-packages
[coverage:report]
fail_under = 100
exclude_lines =
pragma: no cover
def __str__
raise NotImplementedError
[flake8]
extend-ignore = E203
max-complexity = 10
max-line-length = 88
[isort]
profile = black
[check-manifest]
ignore =
__pycache__
*.pyc
ignore-bad-ideas =
*.mo
[egg_info]
tag_build =
tag_date = 0
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1653721593.0
django-registration-3.3/setup.py 0000644 0000767 0000024 00000002706 00000000000 016035 0 ustar 00james staff import os
from setuptools import find_packages, setup
setup(
name="django-registration",
zip_safe=False, # eggs are the devil.
version="3.3",
description="An extensible user-registration application for Django",
long_description=open(os.path.join(os.path.dirname(__file__), "README.rst")).read(),
author="James Bennett",
author_email="james@b-list.org",
url="https://github.com/ubernostrum/django-registration/",
include_package_data=True,
package_dir={"": "src"},
packages=find_packages("src"),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Framework :: Django :: 3.1",
"Framework :: Django :: 3.2",
"Framework :: Django :: 4.0",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Software Development :: Libraries :: Python Modules",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Topic :: Utilities",
],
python_requires=">=3.7",
install_requires=["Django>=3.2", "confusable_homoglyphs~=3.0"],
)
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4232383
django-registration-3.3/src/ 0000755 0000767 0000024 00000000000 00000000000 015105 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4463608
django-registration-3.3/src/django_registration/ 0000755 0000767 0000024 00000000000 00000000000 021141 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/__init__.py 0000644 0000767 0000024 00000000000 00000000000 023240 0 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4495573
django-registration-3.3/src/django_registration/backends/ 0000755 0000767 0000024 00000000000 00000000000 022713 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/backends/__init__.py 0000644 0000767 0000024 00000000000 00000000000 025012 0 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000033 00000000000 010211 x ustar 00 27 mtime=1653723062.450617
django-registration-3.3/src/django_registration/backends/activation/ 0000755 0000767 0000024 00000000000 00000000000 025054 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/backends/activation/__init__.py 0000644 0000767 0000024 00000000554 00000000000 027171 0 ustar 00james staff """
A two-step (signup, then activation) registration workflow, using
HMAC-signed tokens.
To use, include() the provided URLconf --
registration.backends.hmac.urls -- somewhere in your URL
configuration.
For more details, see the documentation in the docs/ directory of the
source-code distribution, or online at
https://django-registration.readthedocs.io/
"""
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1607759404.0
django-registration-3.3/src/django_registration/backends/activation/urls.py 0000644 0000767 0000024 00000002145 00000000000 026415 0 ustar 00james staff """
URLconf for registration and activation, using django-registration's
HMAC activation workflow.
"""
from django.urls import path
from django.views.generic.base import TemplateView
from . import views
urlpatterns = [
path(
"activate/complete/",
TemplateView.as_view(
template_name="django_registration/activation_complete.html"
),
name="django_registration_activation_complete",
),
path(
"activate//",
views.ActivationView.as_view(),
name="django_registration_activate",
),
path(
"register/",
views.RegistrationView.as_view(),
name="django_registration_register",
),
path(
"register/complete/",
TemplateView.as_view(
template_name="django_registration/registration_complete.html"
),
name="django_registration_complete",
),
path(
"register/closed/",
TemplateView.as_view(
template_name="django_registration/registration_closed.html"
),
name="django_registration_disallowed",
),
]
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1607759404.0
django-registration-3.3/src/django_registration/backends/activation/views.py 0000644 0000767 0000024 00000013146 00000000000 026570 0 ustar 00james staff """
A two-step (registration followed by activation) workflow, implemented
by emailing an HMAC-verified timestamped activation token to the user
on signup.
"""
from django.conf import settings
from django.contrib.auth import get_user_model
from django.contrib.sites.shortcuts import get_current_site
from django.core import signing
from django.template.loader import render_to_string
from django.urls import reverse_lazy
from django.utils.translation import gettext_lazy as _
from django_registration import signals
from django_registration.exceptions import ActivationError
from django_registration.views import ActivationView as BaseActivationView
from django_registration.views import RegistrationView as BaseRegistrationView
REGISTRATION_SALT = getattr(settings, "REGISTRATION_SALT", "registration")
class RegistrationView(BaseRegistrationView):
"""
Register a new (inactive) user account, generate an activation key
and email it to the user.
This is different from the model-based activation workflow in that
the activation key is the username, signed using Django's
TimestampSigner, with HMAC verification on activation.
"""
email_body_template = "django_registration/activation_email_body.txt"
email_subject_template = "django_registration/activation_email_subject.txt"
success_url = reverse_lazy("django_registration_complete")
def register(self, form):
new_user = self.create_inactive_user(form)
signals.user_registered.send(
sender=self.__class__, user=new_user, request=self.request
)
return new_user
def create_inactive_user(self, form):
"""
Create the inactive user account and send an email containing
activation instructions.
"""
new_user = form.save(commit=False)
new_user.is_active = False
new_user.save()
self.send_activation_email(new_user)
return new_user
def get_activation_key(self, user):
"""
Generate the activation key which will be emailed to the user.
"""
return signing.dumps(obj=user.get_username(), salt=REGISTRATION_SALT)
def get_email_context(self, activation_key):
"""
Build the template context used for the activation email.
"""
scheme = "https" if self.request.is_secure() else "http"
return {
"scheme": scheme,
"activation_key": activation_key,
"expiration_days": settings.ACCOUNT_ACTIVATION_DAYS,
"site": get_current_site(self.request),
}
def send_activation_email(self, user):
"""
Send the activation email. The activation key is the username,
signed using TimestampSigner.
"""
activation_key = self.get_activation_key(user)
context = self.get_email_context(activation_key)
context["user"] = user
subject = render_to_string(
template_name=self.email_subject_template,
context=context,
request=self.request,
)
# Force subject to a single line to avoid header-injection
# issues.
subject = "".join(subject.splitlines())
message = render_to_string(
template_name=self.email_body_template,
context=context,
request=self.request,
)
user.email_user(subject, message, settings.DEFAULT_FROM_EMAIL)
class ActivationView(BaseActivationView):
"""
Given a valid activation key, activate the user's
account. Otherwise, show an error message stating the account
couldn't be activated.
"""
ALREADY_ACTIVATED_MESSAGE = _(
"The account you tried to activate has already been activated."
)
BAD_USERNAME_MESSAGE = _("The account you attempted to activate is invalid.")
EXPIRED_MESSAGE = _("This account has expired.")
INVALID_KEY_MESSAGE = _("The activation key you provided is invalid.")
success_url = reverse_lazy("django_registration_activation_complete")
def activate(self, *args, **kwargs):
username = self.validate_key(kwargs.get("activation_key"))
user = self.get_user(username)
user.is_active = True
user.save()
return user
def validate_key(self, activation_key):
"""
Verify that the activation key is valid and within the
permitted activation time window, returning the username if
valid or raising ``ActivationError`` if not.
"""
try:
username = signing.loads(
activation_key,
salt=REGISTRATION_SALT,
max_age=settings.ACCOUNT_ACTIVATION_DAYS * 86400,
)
return username
except signing.SignatureExpired:
raise ActivationError(self.EXPIRED_MESSAGE, code="expired")
except signing.BadSignature:
raise ActivationError(
self.INVALID_KEY_MESSAGE,
code="invalid_key",
params={"activation_key": activation_key},
)
def get_user(self, username):
"""
Given the verified username, look up and return the
corresponding user account if it exists, or raising
``ActivationError`` if it doesn't.
"""
User = get_user_model()
try:
user = User.objects.get(**{User.USERNAME_FIELD: username})
if user.is_active:
raise ActivationError(
self.ALREADY_ACTIVATED_MESSAGE, code="already_activated"
)
return user
except User.DoesNotExist:
raise ActivationError(self.BAD_USERNAME_MESSAGE, code="bad_username")
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4517224
django-registration-3.3/src/django_registration/backends/one_step/ 0000755 0000767 0000024 00000000000 00000000000 024527 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/backends/one_step/__init__.py 0000644 0000767 0000024 00000000574 00000000000 026646 0 ustar 00james staff """
A one-step registration workflow, in which a user signs up and is
immediately active and logged in.
To use, include() the provided URLconf --
registration.backends.simple.urls -- somewhere in your URL
configuration.
For more details, see the documentation in the docs/ directory of the
source-code distribution, or online at
https://django-registration.readthedocs.io/
"""
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1607759404.0
django-registration-3.3/src/django_registration/backends/one_step/urls.py 0000644 0000767 0000024 00000001345 00000000000 026071 0 ustar 00james staff """
URLconf for registration using django-registration's one-step
workflow.
"""
from django.urls import path
from django.views.generic.base import TemplateView
from . import views
urlpatterns = [
path(
"register/",
views.RegistrationView.as_view(),
name="django_registration_register",
),
path(
"register/closed/",
TemplateView.as_view(
template_name="django_registration/registration_closed.html"
),
name="django_registration_disallowed",
),
path(
"register/complete/",
TemplateView.as_view(
template_name="django_registration/registration_complete.html"
),
name="django_registration_complete",
),
]
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1607759404.0
django-registration-3.3/src/django_registration/backends/one_step/views.py 0000644 0000767 0000024 00000002120 00000000000 026231 0 ustar 00james staff """
A one-step (user signs up and is immediately active and logged in)
workflow.
"""
from django.contrib.auth import authenticate, get_user_model, login
from django.urls import reverse_lazy
from django_registration import signals
from django_registration.views import RegistrationView as BaseRegistrationView
User = get_user_model()
class RegistrationView(BaseRegistrationView):
"""
Registration via the simplest possible process: a user supplies a
username, email address and password (the bare minimum for a
useful account), and is immediately signed up and logged in.
"""
success_url = reverse_lazy("django_registration_complete")
def register(self, form):
new_user = form.save()
new_user = authenticate(
**{
User.USERNAME_FIELD: new_user.get_username(),
"password": form.cleaned_data["password1"],
}
)
login(self.request, new_user)
signals.user_registered.send(
sender=self.__class__, user=new_user, request=self.request
)
return new_user
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1570956603.0
django-registration-3.3/src/django_registration/exceptions.py 0000644 0000767 0000024 00000000745 00000000000 023702 0 ustar 00james staff """
Exception classes used in registration workflows.
"""
class RegistrationError(Exception):
"""
Base class for registration errors.
"""
def __init__(self, message, code=None, params=None):
super(RegistrationError, self).__init__(message, code, params)
self.message = message
self.code = code
self.params = params
class ActivationError(RegistrationError):
"""
Base class for account-activation errors.
"""
pass
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1607759404.0
django-registration-3.3/src/django_registration/forms.py 0000644 0000767 0000024 00000006476 00000000000 022656 0 ustar 00james staff """
Forms and validation code for user registration.
Note that all of these forms assume your user model is similar in
structure to Django's default User class. If your user model is
significantly different, you may need to write your own form class;
see the documentation for notes on custom user models with
django-registration.
"""
from django import forms
from django.contrib.auth import get_user_model
from django.contrib.auth.forms import UserCreationForm
from django.utils.translation import gettext_lazy as _
from . import validators
User = get_user_model()
class RegistrationForm(UserCreationForm):
"""
Form for registering a new user account.
Validates that the requested username is not already in use, and
requires the password to be entered twice to catch typos.
Subclasses should feel free to add any additional validation they
need, but should take care when overriding ``save()`` to respect
the ``commit=False`` argument, as several registration workflows
will make use of it to create inactive user accounts.
"""
class Meta(UserCreationForm.Meta):
fields = [
User.USERNAME_FIELD,
User.get_email_field_name(),
"password1",
"password2",
]
error_css_class = "error"
required_css_class = "required"
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
email_field = User.get_email_field_name()
if hasattr(self, "reserved_names"):
reserved_names = self.reserved_names
else:
reserved_names = validators.DEFAULT_RESERVED_NAMES
username_validators = [
validators.ReservedNameValidator(reserved_names),
validators.validate_confusables,
]
self.fields[User.USERNAME_FIELD].validators.extend(username_validators)
self.fields[email_field].validators.extend(
(validators.HTML5EmailValidator(), validators.validate_confusables_email)
)
self.fields[email_field].required = True
class RegistrationFormCaseInsensitive(RegistrationForm):
"""
Subclass of ``RegistrationForm`` enforcing case-insensitive
uniqueness of usernames.
"""
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.fields[User.USERNAME_FIELD].validators.append(
validators.CaseInsensitiveUnique(
User, User.USERNAME_FIELD, validators.DUPLICATE_USERNAME
)
)
class RegistrationFormTermsOfService(RegistrationForm):
"""
Subclass of ``RegistrationForm`` which adds a required checkbox
for agreeing to a site's Terms of Service.
"""
tos = forms.BooleanField(
widget=forms.CheckboxInput,
label=_("I have read and agree to the Terms of Service"),
error_messages={"required": validators.TOS_REQUIRED},
)
class RegistrationFormUniqueEmail(RegistrationForm):
"""
Subclass of ``RegistrationForm`` which enforces uniqueness of
email addresses.
"""
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
email_field = User.get_email_field_name()
self.fields[email_field].validators.append(
validators.CaseInsensitiveUnique(
User, email_field, validators.DUPLICATE_EMAIL
)
)
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4337804
django-registration-3.3/src/django_registration/locale/ 0000755 0000767 0000024 00000000000 00000000000 022400 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4242094
django-registration-3.3/src/django_registration/locale/ar/ 0000755 0000767 0000024 00000000000 00000000000 023002 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4527535
django-registration-3.3/src/django_registration/locale/ar/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024567 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/ar/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000004127 00000000000 026372 0 ustar 00james staff x - y _ N 6 V ; ' )
* 8 A R g } 5 C Q 1 l : @ + l , " ( 2 ?
I have read and agree to the Terms of Service Registration using free email addresses is prohibited. Please supply a different email address. This email address is already in use. Please supply a different email address. This username is already taken. Please choose another. Usernames can only contain letters, numbers and underscores You must agree to the terms to register You must type the same password each time activation key email address password password (again) registration profile registration profiles user username Project-Id-Version: PACKAGE VERSION
Report-Msgid-Bugs-To:
POT-Creation-Date: 2007-09-19 19:30-0500
PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE
Last-Translator: FULL NAME
Language-Team: LANGUAGE
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
أقر بقراءة والموافقة على شروط الخدمة يمنع التسجيل باستخدام عناوين بريد الكترونية مجانية. يرجى تزويد عنوان بريد الكتروني مختلف. عنوان البريد الالكتروني مسجل مسبقا. يرجى تزويد عنوان بريد الكتروني مختلف. اسم المستخدم مسجل مسبقا. يرجى اختيار اسم اخر. يمكن أن يحتوي اسم المستخدم على احرف، ارقام وشرطات سطرية فقط يجب الموافقة على الشروط للتسجيل يجب ادخال كلمة المرور مطابقة كل مرة رمز التفعيل عنوان البريد الالكتروني كلمة المرور تأكيد كلمة المرور ملف التسجيل الشخصي ملفات التسجيل الشخصية مستخدم اسم المستخدم ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/ar/LC_MESSAGES/django.po 0000644 0000767 0000024 00000004743 00000000000 026401 0 ustar 00james staff # SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR , YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2007-09-19 19:30-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME \n"
"Language-Team: LANGUAGE \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: forms.py:38
msgid "username"
msgstr "اسم المستخدم"
#: forms.py:41
msgid "email address"
msgstr "عنوان البريد الالكتروني"
#: forms.py:43
msgid "password"
msgstr "كلمة المرور"
#: forms.py:45
msgid "password (again)"
msgstr "تأكيد كلمة المرور"
#: forms.py:54
msgid "Usernames can only contain letters, numbers and underscores"
msgstr "يمكن أن يحتوي اسم المستخدم على احرف، ارقام وشرطات سطرية فقط"
#: forms.py:59
msgid "This username is already taken. Please choose another."
msgstr "اسم المستخدم مسجل مسبقا. يرجى اختيار اسم اخر."
#: forms.py:68
msgid "You must type the same password each time"
msgstr "يجب ادخال كلمة المرور مطابقة كل مرة"
#: forms.py:96
msgid "I have read and agree to the Terms of Service"
msgstr "أقر بقراءة والموافقة على شروط الخدمة"
#: forms.py:105
msgid "You must agree to the terms to register"
msgstr "يجب الموافقة على الشروط للتسجيل"
#: forms.py:124
msgid ""
"This email address is already in use. Please supply a different email "
"address."
msgstr "عنوان البريد الالكتروني مسجل مسبقا. يرجى تزويد عنوان بريد الكتروني مختلف."
#: forms.py:149
msgid ""
"Registration using free email addresses is prohibited. Please supply a "
"different email address."
msgstr "يمنع التسجيل باستخدام عناوين بريد الكترونية مجانية. يرجى تزويد عنوان بريد الكتروني مختلف."
#: models.py:188
msgid "user"
msgstr "مستخدم"
#: models.py:189
msgid "activation key"
msgstr "رمز التفعيل"
#: models.py:194
msgid "registration profile"
msgstr "ملف التسجيل الشخصي"
#: models.py:195
msgid "registration profiles"
msgstr "ملفات التسجيل الشخصية"
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4246056
django-registration-3.3/src/django_registration/locale/bg/ 0000755 0000767 0000024 00000000000 00000000000 022770 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000033 00000000000 010211 x ustar 00 27 mtime=1653723062.453515
django-registration-3.3/src/django_registration/locale/bg/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024555 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/bg/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000004376 00000000000 026366 0 ustar 00james staff x - y _ N 6 V ; ' )
* 8 A R g } s b b y Z { h _ ; % C P ) p + "
I have read and agree to the Terms of Service Registration using free email addresses is prohibited. Please supply a different email address. This email address is already in use. Please supply a different email address. This username is already taken. Please choose another. Usernames can only contain letters, numbers and underscores You must agree to the terms to register You must type the same password each time activation key email address password password (again) registration profile registration profiles user username Project-Id-Version: PACKAGE VERSION
Report-Msgid-Bugs-To:
POT-Creation-Date: 2007-09-19 19:30-0500
PO-Revision-Date: 2008-03-05 12:37+0200
Last-Translator: Vladislav
Language-Team: LANGUAGE
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Poedit-Bookmarks: -1,-1,-1,-1,10,-1,-1,-1,-1,-1
Прочел съм и съм съгласен с условията за експлоатация Регистрациите с безплатни адреси е забранен. Моля въведете различен адрес за електронна поща Адреса на електронната поща е използван. Моля въведете друг адрес. Потребителското име е заето. Моля изберето друго. Потребителските имена могат да съдържат букви, цифри и подчертавки Трябва да сте съгласни с условията за да се регистрирате. Грешка при проверка на паролата. Ключ за активация Електронна поща Парола Парола (проверка) регистрационен профил регистрационни профили Потребител Потребителско име ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/bg/LC_MESSAGES/django.po 0000644 0000767 0000024 00000005172 00000000000 026364 0 ustar 00james staff # SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR , YEAR.
#
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2007-09-19 19:30-0500\n"
"PO-Revision-Date: 2008-03-05 12:37+0200\n"
"Last-Translator: Vladislav \n"
"Language-Team: LANGUAGE \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Poedit-Bookmarks: -1,-1,-1,-1,10,-1,-1,-1,-1,-1\n"
#: forms.py:38
msgid "username"
msgstr "Потребителско име "
#: forms.py:41
msgid "email address"
msgstr "Електронна поща"
#: forms.py:43
msgid "password"
msgstr "Парола"
#: forms.py:45
msgid "password (again)"
msgstr "Парола (проверка)"
#: forms.py:54
msgid "Usernames can only contain letters, numbers and underscores"
msgstr "Потребителските имена могат да съдържат букви, цифри и подчертавки"
#: forms.py:59
msgid "This username is already taken. Please choose another."
msgstr "Потребителското име е заето. Моля изберето друго."
#: forms.py:68
msgid "You must type the same password each time"
msgstr "Грешка при проверка на паролата."
#: forms.py:96
msgid "I have read and agree to the Terms of Service"
msgstr "Прочел съм и съм съгласен с условията за експлоатация"
#: forms.py:105
msgid "You must agree to the terms to register"
msgstr "Трябва да сте съгласни с условията за да се регистрирате."
#: forms.py:124
msgid "This email address is already in use. Please supply a different email address."
msgstr "Адреса на електронната поща е използван. Моля въведете друг адрес."
#: forms.py:149
msgid "Registration using free email addresses is prohibited. Please supply a different email address."
msgstr "Регистрациите с безплатни адреси е забранен. Моля въведете различен адрес за електронна поща"
#: models.py:188
msgid "user"
msgstr "Потребител"
#: models.py:189
msgid "activation key"
msgstr "Ключ за активация"
#: models.py:194
msgid "registration profile"
msgstr "регистрационен профил"
#: models.py:195
msgid "registration profiles"
msgstr "регистрационни профили"
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4249005
django-registration-3.3/src/django_registration/locale/ca/ 0000755 0000767 0000024 00000000000 00000000000 022763 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4543266
django-registration-3.3/src/django_registration/locale/ca/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024550 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/ca/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000003641 00000000000 026353 0 ustar 00james staff < ) - ( 9 _ S % N > ( g ' p j $ B g w 2 ~ ` , R P D > " a s
A user with that username already exists. Activate users E-mail I have read and agree to the Terms of Service Password Password (again) Re-send activation emails Registration using free email addresses is prohibited. Please supply a different email address. The two password fields didn't match. This email address is already in use. Please supply a different email address. This value must contain only letters, numbers and underscores. Username You must agree to the terms to register activation key registration profile registration profiles user Project-Id-Version: django-registration 0.8
Report-Msgid-Bugs-To:
POT-Creation-Date: 2011-07-17 11:04+0200
PO-Revision-Date: 2010-09-24 23:21+0100
Last-Translator: Carles Barrobés i Meix
Language-Team: Català
Language:
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Poedit-Language: Catalan
Ja existeix un usuari amb aquest nom Activar usuaris E-mail He llegit i estic d'acord amb les condicions d'ús Contrasenya Contrasenya (de nou) Re-enviar e-mails d'activació Està prohibit registrar-se utilitzant adreces d'e-mail gratuïtes. Sisplau entreu-ne una altra. Els dos camps de contrasenya no coincideixen Aquesta adreça d'e-mail ja està sent utilitzada. Sisplau, entreu-ne una altra. Aquest valor ha de contenir només lletres, números i guions baixos Nom d'usuari Heu d'estar d'acord amb les condicions d'ús per registrar-vos clau d'activació perfil de registre perfils de registre usuari ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/ca/LC_MESSAGES/django.po 0000644 0000767 0000024 00000004626 00000000000 026362 0 ustar 00james staff # Catalan translation for django-registration.
# Copyright (C) 2007-2010, James Bennet
# This file is distributed under the same license as the django-registration package.
# Carles Barrobés , 2010.
#
msgid ""
msgstr ""
"Project-Id-Version: django-registration 0.8\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-07-17 11:04+0200\n"
"PO-Revision-Date: 2010-09-24 23:21+0100\n"
"Last-Translator: Carles Barrobés i Meix \n"
"Language-Team: Català\n"
"Language: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Poedit-Language: Catalan\n"
#: admin.py:23
msgid "Activate users"
msgstr "Activar usuaris"
#: admin.py:43
msgid "Re-send activation emails"
msgstr "Re-enviar e-mails d'activació"
#: forms.py:35
msgid "Username"
msgstr "Nom d'usuari"
#: forms.py:36
msgid "This value must contain only letters, numbers and underscores."
msgstr "Aquest valor ha de contenir només lletres, números i guions baixos"
#: forms.py:39
msgid "E-mail"
msgstr "E-mail"
#: forms.py:41
msgid "Password"
msgstr "Contrasenya"
#: forms.py:43
msgid "Password (again)"
msgstr "Contrasenya (de nou)"
#: forms.py:55
msgid "A user with that username already exists."
msgstr "Ja existeix un usuari amb aquest nom"
#: forms.py:67
msgid "The two password fields didn't match."
msgstr "Els dos camps de contrasenya no coincideixen"
#: forms.py:78
msgid "I have read and agree to the Terms of Service"
msgstr "He llegit i estic d'acord amb les condicions d'ús"
#: forms.py:79
msgid "You must agree to the terms to register"
msgstr "Heu d'estar d'acord amb les condicions d'ús per registrar-vos"
#: forms.py:95
msgid ""
"This email address is already in use. Please supply a different email "
"address."
msgstr ""
"Aquesta adreça d'e-mail ja està sent utilitzada. Sisplau, entreu-ne una "
"altra."
#: forms.py:122
msgid ""
"Registration using free email addresses is prohibited. Please supply a "
"different email address."
msgstr ""
"Està prohibit registrar-se utilitzant adreces d'e-mail gratuïtes. Sisplau "
"entreu-ne una altra."
#: models.py:168
msgid "user"
msgstr "usuari"
#: models.py:169
msgid "activation key"
msgstr "clau d'activació"
#: models.py:174
msgid "registration profile"
msgstr "perfil de registre"
#: models.py:175
msgid "registration profiles"
msgstr "perfils de registre"
#~ msgid "Email address"
#~ msgstr "Adreça d'e-mail"
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4253423
django-registration-3.3/src/django_registration/locale/cs/ 0000755 0000767 0000024 00000000000 00000000000 023005 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4549284
django-registration-3.3/src/django_registration/locale/cs/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024572 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/cs/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000003653 00000000000 026400 0 ustar 00james staff < )
- & / @ _ Z % N > / ' n Q ) 0 Z o 4
! a N S m E F N a v
A user with that username already exists. Activate users Email address I have read and agree to the Terms of Service Password Password (again) Re-send activation emails Registration using free email addresses is prohibited. Please supply a different email address. The two password fields didn't match. This email address is already in use. Please supply a different email address. This value must contain only letters, numbers and underscores. You must agree to the terms to register activation key registration profile registration profiles user username Project-Id-Version: PACKAGE VERSION
Report-Msgid-Bugs-To:
POT-Creation-Date: 2009-10-12 14:09-0500
PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE
Last-Translator: Implayo s.r.o.
Language-Team: LANGUAGE
Language: cs
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Uživatel s tímto jménem již existuje. Aktivovat uživatele E-mailová adresa Přečetl jsem si a souhlasím s podmínkami služby Heslo Heslo (znovu) Znovu odeslat aktivační e-maily Používání volných e-mailových adres je zakázáno. Prosím zadejte jinou e-mailovou adresu. Zadaná 2 hesla se neshodují. Tato e-mailová adresa se již používá. Prosím zadejte jinou e-mailovou adresu. Tato hodnota může obsahovat pouze písmena, čísla a podtržítka. Musíte odsouhlasit podmínky služby pro pokračování v registraci. aktivační klíč registrační profil registrační profily uživatel uživatelské jméno ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/cs/LC_MESSAGES/django.po 0000644 0000767 0000024 00000004531 00000000000 026377 0 ustar 00james staff # SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR , 2011.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2009-10-12 14:09-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: Implayo s.r.o. \n"
"Language-Team: LANGUAGE \n"
"Language: cs\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: admin.py:23
msgid "Activate users"
msgstr "Aktivovat uživatele"
#: admin.py:43
msgid "Re-send activation emails"
msgstr "Znovu odeslat aktivační e-maily"
#: forms.py:35
msgid "username"
msgstr "uživatelské jméno"
#: forms.py:36
msgid "This value must contain only letters, numbers and underscores."
msgstr "Tato hodnota může obsahovat pouze písmena, čísla a podtržítka."
#: forms.py:39
msgid "Email address"
msgstr "E-mailová adresa"
#: forms.py:41
msgid "Password"
msgstr "Heslo"
#: forms.py:43
msgid "Password (again)"
msgstr "Heslo (znovu)"
#: forms.py:55
msgid "A user with that username already exists."
msgstr "Uživatel s tímto jménem již existuje."
#: forms.py:67
msgid "The two password fields didn't match."
msgstr "Zadaná 2 hesla se neshodují."
#: forms.py:78
msgid "I have read and agree to the Terms of Service"
msgstr "Přečetl jsem si a souhlasím s podmínkami služby"
#: forms.py:79
msgid "You must agree to the terms to register"
msgstr "Musíte odsouhlasit podmínky služby pro pokračování v registraci."
#: forms.py:95
msgid ""
"This email address is already in use. Please supply a different email "
"address."
msgstr ""
"Tato e-mailová adresa se již používá. Prosím zadejte jinou e-mailovou "
"adresu."
#: forms.py:122
msgid ""
"Registration using free email addresses is prohibited. Please supply a "
"different email address."
msgstr ""
"Používání volných e-mailových adres je zakázáno. Prosím zadejte "
"jinou e-mailovou adresu."
#: models.py:165
msgid "user"
msgstr "uživatel"
#: models.py:166
msgid "activation key"
msgstr "aktivační klíč"
#: models.py:171
msgid "registration profile"
msgstr "registrační profil"
#: models.py:172
msgid "registration profiles"
msgstr "registrační profily"
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4256532
django-registration-3.3/src/django_registration/locale/da/ 0000755 0000767 0000024 00000000000 00000000000 022764 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4557793
django-registration-3.3/src/django_registration/locale/da/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024551 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/da/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000003413 00000000000 026351 0 ustar 00james staff < )
- & / @ _ Z % N > / n ' w 3
+ ( 9 b k } Z @ 8 T
0
A user with that username already exists. Activate users Email address I have read and agree to the Terms of Service Password Password (again) Re-send activation emails Registration using free email addresses is prohibited. Please supply a different email address. The two password fields didn't match. This email address is already in use. Please supply a different email address. This value must contain only letters, numbers and underscores. Username You must agree to the terms to register activation key registration profile registration profiles user Project-Id-Version: django-registration 0.8
Report-Msgid-Bugs-To:
POT-Creation-Date:
PO-Revision-Date:
Last-Translator: Rune Bromer
Language-Team:
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Der findes allerede en bruger med dette brugernavn. Aktiver brugere E-mailadresse I har l¾st og accepterer betingelserne. Password Password (gentag) Gensend aktiveringsemails Registrering med gratis emailadresser er ikke muligt. V¾lg venligst en anden emailadresse De 2 passwordfelter er ikke ens. Denne emailadresse er allerede i brug. Benyt venligst en anden. V¾rdien m kun indeholde bogstaver, tal og underscore. Brugernavn Du skal acceptere betingelserne for at registere Aktiveringsn¿gle Registreringsprofil Registreringprofiler bruger ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/da/LC_MESSAGES/django.po 0000644 0000767 0000024 00000004264 00000000000 026361 0 ustar 00james staff # SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# Rune Bromer , 2007-2009.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: django-registration 0.8 \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: \n"
"PO-Revision-Date: \n"
"Last-Translator: Rune Bromer \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: admin.py:23
msgid "Activate users"
msgstr "Aktiver brugere"
#: admin.py:43
msgid "Re-send activation emails"
msgstr "Gensend aktiveringsemails"
#: forms.py:35
msgid "Username"
msgstr "Brugernavn"
#: forms.py:36
msgid "This value must contain only letters, numbers and underscores."
msgstr "V¾rdien m kun indeholde bogstaver, tal og underscore."
#: forms.py:39
msgid "Email address"
msgstr "E-mailadresse"
#: forms.py:41
msgid "Password"
msgstr "Password"
#: forms.py:43
msgid "Password (again)"
msgstr "Password (gentag)"
#: forms.py:55
msgid "A user with that username already exists."
msgstr "Der findes allerede en bruger med dette brugernavn."
#: forms.py:67
msgid "The two password fields didn't match."
msgstr "De 2 passwordfelter er ikke ens."
#: forms.py:78
msgid "I have read and agree to the Terms of Service"
msgstr "I har l¾st og accepterer betingelserne."
#: forms.py:79
msgid "You must agree to the terms to register"
msgstr "Du skal acceptere betingelserne for at registere"
#: forms.py:95
msgid ""
"This email address is already in use. Please supply a different email "
"address."
msgstr ""
"Denne emailadresse er allerede i brug. Benyt venligst en anden. "
#: forms.py:122
msgid ""
"Registration using free email addresses is prohibited. Please supply a "
"different email address."
msgstr ""
"Registrering med gratis emailadresser er ikke muligt. V¾lg venligst en "
"anden emailadresse"
#: models.py:165
msgid "user"
msgstr "bruger"
#: models.py:166
msgid "activation key"
msgstr "Aktiveringsn¿gle"
#: models.py:171
msgid "registration profile"
msgstr "Registreringsprofil"
#: models.py:172
msgid "registration profiles"
msgstr "Registreringprofiler"
././@PaxHeader 0000000 0000000 0000000 00000000033 00000000000 010211 x ustar 00 27 mtime=1653723062.425982
django-registration-3.3/src/django_registration/locale/de/ 0000755 0000767 0000024 00000000000 00000000000 022770 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4563468
django-registration-3.3/src/django_registration/locale/de/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024555 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/de/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000003717 00000000000 026364 0 ustar 00james staff < )
- & / @ _ Z % N > / n ' w F ) % O c ; r ! t , e W D / G <
A user with that username already exists. Activate users Email address I have read and agree to the Terms of Service Password Password (again) Re-send activation emails Registration using free email addresses is prohibited. Please supply a different email address. The two password fields didn't match. This email address is already in use. Please supply a different email address. This value must contain only letters, numbers and underscores. Username You must agree to the terms to register activation key registration profile registration profiles user Project-Id-Version: django-registration 0.8
Report-Msgid-Bugs-To:
POT-Creation-Date: 2009-10-18 21:32+0200
PO-Revision-Date: 2007-09-29 16:50+0200
Last-Translator: Jannis Leidel
Language-Team: Deutsch
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Dieser Benutzername ist bereits vergeben. Benutzer aktivieren E-Mail-Adresse Ich habe die Nutzungsvereinbarung gelesen und stimme ihr zu Passwort Passwort (wiederholen) Aktivierungs-E-Mail erneut senden Die Registrierung mit einer kostenlosen E-Mail-Adresse ist untersagt. Bitte geben Sie eine andere E-Mail-Adresse an. Die beiden Passwörter sind nicht identisch. Diese E-Mail-Adresse wird schon genutzt. Bitte geben Sie eine andere E-Mail-Adresse an. Dieser Wert darf nur Buchstaben, Ziffern und Unterstriche enthalten. Benutzername Sie müssen der Nutzungsvereinbarung zustimmen, um sich zu registrieren Aktivierungsschlüssel Registrierungsprofil Registrierungsprofile Benutzer ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/de/LC_MESSAGES/django.po 0000644 0000767 0000024 00000004572 00000000000 026367 0 ustar 00james staff # SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# Jannis Leidel , 2007-2009.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: django-registration 0.8 \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2009-10-18 21:32+0200\n"
"PO-Revision-Date: 2007-09-29 16:50+0200\n"
"Last-Translator: Jannis Leidel \n"
"Language-Team: Deutsch \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: admin.py:23
msgid "Activate users"
msgstr "Benutzer aktivieren"
#: admin.py:43
msgid "Re-send activation emails"
msgstr "Aktivierungs-E-Mail erneut senden"
#: forms.py:35
msgid "Username"
msgstr "Benutzername"
#: forms.py:36
msgid "This value must contain only letters, numbers and underscores."
msgstr "Dieser Wert darf nur Buchstaben, Ziffern und Unterstriche enthalten."
#: forms.py:39
msgid "Email address"
msgstr "E-Mail-Adresse"
#: forms.py:41
msgid "Password"
msgstr "Passwort"
#: forms.py:43
msgid "Password (again)"
msgstr "Passwort (wiederholen)"
#: forms.py:55
msgid "A user with that username already exists."
msgstr "Dieser Benutzername ist bereits vergeben."
#: forms.py:67
msgid "The two password fields didn't match."
msgstr "Die beiden Passwörter sind nicht identisch."
#: forms.py:78
msgid "I have read and agree to the Terms of Service"
msgstr "Ich habe die Nutzungsvereinbarung gelesen und stimme ihr zu"
#: forms.py:79
msgid "You must agree to the terms to register"
msgstr "Sie müssen der Nutzungsvereinbarung zustimmen, um sich zu registrieren"
#: forms.py:95
msgid ""
"This email address is already in use. Please supply a different email "
"address."
msgstr ""
"Diese E-Mail-Adresse wird schon genutzt. Bitte geben Sie eine andere E-Mail-"
"Adresse an."
#: forms.py:122
msgid ""
"Registration using free email addresses is prohibited. Please supply a "
"different email address."
msgstr ""
"Die Registrierung mit einer kostenlosen E-Mail-Adresse ist untersagt. Bitte "
"geben Sie eine andere E-Mail-Adresse an."
#: models.py:165
msgid "user"
msgstr "Benutzer"
#: models.py:166
msgid "activation key"
msgstr "Aktivierungsschlüssel"
#: models.py:171
msgid "registration profile"
msgstr "Registrierungsprofil"
#: models.py:172
msgid "registration profiles"
msgstr "Registrierungsprofile"
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4262803
django-registration-3.3/src/django_registration/locale/el/ 0000755 0000767 0000024 00000000000 00000000000 023000 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000033 00000000000 010211 x ustar 00 27 mtime=1653723062.457074
django-registration-3.3/src/django_registration/locale/el/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024565 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/el/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000004570 00000000000 026372 0 ustar 00james staff x - y _ N 6 V ; ' )
* 8 A R g } 5 W b Y ' o D ! 3 Q `
I have read and agree to the Terms of Service Registration using free email addresses is prohibited. Please supply a different email address. This email address is already in use. Please supply a different email address. This username is already taken. Please choose another. Usernames can only contain letters, numbers and underscores You must agree to the terms to register You must type the same password each time activation key email address password password (again) registration profile registration profiles user username Project-Id-Version: PACKAGE VERSION
Report-Msgid-Bugs-To:
POT-Creation-Date: 2007-09-19 19:30-0500
PO-Revision-Date: 2007-11-14 21:50+0200
Last-Translator: FULL NAME
Language-Team: LANGUAGE
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Διάβασα και συμφωνώ με τους Όρους της Υπηρεσίας Η εγγραφή μέσω δωρεάν διευθύνσεων ηλεκτρονικού ταχυδρομείου απαγορεύεται. Παρακαλώ δώστε κάποια άλλη. Η συγκεκριμένη διεύθυνση ηλεκτρονικού ταχυδρομείου χρησιμοποιείται ήδη. Παρακαλώ δώστε κάποια άλλη. Αυτό το όνομα χρήστη χρησιμοποίειται ήδη. Παρακαλώ διαλέξτε ένα άλλο. Τα ονόματα χρηστών μπορούν να περιλαμβάνουν μόνο γράμματα, αριθμούς και υπογραμμίσεις Πρέπει να συμφωνείται με τους όρους για να εγγραφείτε Πρέπει να εισάγετε το ίδιο συνθηματικό κάθε φορά κλειδί ενεργοποίησης διεύθυνση ηλεκτρονικού ταχυδρομείου συνθηματικό συνθηματικό (ξανά) προφίλ εγγραφής προφίλ εγγραφών χρήστης όνομα χρήστη ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/el/LC_MESSAGES/django.po 0000644 0000767 0000024 00000005436 00000000000 026377 0 ustar 00james staff # SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# Panos Laganakos , 2007.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2007-09-19 19:30-0500\n"
"PO-Revision-Date: 2007-11-14 21:50+0200\n"
"Last-Translator: FULL NAME \n"
"Language-Team: LANGUAGE \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: forms.py:38
msgid "username"
msgstr "όνομα χρήστη"
#: forms.py:41
msgid "email address"
msgstr "διεύθυνση ηλεκτρονικού ταχυδρομείου"
#: forms.py:43
msgid "password"
msgstr "συνθηματικό"
#: forms.py:45
msgid "password (again)"
msgstr "συνθηματικό (ξανά)"
#: forms.py:54
msgid "Usernames can only contain letters, numbers and underscores"
msgstr "Τα ονόματα χρηστών μπορούν να περιλαμβάνουν μόνο γράμματα, αριθμούς και υπογραμμίσεις"
#: forms.py:59
msgid "This username is already taken. Please choose another."
msgstr "Αυτό το όνομα χρήστη χρησιμοποίειται ήδη. Παρακαλώ διαλέξτε ένα άλλο."
#: forms.py:68
msgid "You must type the same password each time"
msgstr "Πρέπει να εισάγετε το ίδιο συνθηματικό κάθε φορά"
#: forms.py:96
msgid "I have read and agree to the Terms of Service"
msgstr "Διάβασα και συμφωνώ με τους Όρους της Υπηρεσίας"
#: forms.py:105
msgid "You must agree to the terms to register"
msgstr "Πρέπει να συμφωνείται με τους όρους για να εγγραφείτε"
#: forms.py:124
msgid ""
"This email address is already in use. Please supply a different email "
"address."
msgstr ""
"Η συγκεκριμένη διεύθυνση ηλεκτρονικού ταχυδρομείου χρησιμοποιείται ήδη. "
"Παρακαλώ δώστε κάποια άλλη."
#: forms.py:149
msgid ""
"Registration using free email addresses is prohibited. Please supply a "
"different email address."
msgstr ""
"Η εγγραφή μέσω δωρεάν διευθύνσεων ηλεκτρονικού ταχυδρομείου απαγορεύεται. ""Παρακαλώ δώστε κάποια άλλη."
#: models.py:188
msgid "user"
msgstr "χρήστης"
#: models.py:189
msgid "activation key"
msgstr "κλειδί ενεργοποίησης"
#: models.py:194
msgid "registration profile"
msgstr "προφίλ εγγραφής"
#: models.py:195
msgid "registration profiles"
msgstr "προφίλ εγγραφών"
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4266484
django-registration-3.3/src/django_registration/locale/en/ 0000755 0000767 0000024 00000000000 00000000000 023002 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4576514
django-registration-3.3/src/django_registration/locale/en/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024567 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/en/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000000557 00000000000 026375 0 ustar 00james staff $ , 8 5 9 Project-Id-Version: PACKAGE VERSION
Report-Msgid-Bugs-To:
POT-Creation-Date: 2009-10-12 14:09-0500
PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE
Last-Translator: FULL NAME
Language-Team: LANGUAGE
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/en/LC_MESSAGES/django.po 0000644 0000767 0000024 00000003271 00000000000 026374 0 ustar 00james staff # SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR , YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2009-10-12 14:09-0500\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME \n"
"Language-Team: LANGUAGE \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: admin.py:23
msgid "Activate users"
msgstr ""
#: admin.py:43
msgid "Re-send activation emails"
msgstr ""
#: forms.py:35
msgid "username"
msgstr ""
#: forms.py:36
msgid "This value must contain only letters, numbers and underscores."
msgstr ""
#: forms.py:39
msgid "Email address"
msgstr ""
#: forms.py:41
msgid "Password"
msgstr ""
#: forms.py:43
msgid "Password (again)"
msgstr ""
#: forms.py:55
msgid "A user with that username already exists."
msgstr ""
#: forms.py:67
msgid "The two password fields didn't match."
msgstr ""
#: forms.py:78
msgid "I have read and agree to the Terms of Service"
msgstr ""
#: forms.py:79
msgid "You must agree to the terms to register"
msgstr ""
#: forms.py:95
msgid ""
"This email address is already in use. Please supply a different email "
"address."
msgstr ""
#: forms.py:122
msgid ""
"Registration using free email addresses is prohibited. Please supply a "
"different email address."
msgstr ""
#: models.py:165
msgid "user"
msgstr ""
#: models.py:166
msgid "activation key"
msgstr ""
#: models.py:171
msgid "registration profile"
msgstr ""
#: models.py:172
msgid "registration profiles"
msgstr ""
././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4269307
django-registration-3.3/src/django_registration/locale/es/ 0000755 0000767 0000024 00000000000 00000000000 023007 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4584212
django-registration-3.3/src/django_registration/locale/es/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 024574 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/es/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000003635 00000000000 026402 0 ustar 00james staff x - y _ N 6 V ; ' )
* 8 A R g } { , v 4 b > N M 1 3 8 D [ n
I have read and agree to the Terms of Service Registration using free email addresses is prohibited. Please supply a different email address. This email address is already in use. Please supply a different email address. This username is already taken. Please choose another. Usernames can only contain letters, numbers and underscores You must agree to the terms to register You must type the same password each time activation key email address password password (again) registration profile registration profiles user username Project-Id-Version: django-registration 0.3
Report-Msgid-Bugs-To:
POT-Creation-Date: 2008-03-11 00:19-0400
PO-Revision-Date: 2017-06-01 11:06-0400
Last-Translator: Ernesto Rico Schmidt
Language-Team: Español
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Language: es
X-Generator: Poedit 1.8.12
He leído y acepto los términos de servicio El registro usando una dirección de correo electrónico gratis está prohibido.Por favor proporciona otra dirección. La dirección de correo electrónico ya está siendo usada. Por favor proporciona otra dirección. Este nombre de usuario ya está ocupado. Por favor escoge otro Los nombres de usuarios sólo pueden contener letras, números y guiones bajos Tienes que aceptar los términos para registrarte Tienes que introducir la misma contraseña cada vez clave de activación dirección de coreo electrónico contraseña contraseña (otra vez) perfil de registro perfiles de registro usuario nombre de usuario ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1600671777.0
django-registration-3.3/src/django_registration/locale/es/LC_MESSAGES/django.po 0000644 0000767 0000024 00000004517 00000000000 026405 0 ustar 00james staff # Spanish translation for django-registration.
# Copyright (C) 2007, James Bennet
# This file is distributed under the same license as the registration package.
# Ernesto Rico Schmidt , 2008.
#
msgid ""
msgstr ""
"Project-Id-Version: django-registration 0.3\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2008-03-11 00:19-0400\n"
"PO-Revision-Date: 2017-06-01 11:06-0400\n"
"Last-Translator: Ernesto Rico Schmidt \n"
"Language-Team: Español \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: es\n"
"X-Generator: Poedit 1.8.12\n"
#: forms.py:38
msgid "username"
msgstr "nombre de usuario"
#: forms.py:41
msgid "email address"
msgstr "dirección de correo electrónico"
#: forms.py:43
msgid "password"
msgstr "contraseña"
#: forms.py:45
msgid "password (again)"
msgstr "contraseña (otra vez)"
#: forms.py:54
msgid "Usernames can only contain letters, numbers and underscores"
msgstr "Los nombres de usuario sólo pueden contener letras, números y guiones bajos"
#: forms.py:59
msgid "This username is already taken. Please choose another."
msgstr "Este nombre de usuario ya está ocupado. Por favor escoge otro"
#: forms.py:71
msgid "You must type the same password each time"
msgstr "Tienes que introducir la misma contraseña cada vez"
#: forms.py:100
msgid "I have read and agree to the Terms of Service"
msgstr "He leído y acepto los términos de servicio"
#: forms.py:109
msgid "You must agree to the terms to register"
msgstr "Tienes que aceptar los términos para registrarte"
#: forms.py:128
msgid ""
"This email address is already in use. Please supply a different email address."
msgstr ""
"La dirección de correo electrónico ya está siendo usada. Por favor proporciona "
"otra dirección."
#: forms.py:153
msgid ""
"Registration using free email addresses is prohibited. Please supply a different "
"email address."
msgstr ""
"El registro usando una dirección de correo electrónico gratis está prohibido. Por "
"favor proporciona otra dirección."
#: models.py:188
msgid "user"
msgstr "usuario"
#: models.py:189
msgid "activation key"
msgstr "clave de activación"
#: models.py:194
msgid "registration profile"
msgstr "perfil de registro"
#: models.py:195
msgid "registration profiles"
msgstr "perfiles de registro"
././@PaxHeader 0000000 0000000 0000000 00000000033 00000000000 010211 x ustar 00 27 mtime=1653723062.427165
django-registration-3.3/src/django_registration/locale/es_AR/ 0000755 0000767 0000024 00000000000 00000000000 023371 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000034 00000000000 010212 x ustar 00 28 mtime=1653723062.4590087
django-registration-3.3/src/django_registration/locale/es_AR/LC_MESSAGES/ 0000755 0000767 0000024 00000000000 00000000000 025156 5 ustar 00james staff ././@PaxHeader 0000000 0000000 0000000 00000000026 00000000000 010213 x ustar 00 22 mtime=1535893229.0
django-registration-3.3/src/django_registration/locale/es_AR/LC_MESSAGES/django.mo 0000644 0000767 0000024 00000003471 00000000000 026762 0 ustar 00james staff x - y _ N 6 V ; ' )
* 8 A R g } 5 <