- move wtv-guide romcache + some fixes
- fix getAbsolutePath
- fix adding users (broken with getAbsolutePath update)
- fix bugs, update badwords, more bugs with account addition to fix yet
- implement bad username check (wordlist from Redialed)
- update zefie server IP (again)
- proper x-powered-by version format
- fix: also respect in hide_minisrv_version in cgi
- fix: properly respect hide_minisrv_version flag
- removed a scary warning
- add default php_binpath config entry (php is still disabled by default)
This commit is contained in:
zefie
2025-01-06 19:31:54 -05:00
parent 65521fcad6
commit 184e91d784
225 changed files with 380 additions and 171 deletions

View File

@@ -34,9 +34,19 @@ class WTVRegister {
// returns the user's ssid, and user_id and userid in an array if true, false if not
// check against reserved name list
if (this.minisrv_config.config.user_accounts.reserved_names) {
Object.keys(this.minisrv_config.config.user_accounts.reserved_names).forEach((k) => {
if (self.minisrv_config.config.user_accounts.reserved_names[k].toLowerCase() == username.toLowerCase()) return_val = true;
if (this.minisrv_config.config.user_accounts.reserved_names_files) {
var reserved_names = []
this.minisrv_config.config.user_accounts.reserved_names_files.forEach(function (v) {
var data = self.fs.readFileSync(v);
var json = JSON.parse(data);
json.forEach(function (v) {
reserved_names.push(v);
});
});
Object.keys(reserved_names).forEach((k) => {
var regex = new RegExp("^"+reserved_names[k]+"$", 'i');
if (username.match(regex)) return_val = true;
})
}