Changeset 5926


Ignore:
Timestamp:
04/12/12 10:05:37 (9 years ago)
Author:
cristiano
Message:

Ticket #2615 - Corrigido carregamento session com https ativo

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/login.php

    r5812 r5926  
    4545                } 
    4646                         
    47                 $GLOBALS['phpgw']->session = CreateObject('phpgwapi.sessions'); 
     47                $GLOBALS['phpgw']->session = CreateObject('phpgwapi.sessions');  
     48                 
    4849        } 
    4950        else 
     
    5152                Header('Location: setup/index.php'); 
    5253                exit; 
     54        } 
     55                 
     56        if($_POST) 
     57        { 
     58            $accountInfo = $GLOBALS['phpgw']->accounts->read_repository(); 
     59            session_id( $_COOKIE[ 'sessionid' ] );  
     60            session_start(); 
     61             
     62            //Carregando na sessão configurações do usuario usado na nova API.   
     63            $_SESSION['wallet']['user']['uid']            =  $accountInfo['account_lid']; 
     64            $_SESSION['wallet']['user']['uidNumber']      =  $accountInfo['account_id']; 
     65            $_SESSION['wallet']['user']['password']       =  $_POST['passwd']; 
     66            $_SESSION['wallet']['user']['cn']             =  $accountInfo['firstname'].' '.$accountInfo['lastname']; 
     67            $_SESSION['wallet']['user']['mail']           =  $accountInfo['email']; 
     68 
     69            $_SESSION['wallet']['Sieve']['user']          =  $accountInfo['account_lid']; 
     70            $_SESSION['wallet']['Sieve']['password']      =  $_POST['passwd']; 
     71 
     72            $_SESSION['wallet']['Cyrus']['user']          =  $accountInfo['account_lid']; 
     73            $_SESSION['wallet']['Cyrus']['password']      =  $_POST['passwd']; 
     74 
    5375        } 
    5476         
     
    124146                        session_start(); 
    125147                } 
    126                  
     148                                                 
    127149                include(personalize_include_path('phpgwapi','login')); 
    128         } 
    129             //Carregando na sessão configurações do usuario usado na nova API. 
    130             $_SESSION['wallet']['user']['uid']            =  $GLOBALS['phpgw_info']['user']['userid']; 
    131             $_SESSION['wallet']['user']['uidNumber']      =  $GLOBALS['phpgw_info']['user']['account_id']; 
    132             $_SESSION['wallet']['user']['password']       =  $GLOBALS['phpgw_info']['user']['passwd']; 
    133             $_SESSION['wallet']['user']['cn']             =  $GLOBALS['phpgw_info']['user']['firstname'].' '.$GLOBALS['phpgw_info']['user']['lastname']; 
    134             $_SESSION['wallet']['user']['mail']           =  $GLOBALS['phpgw_info']['user']['email']; 
    135      
    136             $_SESSION['wallet']['Sieve']['user']          =  $GLOBALS['phpgw_info']['user']['account_lid']; 
    137             $_SESSION['wallet']['Sieve']['password']      =  $GLOBALS['phpgw_info']['user']['passwd']; 
    138  
    139             $_SESSION['wallet']['Cyrus']['user']          =  $GLOBALS['phpgw_info']['user']['account_lid']; 
    140             $_SESSION['wallet']['Cyrus']['password']      =  $GLOBALS['phpgw_info']['user']['passwd']; 
    141              
    142              
    143             $_SESSION['wallet']['PostgreSQL']['user']     = $GLOBALS['phpgw_info']['server']['db_user']; 
    144             $_SESSION['wallet']['PostgreSQL']['password'] = $GLOBALS['phpgw_info']['server']['db_pass']; 
    145             $_SESSION['wallet']['PostgreSQL']['dbname']   = $GLOBALS['phpgw_info']['server']['db_name']; 
    146             $_SESSION['wallet']['PostgreSQL']['host']     = $GLOBALS['phpgw_info']['server']['db_host']; 
    147              
    148             $_SESSION['wallet']['OpenLDAP']['context']   =  $GLOBALS['phpgw_info']['server']['ldap_context']; 
    149             $_SESSION['wallet']['OpenLDAP']['host']      =  $GLOBALS['phpgw_info']['server']['ldap_host']; 
     150        }    
    150151             
    151152?> 
Note: See TracChangeset for help on using the changeset viewer.