Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use slumber as the loop back service. It should always be authenticated. #8

Open
jsaytoe opened this issue Apr 30, 2013 · 1 comment

Comments

@jsaytoe
Copy link
Contributor

jsaytoe commented Apr 30, 2013

If i use slumber as loop back service and i have a model that contains RemoteForeignKey that point to a model in the slumber service. Then slumber should recognize it come from itself so it should alway be authenticated.

@KayEss
Copy link
Member

KayEss commented May 1, 2013

The work around for this is to create a user who is active, has the same name as the service name and whose password field contains the same values as the SECRET_KEY setting. I've not tried this, but this sort of thing should do it:

from django.contrib.auth.models import User
from django.conf import settings

User.objects.create(username=settings.SLUMBER_SERVICE, password=settings.SECRET_KEY, is_active=True)

With this user there'll be the required user in the system for Slumber to use to authenticate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants