# django_authopenid

Author : BenoƮt Chesneau <> Url : [](

Updated version of this doc is always here :


## Introduction

Django authentification application with openid using django auth contrib.

This application allow a user to connect to you website with :

  • legacy account : username/password
  • openid url

Idee is having workflow to integrate openid and _legacy_ authentification.

If the user connect with an openid he could associate it with its legaccy account or just create a new django account. When the user is connected you could manage him like you usually do with auth contrib or [django-registration](

## Requirements

## Set your django project

To use django_authopenid add django_authopenid.middleware.OpenIDMiddleware to MIDDLEWARE_CLASSES and
'django_authopenid' to INSTALLED_APP.

then add django_authopenid.urls to, for example :

(r'^account/', include('django_authopenid.urls')),

so all django_authopenid view will be available under account/ path.

Set also your LOGIN_URL in to something like this:

ugettext = lambda s: s LOGIN_URL = '/%s%s' % (ugettext('account/'), ugettext('signin/'))

To install tables, run :

python syncdb

## Use it

### Urls

all code is documented so you could esayly know what do a view.

  • signin/signup :
  • /account/signin : go to signin page
  • /account/signout : signout url
  • /account/signin/complete/ : register openid after signin
  • /account/signup : legacy authentification
  • /account/sendpw/password : send a new password

### Templates

Templates are in templates/authopenid folder :

  • complete.html : complete page after signin (register openid)
  • signin.html : signin page