- Hinzufügen der `Encryptor`-Klasse für AES-Verschlüsselung und -Entschlüsselung. - Implementierung des `EncryptionController` zur Bereitstellung von Endpunkten für Verschlüsselung, Entschlüsselung und Generierung von Verschlüsselungsparametern. - Erweiterung der DI-Konfiguration mit `AddEncryptor`-Erweiterungsmethode und Integration in `Program.cs`. - Bedingte Registrierung des `EncryptionController` basierend auf der Konfiguration `UseEncryptor`, um sicherzustellen, dass der Controller nur bei Bedarf verfügbar ist. - Implementierung von Lazy Loading für die Verbindungszeichenfolge in `UserManagerDbContext` zur sicheren Handhabung von verschlüsselten Verbindungszeichenfolgen.
77 lines
2.4 KiB
JSON
77 lines
2.4 KiB
JSON
{
|
|
"Logging": {
|
|
"LogLevel": {
|
|
"Default": "Information",
|
|
"Microsoft.AspNetCore": "Warning"
|
|
}
|
|
},
|
|
"ConnectionStrings": {
|
|
"DD_ECM_Connection": "cIFSoeMqHel7SDkAj4MWjy1UHrNJgoHrLkBJ/I/1Y95MsV9vFQjJLn6Shm9qtAyymwSNrX9s+78mW2PX4KulSA/KAaRwNQteP6SHrX0nNOJptot8TcohuiT0m9K2M/GsJEnLyJ+3yb0nJHR5yzRaVvjl8ERhgntW47dFMni98YA="
|
|
},
|
|
"AllowedOrigins": [ "https://localhost:7103", "http://172.24.12.39:85", "http://localhost:85", "http://localhost:4200", "http://localhost:5500", "https://localhost:7202" ],
|
|
"RunAsWindowsService": false,
|
|
"DirectorySearchOptions": {
|
|
"ServerName": "DD-VMP01-DC01",
|
|
"Root": "DC=dd-gan,DC=local,DC=digitaldata,DC=works",
|
|
"UserCacheExpirationDays": 1,
|
|
"CustomSearchFilters": {
|
|
"User": "(&(objectClass=user)(sAMAccountName=*))",
|
|
"Group": "(&(objectClass=group) (samAccountName=*))"
|
|
}
|
|
},
|
|
"Jwt": {
|
|
"Key": "pJBcBWZSjsWlhi1OlCcw6ERTMRNb7qsdvsfvdfbagdfbdfsSDGSDMhsjkfdhsdfbgkHKSDF",
|
|
"Issuer": "http://localhost:44316",
|
|
"Audience": "http://localhost:44316"
|
|
},
|
|
"NLog": {
|
|
"throwConfigExceptions": true,
|
|
"variables": {
|
|
"logDirectory": "E:\\LogFiles\\Digital Data\\WebUserManager",
|
|
"logFileNamePrefix": "${shortdate}-ECM.WebUserManager.Web"
|
|
},
|
|
"targets": {
|
|
"infoLogs": {
|
|
"type": "File",
|
|
"fileName": "${logDirectory}\\${logFileNamePrefix}-Info.log",
|
|
"maxArchiveDays": 30
|
|
},
|
|
"errorLogs": {
|
|
"type": "File",
|
|
"fileName": "${logDirectory}\\${logFileNamePrefix}-Error.log",
|
|
"maxArchiveDays": 30
|
|
},
|
|
"criticalLogs": {
|
|
"type": "File",
|
|
"fileName": "${logDirectory}\\${logFileNamePrefix}-Critical.log",
|
|
"maxArchiveDays": 30
|
|
}
|
|
},
|
|
// Trace, Debug, Info, Warn, Error and *Fatal*
|
|
"rules": [
|
|
{
|
|
"logger": "*",
|
|
"minLevel": "Info",
|
|
"maxLevel": "Warn",
|
|
"writeTo": "infoLogs"
|
|
},
|
|
{
|
|
"logger": "*",
|
|
"level": "Error",
|
|
"writeTo": "errorLogs"
|
|
},
|
|
{
|
|
"logger": "*",
|
|
"level": "Fatal",
|
|
"writeTo": "criticalLogs"
|
|
}
|
|
]
|
|
},
|
|
"EncryptionParameters": {
|
|
"Key": "JGPwHVD0BQmC7upi5OV11PzzIk47ugTJoqBV/et5w40=",
|
|
"IV": "gMuetIjlPvJnSzu+i7I3xg=="
|
|
},
|
|
// Delete below in production
|
|
"UseEncryptor": true,
|
|
"UseSwagger": true
|
|
} |