'XAMPP only allow specific LAN device access
I'm looking to allow a specific device (in this case one particular iPad) access to XAMPP on a computer on the same LAN. I don't want any other devices besides this one and the server itself to be able to access localhost or anything else though. I'm able to find ways to enable LAN access online but to my understanding this could allow anyone on the same network to access XAMPP if they have the server's IP.
Solution 1:[1]
if you are talking about the apache server inside xampp, you can use this kind of solution: https://serverfault.com/questions/776252/allow-access-to-apache-server-from-only-one-ip-address
Similar solution can be found for the integrated tomcat, MySQL, etc...
Solution 2:[2]
If you are using Apache 2.4, make sure that you LOAD the authz_core module,
DELETE:
Order allow,deny
Deny from all
Allow from my.ip.add.res
and, in place of the deleted directives,
INSERT:
Require ip xxx.xxx.xxx.xxx
**If you are using Apache 2.2**, make sure that you LOAD the authz_host module,
DELETE:
Order allow,deny
Deny from all
Allow from my.ip.add.res
and, in place of the deleted directives,
INSERT:
Order Deny,Allow
Deny from all
Allow from xxx.xxx.xxx.xxx
Solution 3:[3]
It is slightly off-topic to what's being requested, but requesting credentials is a simple, effective way to restrict access without worrying about IP addresses or MAC addresses.
https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication
e.g. https://stackoverflow.com/a/44560458/3196753
This may not fulfill certain security requirements (e.g. HIPAA, PCI) but for simply keeping unauthorized people out, it is tremendously simple and effective.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Simone Celia |
| Solution 2 | ItsMeBrille |
| Solution 3 | tresf |
