Seems like a reasonable suggestion.
It would certainly be preferable if it worked the same with both commands if possible.
So are you suggesting that the crashes I noted earlier might have gone away after running the rcd command? I will test and see if anything changed. I did not notice until much later that webGUI files had been saved to my cache folder.
Before we implement the JWT change, it might be worth thinking if it works.
There are a few problems to settle if we are going to change the implementation.
First, static files:
That's because when rclone opens the login URL, it will include the basic auth only if BasicUser is set, which is not the case if htpasswd file is used. That's the reason why users are required to login twice - first to acquire static file, second to save the password in local storage.
To solve this, one solution might be not requiring authentication to static files. Here static files means web-gui components (the downloaded zip) or anything that is fixed and not from the rclone itself.
I would like to discuss something related to security. The current implementation is only serializing the username and password as a Base64 token. No encryption, no hash, only encoding. This might be a great security fault if the web-gui is hosted in a remote server with HTTP only. But it still makes no sense if the JWT token is generated in browser - the second part of the token is just the password.
So if we want to increase the security level, the following might be done:
Implement a login endpoint in rclone backend. This accepts a pair of username and password, and returns a token. The token should only include the username, and signed by a secret that only the server knows.
Stop requiring authentication to local static files. This may take some time since it may need to know what path it is requesting and whether it is a static file.
I knew there was a way to do that, I just couldn't remember it! Can we do a bit of context sensitive help while dragging or something like that to tell the user about it?
Great so some kind of button to stop transfers shouldn't be a major issue.
Regarding directory size, yes that's the kind of thing. RClone browser has it set as a handy button which I often use to compare and check large transfers have successfully completed. I presume much like the ability to stop transfers this shouldn't be a huge ask to implement this?
My final question (and maybe this is something that can be done at command line level) is can the WebGUI be activated without actually launching a browser window? I have it set to run at Windows start up, but I only want to launch it form a browser shortcut.
Is there a concept of queue? Right now every download starts right away, so one can end up with 100+ concurrent downloads, which results in really low download speed for each. Would be nice to be able to set a limit to the number of downloads, so the rest would wait in queue.
I tried providing transfers option directly (rclone rcd --rc-web-gui --transfers 1), but apparently it was a silly idea, as it didn't work. Perhaps, it should be provided via options/set?
I am unable to keep it alive, I am using ubuntu18 headless server. It works well from terminal (ssh) when I point it out to my vps address and port but as soon as I closed my terminal (ssh) it no longer works. I have set up vps to drive mount and I need browser to just login and transfer data when I want. I don't want any automate script to upload contents to my drive. I will be doing everything manually.
So I need two things. I need to keep my rclone browser alive forever so I can drop credentials and use when and where required. And also I dont find any file upload option from rclone browser. Though there are lot of options at backend I did not change any. Can you guide me,this is my first visit rclone browser
For the first question, you can use screen or tmux to make it running under their control, or you may write a systemd (or any other init you are using) service to run in the background. If you are only running it once, try nohup .
Very thankful to your reply. I don't want to be burden on you. But I am literally new to this linux world. I am using ubuntu18 under USER I have installed rclone. How am I suppose to prepare script which will run under systemd? Is it easy to write a script? What do I put commands in it?