Solved

How to deny an PC name in .htaccess file?

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

Thanks,
HPvH
0
Comment
Question by:HPvH
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

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

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

Most ColdFusion developers get confused between the CFSet, Duplicate, and Structcopy methods of copying a Structure, especially which one to use when. This Article will explain the differences in the approaches with examples; therefore, after readin…
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.
Learn the basics of lists in Python. Lists, as their name suggests, are a means for ordering and storing values. : Lists are declared using brackets; for example: t = [1, 2, 3]: Lists may contain a mix of data types; for example: t = ['string', 1, T…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

816 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now