mirror of
https://github.com/Viren070/AIOStreams.git
synced 2025-12-01 23:14:04 +01:00
fix: extract config string for custom configs when determining whether to encrypt sensitive information
This commit is contained in:
@@ -131,7 +131,15 @@ app.get('/:config/configure', (req, res) => {
|
||||
}
|
||||
try {
|
||||
let configJson = extractJsonConfig(config);
|
||||
if (isValueEncrypted(config)) {
|
||||
let configString = config;
|
||||
if (CUSTOM_CONFIGS) {
|
||||
const customConfig = extractCustomConfig(config);
|
||||
if (customConfig) {
|
||||
configJson = customConfig;
|
||||
configString = decodeURIComponent(CUSTOM_CONFIGS[config]);
|
||||
}
|
||||
}
|
||||
if (isValueEncrypted(configString)) {
|
||||
logger.info(`Encrypted config detected, encrypting credentials`);
|
||||
configJson = encryptInfoInConfig(configJson);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user