Thanks for checking, Massimo.  I'll start looking into the web server.

David


On Sep 18, 2012, at 1:30 PM, Massimo Di Pierro <massimo.dipie...@gmail.com> 
wrote:

> This confirms my impression. This is not a web2py 2.0.x issue. Something else 
> has changed. env.wsgi_url_scheme and env.https are from the WSGI environment. 
> HTTPS is not defined and WSGI_URL_SCHEME is http. 
> 
> I am suing web2py 2.0.9 with apache and I get 
> 
> request.env.wsgi_url_scheme: https
> request.env.https: 1
> 
> Massimo
> 
> On Tuesday, 18 September 2012 10:50:55 UTC-5, David Phillips wrote:
> Sure.
> 
> [Tue Sep 18 15:49:25 2012] [error] WARNING:root:request.env.wsgi_url_scheme: 
> http
> [Tue Sep 18 15:49:25 2012] [error] WARNING:root:request.env.https: None
> 
> 
> On Sep 18, 2012, at 10:40 AM, Massimo Di Pierro <massimo....@gmail.com> wrote:
> 
>> Can you please print the values of
>> 
>> request.env.wsgi_url_scheme  and request.env.https
>> 
>> It will help me understand what is going on. I do not think we changed the 
>> request.is_https behavior. web2py my not be able to detect https if behind a 
>> proxy.
>> 
>> Massimo
>> 
>> On Tuesday, 18 September 2012 10:27:34 UTC-5, David Phillips wrote:
>> Thanks to everyone for their replies. Bruno, that is a neat trick.
>> 
>> Unfortunately, it didn't solve my problem. I generated a new password and 
>> restarted the apache server, but I am seeing the same behavior -- 
>> request.is_https is returning false even though I am using https and I 
>> cannot use the admin interface.
>> 
>> This is harder to solve because https access works locally. It's only on the 
>> production apache server (on Elastic Beanstalk) that it fails.
>> 
>> Can anyone suggest a strategy to find the cause? A quick survey of the gluon 
>> code didn't turn up any obvious place to look.
>> 
>> Thanks.
>> 
>> David
>> 
>> 
>> 
>> On Monday, September 17, 2012 4:18:34 PM UTC-5, Richard wrote:
>> This is nicer way of restoring it :)
>> 
>> Thanks Bruno!
>> 
>> Richard
>> 
>> On Mon, Sep 17, 2012 at 3:50 PM, Bruno Rocha <rocha...@gmail.com> wrote:
>> assuming your webserver user is www-data and desired password 123456
>> 
>> cd path/to/web2py
>> 
>> sudo -u www-data python -c "from gluon.main import save_password; 
>> save_password('123456',443)"
>> 
>> -- 
>>  
>>  
>>  
>> 
>> 
>> -- 
>>  
>>  
>>  
> 
> 
> -- 
>  
>  
>  

-- 



Reply via email to