Show
Ignore:
Timestamp:
02/14/06 09:51:16 (3 years ago)
Author:
mbonetti
Message:

Some more fixes for possible sql injections

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/rss/admin/users.php

    r1181 r1275  
    2828 
    2929function set_admin_pass($uname=null,$pass=null) { 
     30    $sql = "select count(*) from " . getTable('users') 
     31        ." where password != '' and ulevel >=99"; 
     32    list($adminexists) = rss_fetch_row(rss_query($sql)); 
     33    if ($adminexists) { 
     34        die('Oops. Admin already exists!'); 
     35    } 
     36     
    3037    if ($uname && $pass) { 
    3138        rss_query( "update " . getTable('users') . " set uname='$uname', "