django-rest-auth

Google Sign-in in Android with django-rest-auth

倾然丶 夕夏残阳落幕 提交于 2021-01-27 07:37:28
问题 I've been trying to add Google Sign-In in Android but have a couple of doubts. From the Android documentation Integrate google sign in android In the server side authentication part Client Id is required which is OAuth 2.0 web application client ID for your backend server. From android's documentation: Get your backend server's OAuth 2.0 client ID If your app authenticates with a backend server or accesses Google APIs from your backend server, you must get the OAuth 2.0 client ID that was

Google Sign-in in Android with django-rest-auth

和自甴很熟 提交于 2021-01-27 07:34:52
问题 I've been trying to add Google Sign-In in Android but have a couple of doubts. From the Android documentation Integrate google sign in android In the server side authentication part Client Id is required which is OAuth 2.0 web application client ID for your backend server. From android's documentation: Get your backend server's OAuth 2.0 client ID If your app authenticates with a backend server or accesses Google APIs from your backend server, you must get the OAuth 2.0 client ID that was

django rest auth email validation

我是研究僧i 提交于 2021-01-20 20:15:56
问题 Can someone explain how to set up email verification for django rest auth ? My settings.py contains: EMAIL_BACKEND = 'django.core.mail.backends.console.EmailBackend' ACCOUNT_EMAIL_VERIFICATION = 'mandatory' ACCOUNT_AUTHENTICATION_METHOD = 'email' ACCOUNT_EMAIL_REQUIRED = True ACCOUNT_USERNAME_REQUIRED = False And I've added this line in my urls.py: url(r'^accounts/', include('allauth.urls')), But when I register with this endpoint: rest-auth/registration/ , the email is not sent, but the user

Django-rest-auth (dj-rest-auth) custom user registration

拜拜、爱过 提交于 2021-01-02 03:29:19
问题 I'm using dj-rest-auth (https://dj-rest-auth.readthedocs.io/en/latest/) and trying to implement a custom registration form. When I'm trying to register a new user I have the base form. I've seen with the older version (https://django-rest-auth.readthedocs.io/en/latest/) that if you use password1 and password2, you don't have to retype all the code. serializers.py from rest_framework import serializers from dj_rest_auth.registration.serializers import RegisterSerializer class

Django-rest-auth (dj-rest-auth) custom user registration

断了今生、忘了曾经 提交于 2021-01-02 03:28:43
问题 I'm using dj-rest-auth (https://dj-rest-auth.readthedocs.io/en/latest/) and trying to implement a custom registration form. When I'm trying to register a new user I have the base form. I've seen with the older version (https://django-rest-auth.readthedocs.io/en/latest/) that if you use password1 and password2, you don't have to retype all the code. serializers.py from rest_framework import serializers from dj_rest_auth.registration.serializers import RegisterSerializer class

How to test email confirmation?

你离开我真会死。 提交于 2020-12-15 08:41:30
问题 I'm trying to make a test for the email confirmation view with django-rest-auth. Here is what I have: def test_verify_email(self): # Verify email address username = 'userTest' payload = { 'email': 'test@example.com', 'password1': 'TestpassUltra1', 'password2': 'TestpassUltra1', 'username': username, } res = self.client.post(REGISTER_USER_URL, payload) self.assertEqual(res.status_code, status.HTTP_201_CREATED) user = get_user_model().objects.get(email='test@example.com') # TODO retrieve the

ImproperlyConfigured at /rest-auth/registration/account-confirm-email

梦想与她 提交于 2020-12-08 06:28:25
问题 I'm using django-rest-auth for user signup and verify email. I'm able to successfully send the email when a user signs up. Howvever, on email verification, I'm getting this error with the following traceback: File "/Library/Python/2.7/site-packages/django/core/handlers/base.py" in get_response 111. response = wrapped_callback(request, *callback_args, **callback_kwargs) File "/Library/Python/2.7/site-packages/django/views/generic/base.py" in view 69. return self.dispatch(request, *args, *

ImproperlyConfigured at /rest-auth/registration/account-confirm-email

自闭症网瘾萝莉.ら 提交于 2020-12-08 06:27:49
问题 I'm using django-rest-auth for user signup and verify email. I'm able to successfully send the email when a user signs up. Howvever, on email verification, I'm getting this error with the following traceback: File "/Library/Python/2.7/site-packages/django/core/handlers/base.py" in get_response 111. response = wrapped_callback(request, *callback_args, **callback_kwargs) File "/Library/Python/2.7/site-packages/django/views/generic/base.py" in view 69. return self.dispatch(request, *args, *

Django-rest-auth use cookie instead of Authorization header

让人想犯罪 __ 提交于 2020-11-30 12:01:34
问题 I want to build the SPA application using Django Rest Framework as a back-end. The application will use Token authentication. For maximum security, I want to store the authentication token inside of httpOnly cookie, so it will not be accessible from javascript. However, because the cookie is not accessible from the javascript, I am not able to set the 'Authorization: Token ...' header. So, my question is, can I make the DRF auth system (or Django-Rest-Knox/Django-Rest-JWT) to read the