The MPADQ admin area uses a simple username/password login form backed by a MySQLDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/ijmeisner/einerlei/llms.txt
Use this file to discover all available pages before exploring further.
admins table. Passwords are stored as MD5 hashes, sessions are tracked with PHP’s native $_SESSION, and every protected page verifies the session on every request. This page explains the full authentication lifecycle — from the initial login through session management and credential updates.
Login Page
The login form lives at/admin/ (served by admin/index.php). It presents two fields — username (labelled “email” in the placeholder) and password — plus a Login button and a separate Recover Password link.
Submitting the form POSTs credentials to /admin/dashboard/authenticate.php.
How Authentication Works
authenticate.php performs the following steps:
- Reads
$_POST["username"]and$_POST["password"]. - Hashes the submitted password with MD5:
hash("md5", $logPassword). - Queries the
adminstable for the row matching the submitted username. - Compares the stored MD5 hash to the computed hash.
- On match: starts a PHP session, sets
$_SESSION["loggedin"] = true, and redirects to/admin/dashboard/. - On mismatch: redirects back to
/admin/with no error message (the form simply reloads).
Login Flow
Enter credentials
Type your username into the email field and your password into the
password field.
Server validates credentials
authenticate.php hashes the submitted password with MD5 and compares it
to the hash stored in the admins table. If the credentials are incorrect
you are redirected back to /admin/ to try again.Credentials Storage
Credentials are stored in theadmins table of the Quiz MySQL database:
Default Credentials
The SQL seed file inserts one default administrator record:098f6bcd4621d373cade4e832627b4f6 is the MD5 digest of the string test.
MD5 is a fast, cryptographically broken hashing algorithm that is no longer
considered secure for password storage. For production deployments, consider
migrating password storage to PHP’s
password_hash() / password_verify()
functions, which use bcrypt or Argon2 and are specifically designed for
credential hashing. If you upgrade the hashing algorithm, update both
authenticate.php and authenticatePass.php to use the new functions and
re-hash any existing stored passwords.Session Verification
Every page inside/admin/dashboard/ starts with an identical session guard:
Logging Out
Visiting/admin/dashboard/logout.php destroys the session completely:
/admin/.
Changing the Admin Password
Navigate to Change Admin Password at/admin/dashboard/change-password/.
Open the Change Password page
From the dashboard, click Change Admin Password. The form asks for your
current password and the new password (entered twice for confirmation).
Fill in all three fields
Enter your current password, your new password, and re-enter the
new password in the confirmation field.
Submit the form
Click Continue. The form POSTs to
admin/dashboard/change-password/changePassword/authenticatePass.php.Server validates the change
The script checks that the two new-password fields match, that the new
password differs from the old password, and that the current password
hashes correctly against the database record. Validation failures redirect
you back to the form with an error message.
Updating the Admin Email
Navigate to Update Email at/admin/dashboard/update-email/.
Enter the new email address (formatted as user@isp.com) and click Update Email. The form POSTs to /admin/dashboard/update-email/confirm/. This is the address used for login recovery and system notifications.