Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /*
- * Alpha Evolution
- * File: login.php - v0.0.2
- * Author: HellFireAE - HellFireAE@gmail.com
- * Reqested POST: u=millsjm&p=millsjm&ep=false&m=0&ver=3600
- */
- require(__DIR__ .'\config.inc.php');
- if(!$_POST){
- die();
- }
- $sign = array(
- 'User' => array(
- 'Username' => $MySQLi->real_escape_string($_POST['u']),
- 'Password' => $MySQLi->real_escape_string($_POST['p'])
- ),
- 'Config' => array(
- 'Version' => $MySQLi->real_escape_string($_POST['ver'])
- )
- );
- $getUserQuery = $MySQLi->query("SELECT * FROM users WHERE Username = '{$sign['User']['Username']}' LIMIT 1");
- $getUserCount = $getUserQuery->num_rows;
- if($getUserCount > 0){
- $getPassQuery = $MySQLi->query("SELECT * FROM users WHERE Username = '{$sign['User']['Username']}' AND Password = '{$sign['User']['Password']}' LIMIT 1");
- $getPassCount = $getPassQuery->num_rows;
- if($getPassCount > 0){
- $user = $getPassQuery->fetch_assoc();
- $getCharQuery = $MySQLi->query("SELECT * FROM characters WHERE UserID = '{$user['id']}' ORDER BY id ASC LIMIT 5") or die();
- /* User Information */
- sendVar('id', $user['id']);
- sendVar('idLore_Users', 1);
- sendVar('strEmail', $user['Email']);
- sendVar('userpass', $user['Password']);
- sendVar('aaa', $user['Age']);
- sendVar('ccc', $user['Security Code']);
- sendVar('intCanEmail', $user['Allow Email']);
- sendVar('intHits', 0);
- /* Character Information */
- $i = 1;
- while($char = $getCharQuery->fetch_assoc() and $i <= $getCharQuery->num_rows){
- sendVar("char{$i}", $char['Name']);
- sendVar("level{$i}", $char['Level']);
- sendVar("turns{$i}", 1);
- sendVar("id{$i}", $char['id']);
- sendVar("CharType{$i}", 'Adventurer');
- sendVar("intCharType{$i}", 0);
- sendVar("FaceFileName{$i}", 'anime/'.$char['Hair Filename']);
- sendVar("FaceColors{$i}", '0xFFCC99,0xFF9966,0x663300,0x330000,0x663300');
- sendVar("LastSeen{$i}", $char['Last Seen']);
- $i++;
- }
- sendVar('numchars', $getCharQuery->num_rows);
- /* Send Status */
- sendVar('status', 'success');
- sendVar('stupidsoftware', 'CAFIREWALL');
- $MySQL->close;
- exit;
- } else {
- sendVar('status', 'badpassword');
- sendVar('stupidsoftware', 'CAFIREWALL');
- exit;
- }
- } else {
- sendVar('status', 'usernotfound');
- sendVar('stupidsoftware', 'CAFIREWALL');
- exit;
- }
Add Comment
Please, Sign In to add comment