| Anonymous | Login | Signup for a new account | 2010-09-09 15:19 UTC |
| Main | My View | View Issues | Change Log | Roadmap |
| Viewing Issue Simple Details [ Jump to Notes ] | [ View Advanced ] [ Issue History ] [ Print ] | ||||||
| ID | Category | Severity | Reproducibility | Date Submitted | Last Update | ||
| 0001225 | [SysCP] General | trivial | always | 2009-04-16 23:51 | 2009-04-17 08:15 | ||
| Reporter | dhr | View Status | public | ||||
| Assigned To | Flo | ||||||
| Priority | normal | Resolution | fixed | ||||
| Status | resolved | Product Version | |||||
| Summary | 0001225: on customer creation user home gets saved to mysql with duplicate trailling slash | ||||||
| Description |
Whenever a customer is created, the home directory gets saved to the ftp_users table with a duplicate trailling slash. Upon editing, php code adds a trailling slash to the home if the path was entered without. Later on, another one gets appended by the sql query. I suggest to change the latter: admin_customers.php:675 from $result = $db->query("INSERT INTO `" . TABLE_FTP_USERS . "` " . "(`customerid`, `username`, `password`, `homedir`, `login_enabled`, `uid`, `gid`) " . "VALUES ('" . (int)$customerid . "', '" . $db->escape($loginname) . "', ENCRYPT('" . $db->escape($password) . "'), '" . $db->escape($documentroot) . "/', 'y', '" . (int)$guid . "', '" . (int)$guid . "')"); to $result = $db->query("INSERT INTO `" . TABLE_FTP_USERS . "` " . "(`customerid`, `username`, `password`, `homedir`, `login_enabled`, `uid`, `gid`) " . "VALUES ('" . (int)$customerid . "', '" . $db->escape($loginname) . "', ENCRYPT('" . $db->escape($password) . "'), '" . $db->escape($documentroot) . "', 'y', '" . (int)$guid . "', '" . (int)$guid . "')"); |
||||||
| Additional Information | |||||||
| Tags | No tags attached. | ||||||
| Attached Files | |||||||
|
|
|||||||
Notes |
|
|
(0000372) monotek (reporter) 2009-04-17 07:38 |
Duplicate: https://bugs.syscp.org/view.php?id=1019 [^] |
SVN - commits |
|
|
(#2710) flo 2009-04-17 08:14 |
Removing trailing slash from query in admin_customers where the default ftp user gets added, fixes #1225
U trunk/syscp/admin_customers.php
|