Got you;

I see; so I have to configure Apache to pop the auth box and then pass it to my web2py app.

Sorry I mis-understood what was supposed to happen.

I always was under the impression that if you visited a page that used basic auth; it would force the borwser to pop a box for authentication.

But this concept is different.

This concept lets you pass user:[email protected] and provides auth based on those values.

I need to do the former; so I guess I will revert back to Apache.

Thanks.



On 5/23/11 11:44 AM, Massimo Di Pierro wrote:
No. You neer get a box because that is for Apache basic auth.

If you do

if request.function == 'stream':
      auth.settings.allow_basic_login = True
@auth.requires_login()
def stream():
       stream = 'http://mystream...'
       return dict(stream=stream)

you get the usual web2py login page. If username and password are
already in the URL (basic auth)

http://username:[email protected]:8000/..../stream

then you do not get prompted. You never get the popup. That is ugly.







On May 23, 10:36 am, "David J."<[email protected]>  wrote:
Strange I tried that;

my controller is default.py

if request.function == 'stream':
      auth.settings.allow_basic_login = True

def stream():
       stream = 'http://mystream...'
       return dict(stream=stream)

but when I visit

http://mydomain.com/stream

I get the stream url; I would have thought I would have got a Basic
Authentication box.

Perhaps I need to upgrade my version; I am running 1.95.1

On 5/23/11 11:25 AM, Massimo Di Pierro wrote:







if request.function=='stream':
      auth.settings.allow_basic_login = True

Reply via email to