Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
lolo888
ISPConfig 3
Commits
035e7dd7
Commit
035e7dd7
authored
Apr 23, 2008
by
tbrehm
Browse files
Removed the auto increment value for server table.
Fixed a bug in password encryption function.
parent
d4c9b31f
Changes
2
Hide whitespace changes
Inline
Side-by-side
install/sql/ispconfig3.sql
View file @
035e7dd7
...
...
@@ -487,7 +487,7 @@ CREATE TABLE `server` (
`updated`
tinyint
(
4
)
NOT
NULL
default
'0'
,
`active`
tinyint
(
4
)
NOT
NULL
default
'1'
,
PRIMARY
KEY
(
`server_id`
)
)
ENGINE
=
MyISAM
DEFAULT
CHARSET
=
latin1
AUTO_INCREMENT
=
3
;
)
ENGINE
=
MyISAM
DEFAULT
CHARSET
=
latin1
;
--
-- Daten fr Tabelle `server`
...
...
interface/lib/classes/tform.inc.php
View file @
035e7dd7
...
...
@@ -693,7 +693,7 @@ class tform {
$sql_insert_key
.
=
"`
$key
`, "
;
if
(
$field
[
'encryption'
]
==
'CRYPT'
)
{
$salt
=
"$1$"
;
for
(
$n
=
0
;
$n
<
8
;
$n
++
)
{
for
(
$n
=
0
;
$n
<
11
;
$n
++
)
{
$salt
.
=
chr
(
mt_rand
(
64
,
126
));
}
$salt
.
=
"$"
;
...
...
@@ -702,7 +702,7 @@ class tform {
}
else
{
$record
[
$key
]
=
md5
(
$record
[
$key
]);
}
$sql_insert_val
.
=
"'"
.
$record
[
$key
]
.
"', "
;
$sql_insert_val
.
=
"'"
.
addslashes
(
$record
[
$key
]
)
.
"', "
;
}
elseif
(
$field
[
'formtype'
]
==
'CHECKBOX'
)
{
$sql_insert_key
.
=
"`
$key
`, "
;
if
(
$record
[
$key
]
==
''
)
{
...
...
@@ -720,7 +720,7 @@ class tform {
if
(
$field
[
'formtype'
]
==
'PASSWORD'
)
{
if
(
isset
(
$field
[
'encryption'
])
&&
$field
[
'encryption'
]
==
'CRYPT'
)
{
$salt
=
"$1$"
;
for
(
$n
=
0
;
$n
<
8
;
$n
++
)
{
for
(
$n
=
0
;
$n
<
11
;
$n
++
)
{
$salt
.
=
chr
(
mt_rand
(
64
,
126
));
}
$salt
.
=
"$"
;
...
...
@@ -729,7 +729,7 @@ class tform {
}
else
{
$record
[
$key
]
=
md5
(
$record
[
$key
]);
}
$sql_update
.
=
"`
$key
` = '"
.
$record
[
$key
]
.
"', "
;
$sql_update
.
=
"`
$key
` = '"
.
addslashes
(
$record
[
$key
]
)
.
"', "
;
}
elseif
(
$field
[
'formtype'
]
==
'CHECKBOX'
)
{
if
(
$record
[
$key
]
==
''
)
{
// if a checkbox is not set, we set it to the unchecked value
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment