feat(core): Add URL encryption for GDPR compliancy

This commit is contained in:
smizrahi
2024-01-09 11:01:17 +01:00
parent 26b14671f5
commit 930a06e520
2 changed files with 9 additions and 3 deletions

View File

@@ -788,8 +788,10 @@ static const NSString *kJwtKey = @"jwt";
[us disableForceResetPassword];
}
}
response = [self responseWithStatus: 200 andJSONRepresentation:
[NSDictionary dictionaryWithObjectsAndKeys: [SOGoUser getEncryptedUsernameIfNeeded:username], @"username", nil]];
response = [self responseWith204];
if (!passwordRecovery) {
authCookie = [auth cookieWithUsername: username
andPassword: newPassword

View File

@@ -183,8 +183,12 @@
'X-XSRF-TOKEN' : xsrfCookie
},
data: { userName: userName, newPassword: newPassword, oldPassword: oldPassword, token: token }
}).then(function() {
d.resolve({url: redirectUrl(userName, domain)});
}).then(function (response) {
if (response && response.data && response.data.username) {
d.resolve({ url: redirectUrl(response.data.username, domain) });
} else {
d.resolve({ url: redirectUrl(userName, domain) });
}
}, function(response) {
var error,
data = response.data,