Passed
Push — 1.10.x ( 51b3f0...0b3bd8 )
by Yannick
116:33 queued 61:35
created
main/auth/external_login/facebook.init.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -22,5 +22,5 @@
 block discarded – undo
22 22
  * See facebook section of the auth.conf.php file
23 23
  */
24 24
 
25
-require_once dirname(__FILE__) . '/../../../app/config/auth.conf.php';
25
+require_once dirname(__FILE__).'/../../../app/config/auth.conf.php';
26 26
 
Please login to merge, or discard this patch.
main/auth/external_login/login.ws.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -14,7 +14,7 @@  discard block
 block discarded – undo
14 14
 $wsUrl = '';
15 15
 
16 16
 // include common authentication functions
17
-require_once dirname(__FILE__) . '/functions.inc.php';
17
+require_once dirname(__FILE__).'/functions.inc.php';
18 18
 // call the login checker (defined below)
19 19
 $isValid = loginWSAuthenticate($login, $password, $wsUrl);
20 20
 
@@ -61,8 +61,8 @@  discard block
 block discarded – undo
61 61
     $key = '-+*%$({[]})$%*+-';
62 62
     // Complete password con PKCS7-specific padding
63 63
     $blockSize = 16;
64
-    $padding = $blockSize - (strlen($password)%$blockSize);
65
-    $password .= str_repeat(chr($padding),$padding);
64
+    $padding = $blockSize - (strlen($password) % $blockSize);
65
+    $password .= str_repeat(chr($padding), $padding);
66 66
     $cipher = new Crypt_AES(CRYPT_AES_MODE_CFB);
67 67
     $cipher->setKeyLength(128);
68 68
     $cipher->setKey($key);
Please login to merge, or discard this patch.
main/auth/external_login/updateUser.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -7,7 +7,7 @@  discard block
 block discarded – undo
7 7
 
8 8
 use ChamiloSession as Session;
9 9
 
10
-require_once(dirname(__FILE__) . '/functions.inc.php');
10
+require_once(dirname(__FILE__).'/functions.inc.php');
11 11
 
12 12
 //MAIN CODE
13 13
 //$uData variable is set in local.inc.php
@@ -36,6 +36,6 @@  discard block
 block discarded – undo
36 36
     //User cannot login
37 37
     $loginFailed = true;
38 38
     Session::erase('_uid');
39
-    header('Location: ' . api_get_path(WEB_PATH) . 'index.php?loginFailed=1&error=user_password_incorrect');
39
+    header('Location: '.api_get_path(WEB_PATH).'index.php?loginFailed=1&error=user_password_incorrect');
40 40
     exit;
41 41
 }
Please login to merge, or discard this patch.
main/auth/external_login/newUser.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@
 block discarded – undo
10 10
 
11 11
 use ChamiloSession as Session;
12 12
 
13
-require_once(dirname(__FILE__) . '/functions.inc.php');
13
+require_once(dirname(__FILE__).'/functions.inc.php');
14 14
 
15 15
 //MAIN CODE
16 16
 //$login and $password variables are setted in main/inc/local.inc.php
Please login to merge, or discard this patch.
main/auth/external_login/ldap_import_all_users.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -13,9 +13,9 @@
 block discarded – undo
13 13
 }
14 14
 use \ChamiloSession as Session;
15 15
 
16
-require dirname(__FILE__) . '/../../inc/global.inc.php';
17
-require dirname(__FILE__) . '/ldap.inc.php';
18
-require dirname(__FILE__) . '/../../inc/conf/auth.conf.php';
16
+require dirname(__FILE__).'/../../inc/global.inc.php';
17
+require dirname(__FILE__).'/ldap.inc.php';
18
+require dirname(__FILE__).'/../../inc/conf/auth.conf.php';
19 19
 /**
20 20
  * Code execution
21 21
  */
Please login to merge, or discard this patch.
main/auth/external_login/newUser.ldap.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -39,8 +39,8 @@
 block discarded – undo
39 39
 
40 40
 use ChamiloSession as Session;
41 41
 
42
-require_once dirname(__FILE__) . '/ldap.inc.php';
43
-require_once dirname(__FILE__) . '/functions.inc.php';
42
+require_once dirname(__FILE__).'/ldap.inc.php';
43
+require_once dirname(__FILE__).'/functions.inc.php';
44 44
 
45 45
 $ldap_user = extldap_authenticate($login, $password);
46 46
 if ($ldap_user !== false) {
Please login to merge, or discard this patch.
main/auth/external_login/ldap.inc.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -303,7 +303,7 @@
 block discarded – undo
303 303
 
304 304
     // TODO the password, if encrypted at the source, will be encrypted twice, which makes it useless. Try to fix that.
305 305
     $passwordKey = isset($extldap_user_correspondance['password']) ? $extldap_user_correspondance['password'] : 'userPassword';
306
-    $password        = $data[$passwordKey][0];
306
+    $password = $data[$passwordKey][0];
307 307
 
308 308
     // To ease management, we add the step-year (etape-annee) code
309 309
     //$official_code = $etape."-".$annee;
Please login to merge, or discard this patch.
main/auth/external_login/functions.inc.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
     //Those are the mandatory fields for user creation.
21 21
     //See external_add_user function for all the fields you can have.
22 22
     $table = USERINFO_TABLE;
23
-    $sql = "SELECT * from $table where username='" . Database::escape_string($login) . "'";
23
+    $sql = "SELECT * from $table where username='".Database::escape_string($login)."'";
24 24
     $result = Database::query($sql);
25 25
 
26 26
     if (Database::num_rows($result) == 0) { //false password
Please login to merge, or discard this patch.
main/auth/ldap/login.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
 	$loginFailed = false;
32 32
 	$uidReset = true;
33 33
 	$_user['user_id'] = $uData['user_id'];
34
-	Session::write('_uid',$_uid);
34
+	Session::write('_uid', $_uid);
35 35
     // Jand: copied from event_login in events.lib.php to enable login statistics:
36 36
 	Event::event_login($uData['user_id']);
37 37
 } else {
Please login to merge, or discard this patch.