views:

29

answers:

1

0 down vote favorite

I have to design GUI for authentication. Which will have 1. User name 2. Password using The stream socket, The packet socket or The raw packet.is it possible in php and mysql language. any references or tutorials?

A: 

In case it prevents reposting of the same question multiple multiple times, here's a brief answer for you:

If you just want an authentication script, then you do not need any prior knowledge of socket programming. If you plan on making an HTML form for authenticating with a website then you do not need any prior knowledge of socket programming. If you want to make a C/C++ or other client-side non-browser-based application which will authenticate via your PHP/MySQL script, then you only need to know how to send an HTTP request and how to read the response header. You don't even need to parse the contents of the response if you make the PHP/MySQL yourself as you can have a successful login send a 200/OK and a failed login send a 403/Forbidden header.

If you want to make your application work with an existing website, then you will not only have to read for a 200/OK header but parse the body of the request for the expected "You are logged in" message.

In either case you'll have to store any session variables which should be included in the header. These will be used for proving your authentication in later requests.

steven_desu