Re: request.META['REMOTE_USER'] with django runserver

2014-09-24 Thread Tom Evans
rMiddleware(object): def process_request(self, request): request.META['REMOTE_USER'] = 'bob' Cheers Tom -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails

Re: request.META['REMOTE_USER'] with django runserver

2014-09-23 Thread Jürgen Kofler
Hi, you can add 'django.contrib.auth.backends.ModelBackend' to the AUTHENTICATION_BACKENDS and use a local user. or if you like to use the "REMOTE_USER" set up nginx with auth_basic and proxy on your local instance: location / { auth_basic "Restricted"; auth_basic_user_fil

request.META['REMOTE_USER'] with django runserver

2014-09-22 Thread Robbie Edwards
Hi, On my production server, I'm using REMOTE_USER to provide SSO for an internal service. It works great on the production server. However, when running 'runserver' on the development side, this variable is not set so authentic

Re: request.META['REMOTE_USER']

2009-10-14 Thread Daniel Roseman
On Oct 14, 10:39 am, luca72 wrote: > Thanks but have you got idea why i get this error, request.user return > the correct value, but for my understanding also the META > ['REMOTE_USER'] has to give the same value. No, that's not true, and the documentation doesn't say it does. The values in META

Re: request.META['REMOTE_USER']

2009-10-14 Thread robin nanola
OTE_USER'] has to give the same value. > > On 14 Ott, 11:34, robin nanola wrote: > > try request.user > > > > you get a key error coz there is no 'REMOTE_USER' key in META. > > > > On Wed, Oct 14, 2009 at 5:29 PM, luca72 wrote: > > > >

Re: request.META['REMOTE_USER']

2009-10-14 Thread Bayuadji
hi, imho request.user.is_authenticated and request.user.is_anonymous -djibon- On 10/14/09, robin nanola wrote: > try request.user > > you get a key error coz there is no 'REMOTE_USER' key in META. > > On Wed, Oct 14, 2009 at 5:29 PM, luca72 wrote: > >&

Re: request.META['REMOTE_USER']

2009-10-14 Thread luca72
#x27;REMOTE_USER' key in META. > > On Wed, Oct 14, 2009 at 5:29 PM, luca72 wrote: > > > Hello if i use request.META['REMOTE_USER'] i get key error, but if i > > use 'REMOTE_HOST' not > > can you tell me how to get the user that is authentic

Re: request.META['REMOTE_USER']

2009-10-14 Thread Tom Evans
On Wed, 2009-10-14 at 02:29 -0700, luca72 wrote: > Hello if i use request.META['REMOTE_USER'] i get key error, but if i > use 'REMOTE_HOST' not > can you tell me how to get the user that is authenticate > I use the decorator @login_required and so the user is authe

Re: request.META['REMOTE_USER']

2009-10-14 Thread robin nanola
try request.user you get a key error coz there is no 'REMOTE_USER' key in META. On Wed, Oct 14, 2009 at 5:29 PM, luca72 wrote: > > Hello if i use request.META['REMOTE_USER'] i get key error, but if i > use 'REMOTE_HOST' not > can you tell me how to

Re: request.META['REMOTE_USER']

2009-10-14 Thread Daniel Roseman
On Oct 14, 10:29 am, luca72 wrote: > Hello if i use request.META['REMOTE_USER'] i get key error, but if i > use 'REMOTE_HOST' not > can you tell me how to get the user that is authenticate > I use the decorator @login_required and so the user is authenticated

request.META['REMOTE_USER']

2009-10-14 Thread luca72
Hello if i use request.META['REMOTE_USER'] i get key error, but if i use 'REMOTE_HOST' not can you tell me how to get the user that is authenticate I use the decorator @login_required and so the user is authenticated cor