Really easy Passwordsystem
Posted: Thu Sep 08, 2011 5:45 pm
Hello
In this Tutorial i show you how to make a simple Passwordsystem but the password isn't in the program it is in a PHPfile its better and secure.
Now we beginning with the PHP-File the name of my PHP-File is lizens.php
Here is the code for the PHP-File!
Now we come to the Code in Visualbasic in this code we send a Request to the PHP-File if the PHP-File says OK then you can Access in the Program if not the program close.
You need for this a button and a textbox the button code is this code here:
Here is the Visual Basic Code:
This is very simple and not secure but its a basic Passwordsystem and no body can find the password with a reflector!
I hope you like this Tutorial and give me Feedback
In this Tutorial i show you how to make a simple Passwordsystem but the password isn't in the program it is in a PHPfile its better and secure.
Now we beginning with the PHP-File the name of my PHP-File is lizens.php
Here is the code for the PHP-File!
Code: Select all
This is very simple the PHP-File is looking if the password correct!<?php
$passwort = $_GET["passwort"];
if($passwort == "Here is your Password")
{
echo "OK!";
}
else
{
echo "Nein!";
}?>
Now we come to the Code in Visualbasic in this code we send a Request to the PHP-File if the PHP-File says OK then you can Access in the Program if not the program close.
You need for this a button and a textbox the button code is this code here:
Here is the Visual Basic Code:
Code: Select all
Dim webreq As WebRequest = WebRequest.Create("YOUR Site.de/lizens.php?passwort=" & textbox1.text)
Dim Res As Net.WebResponse = webreq.GetResponse
Dim reader As StreamReader = New StreamReader(Res.GetResponseStream)
Dim ok As String = reader.ReadToEnd
if ok = "OK!" then
form2.show()
form1.close()
else
msgbox("Password invalid")
This is very simple and not secure but its a basic Passwordsystem and no body can find the password with a reflector!
I hope you like this Tutorial and give me Feedback