rejetto forum

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - rejetto

Pages: 1 ... 7 8 9 10 11 ... 844
123
HFS ~ HTTP File Server / Re: Hosting and PDF viewing
« on: February 13, 2022, 03:48:56 PM »
i guess it's because you apparently "invented" a mime type :D
mime types are conventions, so the only way is to google for it.
I did it for you, and apparently for pdf is application/pdf
hope it helps

124
HFS ~ HTTP File Server / Re: Ban IP using cloudflare
« on: February 10, 2022, 10:40:08 PM »
No, the limit is not on login. I'll try to explain. HFS normally knows your ip. That thing you are enabling is letting your other part (in your case cloudflare) to "tell" HFS what the real ip is. It can tell the truth or lie. Of course cloudflare will tell the truth, but HFS doesn't know.
That's why this feature is limited.
By default HFS decide to trust such information if it comes from a software that's running on your computer (localhost).
That's why you have to decide who HFS should trust. It's a trust limited to "telling the ip" of course. It's not necessarily something dangerous, but HFS must play it safe.
Your best option is to allow not * but just the IPs of cloudflare.
You can learn how to enter a filter different than * with this guide: https://www.rejetto.com/wiki/index.php/HFS:_IP_masks

i don't know why the script isn't working. I didn't even test it, just copied it.

126
HFS ~ HTTP File Server / Re: Ban IP using cloudflare
« on: February 09, 2022, 03:57:25 PM »
ok, i googled: hfs x-forwarded-for
and that's what i've found :)

https://rejetto.com/forum/index.php?topic=6292.msg1037912#msg1037912

so, HFS already supports reverse-proxy but by default it's limited to localhost for security reasons.
You can change this but I gave a quick look and I think it's still missing in the menu.
Method 1) you'll edit the hfs.ini with notepad. Be sure first to quit HFS first.
Method 2) there's a scripting command to modify configuration via scripting. So as you can go Menu > Debug > Run script
and there run this small script
{.set ini|forwarded-mask=*.}

Here I'm suggesting * because if you only get requests that are forwarded by the proxy, then you can actually trust any source.
Otherwise you may specify exactly the IP address of the proxy.
Hope it helps.

127
HFS ~ HTTP File Server / Re: Ban IP using cloudflare
« on: February 09, 2022, 02:03:00 PM »
ciao Sergio,
ot may help to know what you did to configure HFS for cloudflare.
I've never used cloudflare myself, so i hope someone could help you.

128
HFS ~ HTTP File Server / Re: a new beginning...
« on: February 08, 2022, 05:09:48 PM »
in next version plugins' api will get a breaking change:
the way to get the api object will be as parameter of the "init" function.
I think this is cleaner.

Also, I've noticed that in exe distribution the 'require' doesn't work. To solve this, plugins will get api.require in the api object.

129
HFS ~ HTTP File Server / Re: Source path batch change ?
« on: February 07, 2022, 03:38:12 PM »
this freezing sounds like a slow networked drive/path, is it so?

you can preview version 3 at https://github.com/rejetto/hfs/

if you decided to make some testing feel free to contact me for help privately, as i'm eager to get it working correctly: a@rejetto.com

130
HFS ~ HTTP File Server / Re: Source path batch change ?
« on: February 07, 2022, 11:10:59 AM »
hi and welcome!
there's nothing ready to use,
but an option for you is to change the folders using script commands.
so you can prepare your script, and decide to run it inside Menu > Debug > Run script
or a different solution.
Your script may even take some inputs somewhere, as parameters of the work is going to do.

Manually it means that you right click and "edit resource" for each folder.
I expect this to be a 20 seconds operation, x30 means 10 minutes.
It's up to you.

There's no option in HFS 2 to have the vfs in plain text, sorry.

HFS 3 (still in alpha, but usable) only uses plain text for all configuration, and doesn't require restart if you edit it while running.

131
HFS ~ HTTP File Server / Re: a new beginning...
« on: February 07, 2022, 09:35:14 AM »
https://github.com/rejetto/hfs/releases/tag/v0.9.0

admin interface, with real time connections monitor

132
HFS ~ HTTP File Server / Re: hfs 3 logo
« on: February 02, 2022, 06:50:49 PM »
ok, my idea is to ask someone to make me a custom version of this concept
https://www.shutterstock.com/it/image-vector/hand-food-cloche-tray-dish-platter-1128086180

and to change the motto (currently "the other way to share your files") to "serve fresh", referring to the fact that it's your disk providing files, and there's no de-sync with a cloud version

133
HFS ~ HTTP File Server / Re: a new beginning...
« on: January 29, 2022, 09:37:03 PM »
onDirEntry is in case you want to manipulate the list in the backend, not in frontend.
I think what you need is walkNode.

134
yes, i can see it running with your ip.
HFS is by default read-only.
There's no way for me to know that you didn't create an account that once logged in can upload or delete stuff, but I assume from your words that you didn't do it.

Be careful exposing your php files, or other files that may contain sensible informations.
A php file in HFS is just a text file where people can read your source.
You may expect that it is executed and only its output is visible, but that's not true in HFS (because it doesn't support PHP)

135
HFS doesn't support PHP.
Still you can use HFS to execute a file (with parameters) when a specific url is requested, by using the {.exec.} command.
Yet, this is hardly what HFS is designed for, so if that's your only goal you may find better solutions.
You can replace the disconnect command in my example with exec, that is documented here
https://rejetto.com/wiki/index.php/HFS:_scripting_commands#Others

hfs' scripting language is quite bad, but it's all you got on hfs :)

Pages: 1 ... 7 8 9 10 11 ... 844