Jump to content

Identifying Certain Computers


hishighness

Recommended Posts

Hey all, I'm trying to block a few computers from my workplace (or more accurately the people who use them) from my website. My first thought was to use IP addresses but unfortunately I guess because of the way our network is set up some computers have the same IP address so if I blocked by IP I'd end up blocking good people as well as the bad apples.

 

So I was wondering if there is some sort of unique computer identifier that can be captured using php I could use to ensure I'm only blocking the people I want to. I can log in to their computers (using my own ID of course) and get any info needed while they're not there so getting the info wouldn't be a problem. I don't really want to create a login system because I want it to look like the site just isn't working for them. (which wouldn't be a stretch because my web host sucks)

 

Thanks for reading! :D

Link to comment
Share on other sites

Hey all, I'm trying to block a few computers from my workplace (or more accurately the people who use them) from my website. My first thought was to use IP addresses but unfortunately I guess because of the way our network is set up some computers have the same IP address so if I blocked by IP I'd end up blocking good people as well as the bad apples.

That's also known as DHCP ;)

 

Maybe someting like:

<?php
$hostname = gethostbyaddr($_SERVER['REMOTE_ADDR']);

echo $hostname;
?>

 

This works great when the webserver is in the same network as the clients...

If the webserver is not in the same network (seperated by router) you would lock out the router thus locking out the entire network behind that router...(NAT, http://en.wikipedia.org/wiki/Network_address_translation)

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

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.   Restore formatting

  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.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.