SEBWIN-471: Fixed bug where reconfiguration URL wasn't mandatory in a secure session.
This commit is contained in:
parent
8187799929
commit
417a16ea49
1 changed files with 2 additions and 2 deletions
|
@ -341,13 +341,13 @@ namespace SafeExamBrowser.Client
|
||||||
{
|
{
|
||||||
var expression = Regex.Escape(Settings.Security.ReconfigurationUrl).Replace(@"\*", ".*");
|
var expression = Regex.Escape(Settings.Security.ReconfigurationUrl).Replace(@"\*", ".*");
|
||||||
var regex = new Regex($"^{expression}$", RegexOptions.IgnoreCase);
|
var regex = new Regex($"^{expression}$", RegexOptions.IgnoreCase);
|
||||||
var sebUrl = args.Url.Replace(Uri.UriSchemeHttp, context.AppConfig.SebUriScheme).Replace(Uri.UriSchemeHttps, context.AppConfig.SebUriSchemeSecure);
|
var sebUrl = args.Url.Replace(Uri.UriSchemeHttps, context.AppConfig.SebUriSchemeSecure).Replace(Uri.UriSchemeHttp, context.AppConfig.SebUriScheme);
|
||||||
|
|
||||||
allow = Settings.Security.AllowReconfiguration && (regex.IsMatch(args.Url) || regex.IsMatch(sebUrl));
|
allow = Settings.Security.AllowReconfiguration && (regex.IsMatch(args.Url) || regex.IsMatch(sebUrl));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
allow = Settings.Security.AllowReconfiguration;
|
logger.Warn("The active configuration does not contain a valid reconfiguration URL!");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue