Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New Coder
    Join Date
    Dec 2011
    Posts
    34
    Thanks
    2
    Thanked 0 Times in 0 Posts

    should i database user hostname, isp and stuff?

    Hi,

    I have a quick question for the CodingForums community-
    I have a website and im wondering if i should store the users hostname, isp, and general IP information into my sql database?
    Like i'm not sure if i should just do live lookup with the gethostbyaddr(); function or if i should just do it live and save some space in the database.

    any suggestions?

  • #2
    Regular Coder Custard7A's Avatar
    Join Date
    Jul 2010
    Location
    Australia
    Posts
    286
    Thanks
    32
    Thanked 33 Times in 33 Posts
    A users' hostname, isp, and particularly IP are unreliable data to begin with, I wouldn't even rely on them for the duration of a session. I suppose it comes down to why you would want to keep them.

  • #3
    Regular Coder patryk's Avatar
    Join Date
    Oct 2012
    Location
    /dev/couch
    Posts
    398
    Thanks
    2
    Thanked 64 Times in 64 Posts
    why database? you have server logs to do that stuff.
    if ur using apache, check logging settings and related modules
    http://httpd.apache.org/docs/current/logs.html

    a hint: include cookies in your log format. this way you should be able to trace-back every record.

  • #4
    New Coder
    Join Date
    Dec 2011
    Posts
    34
    Thanks
    2
    Thanked 0 Times in 0 Posts
    I have a system that stops proxies and vpn usage on my site as it violates the terms of service with the advertisers. I'm not so sure if i should database that info or if i should do live lookup. What do you think?
    As for the server logs, i have these just for reference to ensure the user is not a vpn user (eg. ThePlanet.Net Internet Services) in my admin panel instead of checking the server logs. Do you think a live lookup would be better or should i set it in the database?


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •