Open nadenislamarre opened 8 years ago
If you want security with the manager, Recalbox will have to ship and launch a real webserver.
But remember, even something lightweight like lighttpd or nginx have a big cost on the few rpi ressources. It's the reason why actually the Django instance is served by its "development server", that is not a real webserver.
We may talk more about this.
hum, the number of served pages remains limited. Do you advise to disable the manager when recalbox is running on an open network ? or do you have an other idea ?
There is no other choices, either we have a real webserver in front of Django either shut it down on opened network.
Sure, i could code something tricky, but if we are talking about real security than can be trusted, this is huge work to accomplish and maintain, too many work time for me.
Or maybe Recalbox system including something like ipban rules to reject all request to the Django server port except some IP from a whitelist to manually configure in some recalbox config file.
ok, i understand. i will disable in secure mode for the moment.
is it complex to put a lighttpd in front of the application ?
Nicolas
It's not very complex but not the easiest.
You know webservers are not application servers, you need something between the webserver and the webapp, for Apache or lighttpd it's "Fastcgi" protocole, for more "recent" webserver it's wscgi, this last solution could be considered easier and lighter. This also a more natural way with Django.
Starting with recalbox 4.1, recalbox.conf has a variable : system.security.enabled if this is one, the recalbox manager (among others) must not be open.
It must be secured. 1) at minimum by a basic http password 2) if possible, via ssl while the aim is to secure from network attacks
the login is what you want, but the password to use is the one provided by /etc/init.d/S35rootpasswd it's in this starting script that you must generate a password file in the temporary location.
I don't manage to do it by myself. I don't known django and i don't see in recalbox the same configuration files that i found in django documentation (like httpd.conf for example).
The current script content is :