SEBWIN-427: Ensured seb(s) URLs are correctly handled for secure session reconfiguration.

This commit is contained in:
Damian Büchel 2020-10-27 19:50:03 +01:00
parent 3698d7dabb
commit 7d55552889

View file

@ -341,8 +341,9 @@ namespace SafeExamBrowser.Client
{
var expression = Regex.Escape(Settings.Security.ReconfigurationUrl).Replace(@"\*", ".*");
var regex = new Regex($"^{expression}$", RegexOptions.IgnoreCase);
var sebUrl = args.Url.Replace(Uri.UriSchemeHttp, context.AppConfig.SebUriScheme).Replace(Uri.UriSchemeHttps, context.AppConfig.SebUriSchemeSecure);
allow = Settings.Security.AllowReconfiguration && regex.IsMatch(args.Url);
allow = Settings.Security.AllowReconfiguration && (regex.IsMatch(args.Url) || regex.IsMatch(sebUrl));
}
else
{