Solved

How to deny an PC name in .htaccess file?

Posted on 2009-05-14
3
313 Views
Last Modified: 2013-11-16
Hi,
How can I deny an pc name with .htaccess file?

Thanks,
HPvH
0
Comment
Question by:HPvH
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 3

Accepted Solution

by:
cevoman earned 150 total points
ID: 24388406
Hi there,

You can't as the server won't know about the PC name on a network
Only IP and Hostname

Kind regards
James
0
 

Author Comment

by:HPvH
ID: 24388452
Ok, how to deny a range?
0
 
LVL 11

Assisted Solution

by:climbgunks
climbgunks earned 100 total points
ID: 24389560

you can allow/deny a range using a partial domain name, or a range of IP addresses.   The latter is a bit tricky as it has to be specified in CIDR notation, which allows you to specify a contigous set of addresses on well defined boundaries.      You may have to specify multiple small groups to deny if you're not blocking on netmask boundaries.


for example:
   deny from   9.0.0.0/8      # blocks all of the 9.0.0.0 network
   deny from  192.168.1.0/24  # blocks only the last octet (0-255) of addresses
   deny from cnn.com     # block on a domain name

see http://httpd.apache.org/docs/1.3/mod/mod_access.html#allow    for more info on the allow/deny syntax

and

http://en.wikipedia.org/wiki/CIDR_address

for more info on CIDR notation

0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

When it comes to showing a 404 error page to your visitors, you do not want that generic page to show, and you especially do not want your hosting provider’s ad error page to show either. In this article, I will show you how to enable the custom 40…
Active Directory replication delay is the cause to many problems.  Here is a super easy script to force Active Directory replication to all sites with by using an elevated PowerShell command prompt, and a tool to verify your changes.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question