public boolean passwordMatches(String user, String pass) {
		if (!accountExists(user)) return false;
		
		ResultSet rs;
		try {

			String query = "SELECT password, salt from users WHERE username = \"" + user + "\"";
			rs = stmt.executeQuery(query);

			rs.next();
			String hash = rs.getString("password");
			String salt = rs.getString("salt");
			return passHash(salt + pass).equals(hash);
				
		} catch (SQLException e) {
			e.printStackTrace();
		}
		return false;
	}