You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
\n";} //Creating new database security $sql="CREATE database security CHARACTER SET gbk "; if (mysqli_query($con, $sql)) {echo "[*]...................Creating New database 'SECURITY' successfully";echo "
@anukaal Hi Anurag. Looking at the traceback of yours, I suspect the password of the database is not set up properly. Please have a look at that.
Also, it seems like you changed the code to work with php7. In case, there is something left missing in your code and it is creating problems in running this lab, you can use the updated lab available at https://github.com/mukkul007/sqli-labs-kali2
\n";} else {echo "[*]...................Error purging database: " . mysqli_error($con); echo "
\n";} //Creating new database security $sql="CREATE database
security
CHARACTER SETgbk
"; if (mysqli_query($con, $sql)) {echo "[*]...................Creating New database 'SECURITY' successfully";echo "\n";} else {echo "[*]...................Error creating database: " . mysqli_error($con);echo "
\n";} //creating table users $sql="CREATE TABLE security.users (id int(3) NOT NULL AUTO_INCREMENT, username varchar(20) NOT NULL, password varchar(20) NOT NULL, PRIMARY KEY (id))"; if (mysqli_query($con, $sql)) {echo "[*]...................Creating New Table 'USERS' successfully";echo "
\n";} else {echo "[*]...................Error creating Table: " . mysqli_error($con);echo "
\n";} //creating table emails $sql="CREATE TABLE security.emails ( id int(3)NOT NULL AUTO_INCREMENT, email_id varchar(30) NOT NULL, PRIMARY KEY (id) )"; if (mysqli_query($con, $sql)) {echo "[*]...................Creating New Table 'EMAILS' successfully"; echo "
\n";} else {echo "[*]...................Error creating Table: " . mysqli_error($con);echo "
\n";} //creating table uagents $sql="CREATE TABLE security.uagents ( id int(3)NOT NULL AUTO_INCREMENT, uagent varchar(256) NOT NULL, ip_address varchar(35) NOT NULL, username varchar(20) NOT NULL, PRIMARY KEY (id) )"; if (mysqli_query($con, $sql)) {echo "[*]...................Creating New Table 'UAGENTS' successfully";echo "
\n";} else {echo "[*]...................Error creating Table: " . mysqli_error($con);echo "
\n";} //creating table referers $sql="CREATE TABLE security.referers ( id int(3)NOT NULL AUTO_INCREMENT, referer varchar(256) NOT NULL, ip_address varchar(35) NOT NULL, PRIMARY KEY (id) )"; if (mysqli_query($con, $sql)) {echo "[*]...................Creating New Table 'REFERERS' successfully";echo "
\n";} else {echo "[*]...................Error creating Table: " . mysqli_error($con);echo "
\n";} //inserting data $sql="INSERT INTO security.users (id, username, password) VALUES ('1', 'Dumb', 'Dumb'), ('2', 'Angelina', 'I-kill-you'), ('3', 'Dummy', 'p@ssword'), ('4', 'secure', 'crappy'), ('5', 'stupid', 'stupidity'), ('6', 'superman', 'genious'), ('7', 'batman', 'mob!le'), ('8', 'admin', 'admin'), ('9', 'admin1', 'admin1'), ('10', 'admin2', 'admin2'), ('11', 'admin3', 'admin3'), ('12', 'dhakkan', 'dumbo'), ('14', 'admin4', 'admin4')"; if (mysqli_query($con, $sql)) {echo "[*]...................Inserted data correctly into table 'USERS'";echo "
\n";} else {echo "[*]...................Error inserting data: " . mysqli_error($con);echo "
\n";} //inserting data $sql="INSERT INTO
security
.emails
(id, email_id) VALUES ('1', 'Dumb@dhakkan.com'), ('2', 'Angel@iloveu.com'), ('3', 'Dummy@dhakkan.local'), ('4', 'secure@dhakkan.local'), ('5', 'stupid@dhakkan.local'), ('6', 'superman@dhakkan.local'), ('7', 'batman@dhakkan.local'), ('8', 'admin@dhakkan.com')"; if (mysqli_query($con, $sql)) {echo "[*]...................Inserted data correctly into table 'EMAILS'";echo "\n";} else {echo "[*]...................Error inserting data: " . mysqli_error($con);echo "
\n";} //CREATE TABLE security.search (id int(3) NOT NULL AUTO_INCREMENT, search varchar(20) NOT NULL, PRIMARY KEY (id)); //INSERT INTO
security
.search
(search) VALUES ( 'Dumb@dhakkan.com'), ('Angel@iloveu.com'), ('Dummy@dhakkan.local'), ( 'secure@dhakkan.local'), ( 'stupid@dhakkan.local'), ( 'superman@dhakkan.local'), ( 'batman@dhakkan.local'), ( 'admin@dhakkan.com')"; //including the Challenges DB creation file. include("../sql-connections/setup-db-challenge.php"); ?>The text was updated successfully, but these errors were encountered: