Dear Matthias, Good day again, We have found the solution at the below path:
/usr/lib64/GNUstep/SOGo/WebServerResources/js/Main.js Change the code as per below: this.login = function() { var checkStr = "test2.com"; if (r.creds.username.includes(checkStr)){ return r.loginState = "authenticating", a.login(r.creds).then(function(o) { o.gamissingkey ? r.loginState = "googleauthenticatorcode" : (r.loginState = "logged", r.cn = o.cn, t(function() { n.location.href === o.url ? n.location.reload(!0) : n.location.href = o.url }, 1e3)) }, function(o) { r.loginState = "error", r.errorMessage = o.error }), !1 } else { return r.loginState = "error", r.errorMessage = o.error; } } Thanks for your time! Best regards, ________________________________ From: users-requ...@sogo.nu <users-requ...@sogo.nu> on behalf of Pou Pas Kale <users@sogo.nu> Sent: Monday, March 1, 2021 8:56 AM To: users@sogo.nu <users@sogo.nu> Subject: Re: [SOGo] Restrict Web Access at SOGo from specific User - Domain Dear Mathias, Good day, Many thanks for our feedback. The authantication we are using is under Postgress SQL . Could you please send me an example from your below suggestions about "authView" & "add a dedicated column"? Many thanks again for your feedback. Best regards, ________________________________ From: users-requ...@sogo.nu <users-requ...@sogo.nu> on behalf of Matthias Kneer <users@sogo.nu> Sent: Monday, March 1, 2021 1:16 AM To: users@sogo.nu <users@sogo.nu> Subject: Re: [SOGo] Restrict Web Access at SOGo from specific User - Domain Hi, > If we tried to login to > an email account with the other domain (t...@b.com), then the system > should not proceed. Your assistance is highly appreciated. What kind of authentication / user backend are you using? If you are using SQL, you just have to modify your authView to only return users of domain a.com. You could also add a dedicated column to your mail users table like "sogoLogin" and only return users in your view where "sogoLogin" is true / 1. If you are using LDAP, there's an specific example in the installation guide (https://www.sogo.nu/files/docs/SOGoInstallationGuide.html) under "5.4. Authentication using LDAP". > the following filter to return only entries belonging to the > organization Inverse with a mail address and not inactive: > filter = "(o='Inverse' AND mail='*' AND status <> 'inactive')"; This can of course be specifically altered to your requirements. - Matthias -- users@sogo.nu https://inverse.ca/sogo/lists -- users@sogo.nu https://inverse.ca/sogo/lists -- users@sogo.nu https://inverse.ca/sogo/lists