-
Notifications
You must be signed in to change notification settings - Fork 10
config_web_auth
euzu edited this page May 15, 2024
·
6 revisions
web_auth
If the config web_ui_enabled
is false this config is ignored.
web_ui_enabled: true
web_auth:
enabled: true
secret: very.secret.secret
issuer: m3u_filter
userfile: user.txt
-
web_auth
can be deactivated ifenabled
is set tofalse
. If not set default istrue
. -
secret
is used for jwt token generation. -
userfile
is the file where the ui users are stored. if the filename is not absolutem3u-filter
will look into theconfig_dir
. ifuserfile
is not given the default value isuser.txt
For example you can generate a secret key for jwt with:
node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"
The userfile has the format username: password
per line.
Example:
test: $argon2id$v=19$m=19456,t=2,p=1$QUpBWW5uellicTFRUU1tR0RVYVVEUTN5UEJDaWNWQnI3Rm1aNU1xZ3VUSWc3djZJNjk5cGlkOWlZTGFHajllSw$3HHEnLmHW07pjE97Inh85RTi6VN6wbV27sT2hHzGgXk
nobody: $argon2id$v=19$m=19456,t=2,p=1$Y2FROE83ZDQ1c2VaYmJ4VU9YdHpuZ2c2ZUwzVkhlRWFpQk80YVhNMEJCSlhmYk8wRE16UEtWemV2dk81cmNaNw$BB81wmEm/faku/dXenC9wE7z0/pt40l4YGh8jl9G2ko
The password can be generated with ( /opt/m3u-filter/config should be replaced with your path)
./m3u-filter -p /opt/m3u-filter/config --genpwd
or with docker
docker container exec -it m3u-filter ./m3u-filter --genpwd
The encrypted pasword needs to be added manually into the users file.