Jump to content
Sign in to follow this  
Mudsaf

Website protection from hackers [Hackers/Spammers]

Recommended Posts

Could some of you tell me the basic protection that PHP & MySQL website needs. For example new stuff to me was SQL injection. Q: How to prevent website from SQL injection?Q: What other protection websites require than SQL injection protect? I know that the password should be crypted but somehow i think its not enough or is it?

Share this post


Link to post
Share on other sites
How to prevent website from SQL injection?
use mysqli_real_escape_string() or other escaping functions. but most secure is prepared statement.
What other protection websites require than SQL injection protect?
this is a too vague. there is lot of things there to consider and depends on what your application suppose to do.. if you want to make much secure scripts its better to be stay updated with different attacks and maintain basic secure coding principals. http://owasp.org <=check this

Share this post


Link to post
Share on other sites
use mysqli_real_escape_string() or other escaping functions. but most secure is prepared statement.
yes !! we can use this php function but the actaul problem is when a hackers use hexadecimal input!! how to prevent it??

Share this post


Link to post
Share on other sites

escaping works on single byte charset well it has some issues in multi byte. utf-8 multi byte use hex values. prepare statment has not such an issue thus using it is safe with that. and also. hex values are genraly treated as string. if it is in character type column the each two digits of hex represent a character. if it is integer type it just represent the integer value of the hex represntetion.

Share this post


Link to post
Share on other sites

You also might want to read this topic. on security, that's developing right now. It has already given me many ideas. A couple of them are completely new to me. http://w3schools.inv...=0 EDIT: The older I get, few things experiences are more profound than learning about a completely new way of constructively thinking about something I thought I understood.

Edited by niche

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...