Flood-UI / flood

A web UI for rTorrent, qBittorrent and Transmission with a Node.js backend and React frontend. Migrate to v4: https://github.com/jesec/flood/wiki/Migrate-from-older-versions-of-Flood.
https://flood.js.org
GNU General Public License v3.0
1.81k stars 173 forks source link

Add an option to completely disable users and authentication #880

Closed nitnelave closed 3 years ago

nitnelave commented 4 years ago

Description

This change adds a config option disableUsersAndAuth. When it is enabled, the app makes no effort to try to authenticate users, skips the login and register pages and goes straight to the dashboard, using a hardcoded administrator user.

The settings for the hardcoded user are in the config under the block configUser.

Related Issue

Fixes #240.

Motivation and Context

Some servers have their own authentication methods (e.g. nginx basic_auth, LDAP, OAuth and so on). Instead of trying to re-implement everything here, make authentication optional so it can be added as a layer.

How Has This Been Tested?

I set it up on my server, tested it with rTorrent both with SCGI and socket settings. Monitoring the network requests shows no remaining 401s. As long as the config flag is not flipped (and by default it's not, which is why I chose the "disable" version instead of "enable" as I would have liked), this change is a no-op. Note that I didn't try every operation, but given the horizontal nature of the change, I would expect that if something works, everything works.

Screenshots (if appropriate): N/A

Types of changes

Checklist:

jesec commented 3 years ago

Merged: https://github.com/jesec/flood/commit/06e6d1e3f7bf2aef068d256b0c7a6dd1280567a0.