PHP & Mysql injection in phplist

Discussion in 'PHP' started by ktsirig, Nov 7, 2006.

  1. #1
    Hello all,
    I want to secure a page which uses the script of "phplist". Basically this script stores username, name, surname, email etc of users in order for the company to send newsletters to their clients.
    Except from stripping slashes,backslashes etc or special characters, are there any other ways to prevent the data stored in the db from somenone that wants to "lay their hands" on them?

    Thank you!
     
    ktsirig, Nov 7, 2006 IP
  2. Cyrus255

    Cyrus255 Well-Known Member

    Messages:
    796
    Likes Received:
    17
    Best Answers:
    0
    Trophy Points:
    150
    #2
    Sure, but is it worth the trouble just to protect e-mails? Heh.

    Also, depends on what kind of webhosting you have, what server you run, etc.

    Make sure you have something like this (really basic)

    if(!isset($_SERVER['HTTP_USER_AGENT'])){
    die("Forbidden - You are not authorized to view this page");
    exit;
    }

    and/or this

    if(!$_SERVER['REQUEST_METHOD'] == "POST"){
    die("Forbidden - You are not authorized to view this page");
    exit;
    }

    change post to whatever method. there's a whole bunch of things to do.
     
    Cyrus255, Nov 7, 2006 IP
  3. noppid

    noppid gunnin' for the quota

    Messages:
    4,246
    Likes Received:
    232
    Best Answers:
    0
    Trophy Points:
    135
    #3
    It's not about the email, it's about the database and the rest. :rolleyes:
     
    noppid, Nov 7, 2006 IP
  4. melol2

    melol2 Active Member

    Messages:
    511
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    80
    #4
    Dont use the same database for emails as you do other important information. One day some guy hired me to secure his site. I found out 10,000 emails, passwords, usernames, and more could have been compromised if I hadnt told him about a problem with his security.

    You can also use my search engine I call hackersearch. It searches specific websites that deal in website security.

    http://www.sandsword.com/isearch2/
     
    melol2, Nov 7, 2006 IP