Subversion Repositories ALCASAR

Rev

Rev 325 | Rev 509 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 325 Rev 508
Line 15... Line 15...
15
$op_val2 = '';
15
$op_val2 = '';
16
$link = @da_sql_pconnect($config);
16
$link = @da_sql_pconnect($config);
17
if ($link){
17
if ($link){
18
	if (is_file("../lib/crypt/$config[general_encryption_method].php")){
18
	if (is_file("../lib/crypt/$config[general_encryption_method].php")){
19
		include("../lib/crypt/$config[general_encryption_method].php");
19
		include("../lib/crypt/$config[general_encryption_method].php");
-
 
20
		/*Ajout en vue de l'impression des données*/
-
 
21
		$passwd_imp = $passwd;
-
 
22
		/*Fin Ajout*/
20
		$passwd = da_encrypt($passwd);
23
		$passwd = da_encrypt($passwd);
21
		$passwd = da_sql_escape_string($passwd);
24
		$passwd = da_sql_escape_string($passwd);
22
		$res = @da_sql_query($link,$config,
25
		$res = @da_sql_query($link,$config,
23
		"INSERT INTO $config[sql_check_table] (attribute,value,username $text)
26
		"INSERT INTO $config[sql_check_table] (attribute,value,username $text)
24
		VALUES ('$config[sql_password_attribute]','$passwd','$login' $passwd_op);");
27
		VALUES ('$config[sql_password_attribute]','$passwd','$login' $passwd_op);");
Line 88... Line 91...
88
				else if ($attr_type["$key"] == 'replyItem'){
91
				else if ($attr_type["$key"] == 'replyItem'){
89
					$table = "$config[sql_reply_table]";
92
					$table = "$config[sql_reply_table]";
90
					$type = 2;
93
					$type = 2;
91
				}
94
				}
92
				$val = $$attrmap["$key"];
95
				$val = $$attrmap["$key"];
-
 
96
				/*Ajout en vue de l'impression des données*/
-
 
97
				if($key == "Session-Timeout") $sto_imp = $val;
-
 
98
				if($key == "Max-Daily-Session") $mds_imp = $val;
-
 
99
				if($key == "Max-Monthly-Session") $mms_imp = $val;
-
 
100
				/*Fin Ajout*/
93
				$val = da_sql_escape_string($val);
101
				$val = da_sql_escape_string($val);
94
				$op_name = $attrmap["$key"] . '_op';
102
				$op_name = $attrmap["$key"] . '_op';
95
				$op_val = $$op_name;
103
				$op_val = $$op_name;
96
				if ($op_val != ''){
104
				if ($op_val != ''){
97
					$op_val = da_sql_escape_string($op_val);
105
					$op_val = da_sql_escape_string($op_val);
98
					if (check_operator($op_val,$type) == -1){
106
					if (check_operator($op_val,$type) == -1){
99
						echo "<b>Invalid operator ($op_val) for attribute $key</b><br>\n";
107
						echo "<b>Invalid operator ($op_val) for attribute $key</b><br>\n";
100
						coninue;
108
						continue;
101
					}
109
					}
102
					$op_val2 = ",'$op_val'";
110
					$op_val2 = ",'$op_val'";
103
				}
111
				}
104
				if ($val == '' || check_defaults($val,$op_val,$default_vals["$key"]))
112
				if ($val == '' || check_defaults($val,$op_val,$default_vals["$key"]))
105
					continue;
113
					continue;