multi-device-login
Application to manage user session across multiple devices.
Django application to manage user session across multi device/machine login. User will not be allowed to login using multiple devices or browser if he is already logged in to system.
- Manage user's login
- Token Fetch REST API
- Permission class to manage API based login
Quick start
pip install multi-device-login
-
Add
multidevice
to yourINSTALLED_APPS
setting:INSTALLED_APPS = ( ... 'multidevice', )
-
Include the multidevice URLs to a path of your choice
patterns = ('', ... url(r'^api/device/', include('multidevice.apiurls')), )
-
Include multidevice middleware in settings base
MIDDLEWARE_CLASSES = ( 'django.contrib.sessions.middleware.SessionMiddleware', ... 'django.contrib.auth.middleware.AuthenticationMiddleware', 'multidevice.middleware.SingleDeviceLoginMiddleware', ... )
Requirements
- Python (2.6.5+, 2.7,)
- Django (1.5.5+, 1.6, 1.7, 1.8)
- Django REST framework (2.3.8+)
Bugs & Contributions
Please report bugs by opening an issue
Contributions are welcome and are encouraged!