31
HFS ~ HTTP File Server / Re: Any way to limit viewing a folder/file from one specific IP?
« on: April 28, 2021, 07:01:21 PM »
if only one particular ip should be able to access the folder, add something similar in the diff template of the folder properties
either by using a forced disconnection
or even better by using a redirect which gives the user the impression of an invalid link
replace 127.0.0.1 by the allowed ip
a more concrete example is to only give access to a specific user without going through permissions
note the difference in use between {.!=| and {.=| , difference or equal usage
either by using a forced disconnection
Code: [Select]
[+]
{.if|{.=|%ip%|127.0.0.1.}|{:{.disconnect.}:}.}or even better by using a redirect which gives the user the impression of an invalid link
Code: [Select]
[+]
{.if|{.=|%ip%|127.0.0.1.}|{:{.redirect|../ .}:}.}replace 127.0.0.1 by the allowed ip
a more concrete example is to only give access to a specific user without going through permissions
Code: [Select]
[+]
{.if|{.!=|%user%|Tsuna.}|{:{.redirect|../ .}:}.}note the difference in use between {.!=| and {.=| , difference or equal usage

