Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>There's no good reason to store the password (or the hashed password, if that's what you are doing) in the session. Passwords are <em>secret</em>. You should be very careful about how you handle other people's secrets.</p> <p>Storing the unique name (or email) is sufficient to determine that a user is logged in.</p> <p>Some other problems I spotted:</p> <ul> <li>Password field in the top login form is not "password" type. Allows shoulder-surfing.</li> <li>There is no need to use <code>mysql_real_escape_string()</code> if you have hashed the password. Hashing the password should be the first thing you do after receiving it.</li> <li>On the account page, you have used a "password" type field for the <em>Security Answer</em> but you have pre-filled the field with the value. This is available in the HTML source. Yours is <code>12345</code>.</li> <li>You still have <code>display_errors</code> set to true in your <code>php.ini</code>.</li> <li>No SSL. All the passwords will be sent unencrypted across your College network.</li> <li>Your question doesn't mention <code>bcrypt</code> but it should. BCrypt is an appropriate password hashing algorithm. (PHP calls this CRYPT_BLOWFISH).</li> <li>The use of <code>mysql_real_escape_string()</code> indicates that you are not using prepared statements and binding parameters. Doing so makes SQL injection impossible. Switch to <code>mysqli</code> or PDO.</li> </ul> <p>I didn't attempt any unusual POST requests to your service but I noticed that you have a bunch of fields that have editing disabled in the HTML. This doesn't actually prevent anything. I can submit that form with a different Student ID. Does the receiving PHP handle that case?</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload