Jump to content

junx

Members
  • Posts

    88
  • Joined

  • Last visited

  • Days Won

    2

junx last won the day on April 9 2011

junx had the most liked content!

Contact Methods

  • Website URL
    http://junx.tk

Profile Information

  • Gender
    Not Telling
  • Location
    US

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

junx's Achievements

Newbie

Newbie (1/14)

8

Reputation

  1. junx

    Password Changer

    add $query = "UPDATE account SET v = '0' WHERE username = '".$account."'"; $result = mysql_query($query) or die(mysql_error()); $query = "UPDATE account SET s = '0' WHERE username = '".$account."'"; $result = mysql_query($query) or die(mysql_error()); after $query = "UPDATE account SET sha_pass_hash = '".$enewpass."' WHERE username = '".$account."'"; $result = mysql_query($query) or die(mysql_error()); there is probably a cleaner way to do this but i really dont know.
  2. Hi. ty for ur pass changer script. pls answer this:

  3. $characters = ""; //where your wow characters database is, most likely characters or char $auth = ""; //where your wow accounts database is, most likely auth 'db_name_realm'=> 'realmd', //looks like your wow accounts database.., again most like auth
  4. Very nice but I got the following errors when I tried to use the register. I edited the config.php correctly and ran it on my XAMPP server. Maybe someone else can confirm so I know it's not just me. Also going to add the script I use. (Even more) Minimalistic Found and copied from another forum. Forgot who made it. I take no credit. Added & fix a few things. You can change all the '3' to your specific minimal username length. (Be careful if you use Find and Replace.) You can change all the '5' to your specific minimal password length. (Be careful if you use Find and Replace.) <?php $host = "localhost"; //Your servers IP address $port = "3306"; //Your servers port $user = "root"; //Your database username $pass = "pass"; //Your database password $auth = "auth"; //Your auth database $realmlist = "login.server.com"; //This will show up and remind the user the change their realmlist.wtf upon completion. $realmd = array( 'db_host'=> $host, 'db_username' => $user, 'db_password' => $pass, 'db_name'=> $auth, ); function check_for_symbols($string){ $len=strlen($string); $allowed_chars="abcdefghijklmnopqrstuvwxyzæøåABCDEFGHIJKLMNOPQRSTUVWXYZÆØÅ0123456789"; for($i=0;$i<$len;$i++)if(!strstr($allowed_chars,$string[$i]))return TRUE; return FALSE; } function sha_password($username,$password){ $username = strtoupper($username); $password = strtoupper($password); return SHA1($username.':'.$password); } if ($_POST['registration']){ $realmd_bc_new_connect = mysql_connect($realmd['db_host'],$realmd['db_username'],$realmd['db_password']); $selectdb = mysql_select_db($realmd['db_name'],$realmd_bc_new_connect); if (!$realmd_bc_new_connect || !$selectdb){ die("<p align='center'>Error:<br><br>Something went wrong while connecting to the database.<br><br>Please make sure the config.php file is correct.</p>"); } $username = $_POST['username']; $password = $_POST['password']; $confirm = $_POST['confirm']; $username1 = $username; $password1 = sha_password($username1,$_POST['password']); $email1 = $_POST['email']; $email = $email1; if(!filter_var($email, FILTER_VALIDATE_EMAIL)){ die("<p align='center'>Error:<br><br>Your e-mail is not valid!<br><br>It has to be in *@*.* format to be valid.<br><br>Please go back and try again.</p>"); } if($password != $confirm){ die("<p align='center'>Error:<br><br>It appears your passwords didn&#146t match!<br><br>Please go back and try again.</p>"); } //You can change all the '3' to your specific minimal username length. if(strlen($_POST['username']) < 3){ $chars = strlen($username); die("<p align='center'>Error:<br><br>Your username is too short!<br><br>You entered ".$chars." character(s).<br><br>The minimum length is 3 characters and the maximum length is 15.<br><br>Please go back and try again.</p>"); } //You can change all the '5' to your specific minimal password length. if(strlen($_POST['password']) < 5){ $chars = strlen($password); die("<p align='center'>Error:<br><br>Your password is too short!<br><br>You entered ".$chars." character(s).<br><br>The minimum length is 5 characters and the maximum length is 15.<br><br>Please go back and try again.</p>"); } if (check_for_symbols($_POST['password']) == TRUE || check_for_symbols($username1) == TRUE) { die("<p align='center'><br><br>You are using characters not allowed in your username or password!<br><br>Please go back and try again.</p>"); } $qry_check_username = mysql_query("SELECT username FROM account WHERE username='$username'"); $qry_check_email = mysql_query("SELECT email FROM account WHERE email='$email'"); if (mysql_num_rows($qry_check_username) != 0){ die("<p align='center'>Error:<br><br>Your username is already in use!<br><br>Please go back and try again.</p>"); } if (mysql_num_rows($qry_check_email) != 0){ die("<p align='center'>Error:<br><br>Your e-mail is already in use!<br><br>Please go back and try again.</p>"); } else{ mysql_query("INSERT INTO account (username,sha_pass_hash,email,expansion) VALUES ('$username1','$password1','$email1','3')"); die("<p align='center'>Your account <b>".$username1."</b> has been successfully added to the database!<br><br>Make sure you change your realmlist.wtf file to:<br><br><b>set realmlist ".$realmlist."</b><br><br>Please contact one of the staff members if you're having difficulties loggin in after 5-10 minutes.</p>"); } } else{ ?> <html> <head> <title>WoW - Account Creator</title> </head> <body> <center><h1><u><b>Account Creator</b></u></h1><br> INSERT TERMS OF AGREEMENT AND RULES HERE <form autocomplete="off" action="<?php echo $_SERVER['PHP_SELF'] ?>" method="POST"> Username:<br><input type="text" name="username"><br><small>(3 or more characters)</small><br><br> Password:<br><input type="password" name="password"><br><small>(5 or more characters)</small><br><br> Confirm Password:<br><input type="password" name="confirm"><br><br> E-mail Address:<br><input type="text" name="email"><br><br> <input value="By clicking this you accept the Terms of Agreement and to abide by all rules stated above." class="submit" type="submit" name="registration"> </form></center> </body> </html> <?php } ?>
  5. To help change Administrator, Gamemaster, Developer, Moderator & Player(s) default passwords to make your server more secure after setup. Minimalistic Found and copied from another forum. Forgot who made it. I take no credit. Added & fix a few things. You can change all the '5' to your specific minimal password length. (Watch out for the '15' if you use Find and Replace.) <?php $host = "localhost"; //Your servers IP address $port = "3306"; //Your servers port $user = "root"; //Your database username $pass = "pass"; //Your database password $auth = "auth"; //Your auth database if(isset($_POST['submit'])) { $account = $_POST['account']; $passwordOld = $_POST['passwordOld']; $passwordNew = $_POST['passwordNew']; $passwordNew1 = $_POST['passwordNew1']; $passwordolde = sha1(strtoupper($account) . ":" . strtoupper($passwordOld)); $passwordnewe = sha1(strtoupper($account) . ":" . strtoupper($passwordNew)); $passwordNew1e = sha1(strtoupper($account) . ":" . strtoupper($passwordNew1)); $account = /*mysql_real_escape_string*/($account); $eoldpass = strtoupper($passwordolde); $enewpass = strtoupper($passwordnewe); $enewpass1 = strtoupper($passwordNew1e); $con = mysql_connect("$host", "$user", "$pass") or die(mysql_error()); mysql_select_db("$auth", $con) or die(mysql_error()); $query = "SELECT id FROM account WHERE username = '".$account."' AND sha_pass_hash = '".$eoldpass."'"; $result = mysql_query($query) or die(mysql_error()); $numrows = mysql_num_rows($result); if($enewpass != $enewpass1) { die("<p align='center'>Error:<br><br>New password fields must match!<br><br>Please go back and try again.</p>"); } if(strlen($_POST['passwordNew']) < 5){ $chars = strlen($passwordNew); die("<p align='center'>Error:<br><br>Your new password is too short!<br><br>You entered ".$chars." character(s).<br><br>The minimum length is 5 characters and the maximum length is 15.<br><br>Please go back and try again.</p>"); } if($numrows == 0) { die("<p align='center'>Error:<br><br>Invalid account name/password!<br><br>Please go back and try again.</p>"); } $query = "UPDATE account SET sha_pass_hash = '".$enewpass."' WHERE username = '".$account."'"; $result = mysql_query($query) or die(mysql_error()); echo "<p align='center'>Password for the Account<br><br>'<b>".$account."</b>'<br><br>has been successfully changed!"; //close mysql connection mysql_close($con); } else{ ?> <html> <head> <title>WoW - Password Changer</title> </head> <body> <center><h1><u><b>Password Changer</b></u></h1><br> <form autocomplete="off" method="post" action="<?php echo $_SERVER['PHP_SELF'] ?>"> Account/Username:<br><input type="text" name="account"><br><br> Old Password:<br><input type="password" name="passwordOld"><br><br> New Password:<br><input type="password" name="passwordNew"><br><small>(5 or more characters)</small><br><br> Confirm New Password:<br><input type="password" name="passwordNew1"><br><br> <input value="Change my password!" class="form3" type="submit" name="submit"> </form> <small>You <b><u>MUST</u></b> be offline for this tool to successfully work!</small> </center> </body> </html> <?php } ?>
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.