diff options
author | Dries Buytaert <dries@buytaert.net> | 2001-03-07 21:29:40 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2001-03-07 21:29:40 +0000 |
commit | f516626a293edd613cb823db88e36dcf7e1fb8f4 (patch) | |
tree | ba3dd7432d4d13783e34fbc50a4d4308a142309b /modules/watchdog/watchdog.module | |
parent | 2b2e81f6cfce285f466c3c74cb25ad30c581d2cf (diff) | |
download | brdo-f516626a293edd613cb823db88e36dcf7e1fb8f4.tar.gz brdo-f516626a293edd613cb823db88e36dcf7e1fb8f4.tar.bz2 |
A rather large and important update:
revised most of the SQL queries and tried to make drupal as secure as possible (while trying to avoid redundant/duplicate checks). For drupal's sake, try to screw something up. See the mail about PHPNuke being hacked appr. 6 days ago. The one who finds a problem is rewarded a beer (and I'm willing to ship it to Norway if required). I beg you to be evil. Try dumping a table a la "http://localhost/index.php?date=77778;DROP TABLE users" or something. ;)
Diffstat (limited to 'modules/watchdog/watchdog.module')
-rw-r--r-- | modules/watchdog/watchdog.module | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/watchdog/watchdog.module b/modules/watchdog/watchdog.module index f30ac4864..13908e39d 100644 --- a/modules/watchdog/watchdog.module +++ b/modules/watchdog/watchdog.module @@ -53,7 +53,7 @@ function watchdog_display($order = "date") { } function watchdog_view($id) { - $result = db_query("SELECT l.*, u.userid FROM watchdog l LEFT JOIN users u ON l.user = u.id WHERE l.id = $id"); + $result = db_query("SELECT l.*, u.userid FROM watchdog l LEFT JOIN users u ON l.user = u.id WHERE l.id = '$id'"); if ($watchdog = db_fetch_object($result)) { $output .= "<TABLE BORDER=\"1\" CELLPADDING=\"3\" CELLSPACING=\"0\">\n"; @@ -78,10 +78,10 @@ function watchdog_admin() { watchdog_help(); break; case "view": - watchdog_view($id); + watchdog_view(check_input($id)); break; case "Update": - watchdog_display($order); + watchdog_display(check_input($order)); break; default: watchdog_display(); |