Skip to content

Commit cc4f64a

Browse files
committed
1 parent 77c16c1 commit cc4f64a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

interface/lib/classes/tform.inc.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -672,7 +672,7 @@ function getSQL($record, $tab, $action = 'INSERT', $primary_id = 0, $sql_ext_whe
672672
if($field['formtype'] == 'PASSWORD') {
673673
$sql_insert_key .= "`$key`, ";
674674
if($field['encryption'] == 'CRYPT') {
675-
$sql_insert_val .= "'".crypt($record[$key])."', ";
675+
$sql_insert_val .= "encrypt('".$record[$key]."'), ";
676676
} else {
677677
$sql_insert_val .= "md5('".$record[$key]."'), ";
678678
}
@@ -690,7 +690,7 @@ function getSQL($record, $tab, $action = 'INSERT', $primary_id = 0, $sql_ext_whe
690690
} else {
691691
if($field['formtype'] == 'PASSWORD') {
692692
if($field['encryption'] == 'CRYPT') {
693-
$sql_update .= "`$key` = '".crypt($record[$key])."', ";
693+
$sql_update .= "`$key` = encrypt('".$record[$key]."'), ";
694694
} else {
695695
$sql_update .= "`$key` = md5('".$record[$key]."'), ";
696696
}

0 commit comments

Comments
 (0)