Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I'm searching for an approach permitting access on an apache web server, but only for clients that have an IP address which machtes on an IP address that is assigned to a dynamic host address.

share|improve this question

closed as not a real question by mdpc, Ward, Khaled, John Gardeniers, Bryan Dec 31 '12 at 10:14

It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

1 Answer 1

up vote 0 down vote accepted

If I understood your question correctly (you want something like Allow from somehost.dyndns.org) then no, this is not possible.
Apache gets the request from the IP and does a reverse DNS lookup, this will not match and the client will be denied.

The only solution I could think of would be to write a cronjob which periodically resolves the dyndns record and writes an .htaccess file allowing only that IP.
But that is rather hackish and I would much rather simply implement authentication instead.

share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.