Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
djangorestframework-recaptcha
Readme
.. image:: https://badge.fury.io/py/djangorestframework-recaptcha.svg :target: https://badge.fury.io/py/djangorestframework-recaptcha
.. image:: https://travis-ci.org/Maximilien-R/django-rest-framework-recaptcha.svg?branch=master :target: https://travis-ci.org/Maximilien-R/django-rest-framework-recaptcha
.. image:: https://coveralls.io/repos/github/Maximilien-R/django-rest-framework-recaptcha/badge.svg?branch=master :target: https://coveralls.io/github/Maximilien-R/django-rest-framework-recaptcha?branch=master
.. image:: https://readthedocs.org/projects/django-rest-framework-recaptcha/badge/?version=latest :target: https://django-rest-framework-recaptcha.readthedocs.io/en/latest/?badge=latest :alt: Documentation Status
Django REST framework reCAPTCHA provides you a serializer field to handle and validate Google reCAPTCHA response.
The full documentation is at https://django-rest-framework-recaptcha.readthedocs.io.
To install Django REST framework reCAPTCHA, run this command in your terminal:
.. code-block:: console
$ pip install djangorestframework-recaptcha
This is the preferred method to install Django REST framework reCAPTCHA, as it will always install the most recent stable release.
If you don't have pip
_ installed, this Python installation guide
_ can guide
you through the process.
.. _pip: https://pip.pypa.io .. _Python installation guide: http://docs.python-guide.org/en/latest/starting/installation/
Once the djangorestframework-recaptcha
installed, add it to your
INSTALLED_APPS
:
.. code-block:: python
INSTALLED_APPS = (
...
"rest_framework_recaptcha",
...
)
Next, register yourself and obtain your reCAPTCHA credentials at https://www.google.com/recaptcha/admin.
Finally, copy/paste your Google reCAPTCHA secret key to the
DRF_RECAPTCHA_SECRET_KEY
setting:
.. code-block:: python
DRF_RECAPTCHA_SECRET_KEY = "<your_reCAPTCHA_secret_key>"
To use Django REST framework reCAPTCHA within your project you'll need to
import and add the ReCaptchaField
serializer field into the wanted
serializer. For example:
.. code-block:: python
from rest_framework import serializers
from rest_framework_recaptcha import ReCaptchaField
class MySerializer(serializers.Serializer):
recaptcha = ReCaptchaField()
Added
* Django REST framework 3.9, Python 3.7 & Django 2.1.
* Set long description content type to reStructuredText.
0.1.0 (2018-07-02)
------------------
Added
FAQs
reCAPTCHA field for Django REST framework serializers.
We found that djangorestframework-recaptcha demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.