Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

Rev 238 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 238 Rev 1323
Línea 92... Línea 92...
92
        if(!$device) {
92
        if(!$device) {
93
            return new Result(Result::FAILURE_IDENTITY_NOT_FOUND, null, ['ERROR_DEVICE_NOT_FOUND']);
93
            return new Result(Result::FAILURE_IDENTITY_NOT_FOUND, null, ['ERROR_DEVICE_NOT_FOUND']);
94
        }
94
        }
Línea -... Línea 95...
-
 
95
        
-
 
96
        
-
 
97
        if(!$device->user_id) {
-
 
98
            return new Result(Result::FAILURE_IDENTITY_NOT_FOUND, null, ['ERROR_DEVICE_SESSION_NOT_FOUND']);
-
 
99
        }
95
        
100
        
96
        
101
        
Línea 97... Línea 102...
97
        $userMapper = UserMapper::getInstance($this->adapter);
102
        $userMapper = UserMapper::getInstance($this->adapter);
98
        $user = $userMapper->fetchOne($device->user_id);
103
        $user = $userMapper->fetchOne($device->user_id);
Línea 125... Línea 130...
125
        if($t >= $t1 && $t <= $t2) {
130
        if($t >= $t1 && $t <= $t2) {
126
            return new Result(Result::FAILURE_UNCATEGORIZED, null, ['ERROR_WEBSERVICE_TIMESTAMP']);
131
            return new Result(Result::FAILURE_UNCATEGORIZED, null, ['ERROR_WEBSERVICE_TIMESTAMP']);
127
        }*/
132
        }*/
Línea 128... Línea -...
128
     
-
 
129
        
-
 
130
        error_log('device token = ' . $device->id);
-
 
131
        error_log('device password = ' . $device->password);
-
 
132
        error_log('request timestamp = ' . $this->timestamp);
-
 
-
 
133
     
-
 
134
        
Línea 133... Línea 135...
133
        error_log('request rand = ' . $this->rand);
135
       
Línea 134... Línea 136...
134
        error_log('request password = ' . $this->password);
136
 
135
        
137
        
Línea 136... Línea 138...
136
        
138
        
-
 
139
        $passworVerification = md5($device->password . ':' . $this->timestamp . ':'  . $this->rand);
Línea 137... Línea 140...
137
        $passworVerification = md5($device->password . ':' . $this->timestamp . ':'  . $this->rand);
140
        
138
        
141
 
Línea 139... Línea 142...
139
 
142
        if($this->password != $passworVerification) 
-
 
143
        {
Línea 140... Línea 144...
140
        if($this->password != $passworVerification) 
144
                
141
        {
145
            error_log("token : {$device->id}  timestamp : {$this->timestamp} rand : {$this->rand} password : {$this->password} ERR password verificacion : {$passworVerification}"  );
142
                
146