diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/ExchangeServerProxy.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/ExchangeServerProxy.cs
index dbc4e005..d54d8eb3 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/ExchangeServerProxy.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/ExchangeServerProxy.cs
@@ -11,6 +11,12 @@
//
// This source code was auto-generated by wsdl, Version=2.0.50727.3038.
//
+
+using WebsitePanel.Providers;
+using WebsitePanel.Providers.Common;
+using WebsitePanel.Providers.HostedSolution;
+using WebsitePanel.Providers.ResultObjects;
+
namespace WebsitePanel.EnterpriseServer {
using System.Xml.Serialization;
using System.Web.Services;
@@ -19,10 +25,6 @@ namespace WebsitePanel.EnterpriseServer {
using System;
using System.Diagnostics;
using System.Data;
- using WebsitePanel.Providers.HostedSolution;
- using WebsitePanel.Providers.Common;
- using WebsitePanel.Providers.ResultObjects;
- using WebsitePanel.Providers;
///
@@ -4311,24 +4313,26 @@ namespace WebsitePanel.EnterpriseServer {
///
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetMailboxSetupInstructions", RequestNamespace="http://smbsaas/websitepanel/enterpriseserver", ResponseNamespace="http://smbsaas/websitepanel/enterpriseserver", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public string GetMailboxSetupInstructions(int itemId, int accountId, bool pmm, bool emailMode, bool signup) {
+ public string GetMailboxSetupInstructions(int itemId, int accountId, bool pmm, bool emailMode, bool signup, string passwordResetUrl) {
object[] results = this.Invoke("GetMailboxSetupInstructions", new object[] {
itemId,
accountId,
pmm,
emailMode,
- signup});
+ signup,
+ passwordResetUrl});
return ((string)(results[0]));
}
///
- public System.IAsyncResult BeginGetMailboxSetupInstructions(int itemId, int accountId, bool pmm, bool emailMode, bool signup, System.AsyncCallback callback, object asyncState) {
+ public System.IAsyncResult BeginGetMailboxSetupInstructions(int itemId, int accountId, bool pmm, bool emailMode, bool signup, string passwordResetUrl, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("GetMailboxSetupInstructions", new object[] {
itemId,
accountId,
pmm,
emailMode,
- signup}, callback, asyncState);
+ signup,
+ passwordResetUrl}, callback, asyncState);
}
///
@@ -4338,12 +4342,12 @@ namespace WebsitePanel.EnterpriseServer {
}
///
- public void GetMailboxSetupInstructionsAsync(int itemId, int accountId, bool pmm, bool emailMode, bool signup) {
- this.GetMailboxSetupInstructionsAsync(itemId, accountId, pmm, emailMode, signup, null);
+ public void GetMailboxSetupInstructionsAsync(int itemId, int accountId, bool pmm, bool emailMode, bool signup, string passwordResetUrl) {
+ this.GetMailboxSetupInstructionsAsync(itemId, accountId, pmm, emailMode, signup, passwordResetUrl, null);
}
///
- public void GetMailboxSetupInstructionsAsync(int itemId, int accountId, bool pmm, bool emailMode, bool signup, object userState) {
+ public void GetMailboxSetupInstructionsAsync(int itemId, int accountId, bool pmm, bool emailMode, bool signup, string passwordResetUrl, object userState) {
if ((this.GetMailboxSetupInstructionsOperationCompleted == null)) {
this.GetMailboxSetupInstructionsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetMailboxSetupInstructionsOperationCompleted);
}
@@ -4352,7 +4356,8 @@ namespace WebsitePanel.EnterpriseServer {
accountId,
pmm,
emailMode,
- signup}, this.GetMailboxSetupInstructionsOperationCompleted, userState);
+ signup,
+ passwordResetUrl}, this.GetMailboxSetupInstructionsOperationCompleted, userState);
}
private void OnGetMailboxSetupInstructionsOperationCompleted(object arg) {
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/ExchangeServer/ExchangeServerController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/ExchangeServer/ExchangeServerController.cs
index 12ea3e0a..28402df7 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/ExchangeServer/ExchangeServerController.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/ExchangeServer/ExchangeServerController.cs
@@ -2564,7 +2564,7 @@ namespace WebsitePanel.EnterpriseServer
}
}
- public static string GetMailboxSetupInstructions(int itemId, int accountId, bool pmm, bool emailMode, bool signup)
+ public static string GetMailboxSetupInstructions(int itemId, int accountId, bool pmm, bool emailMode, bool signup, string passwordResetUrl)
{
#region Demo Mode
if (IsDemoMode)
@@ -2589,12 +2589,11 @@ namespace WebsitePanel.EnterpriseServer
if (String.IsNullOrEmpty(body))
return null;
- string result = EvaluateMailboxTemplate(itemId, accountId, pmm, false, false, body);
+ string result = EvaluateMailboxTemplate(itemId, accountId, pmm, false, false, body, passwordResetUrl);
return user.HtmlMail ? result : result.Replace("\n", "
");
}
- private static string EvaluateMailboxTemplate(int itemId, int accountId,
- bool pmm, bool emailMode, bool signup, string template)
+ private static string EvaluateMailboxTemplate(int itemId, int accountId, bool pmm, bool emailMode, bool signup, string template, string passwordResetUrl)
{
Hashtable items = new Hashtable();
@@ -2618,7 +2617,8 @@ namespace WebsitePanel.EnterpriseServer
Guid token;
- var passwordResetUrl = OrganizationController.GenerateUserPasswordResetLink(account.ItemId, account.AccountId,out token);
+ passwordResetUrl = OrganizationController.GenerateUserPasswordResetLink(account.ItemId, account.AccountId, out token, string.Empty, passwordResetUrl);
+
if (!string.IsNullOrEmpty(passwordResetUrl))
{
items["PswResetUrl"] = passwordResetUrl;
@@ -2696,8 +2696,8 @@ namespace WebsitePanel.EnterpriseServer
if (to == null)
to = user.Email;
- subject = EvaluateMailboxTemplate(itemId, accountId, false, true, signup, subject);
- body = EvaluateMailboxTemplate(itemId, accountId, false, true, signup, body);
+ subject = EvaluateMailboxTemplate(itemId, accountId, false, true, signup, subject, string.Empty);
+ body = EvaluateMailboxTemplate(itemId, accountId, false, true, signup, body, string.Empty);
// send message
return MailHelper.SendMessage(from, to, cc, subject, body, priority, isHtml);
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs
index 2b3165f1..13d20ed1 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs
@@ -1858,18 +1858,23 @@ namespace WebsitePanel.EnterpriseServer
return SystemController.GetSystemSettingsInternal(SystemSettings.WEBDAV_PORTAL_SETTINGS, false);
}
- public static string GenerateUserPasswordResetLink(int itemId, int accountId, out Guid tokenGuid, string pincode = null)
+ public static string GenerateUserPasswordResetLink(int itemId, int accountId, out Guid tokenGuid, string pincode = null, string resetUrl = null)
{
- string passwordResetUrlFormat = string.IsNullOrEmpty(pincode) ? "account/password-reset/step-2" : "account/password-reset/step-final";
-
var settings = GetWebDavSystemSettings();
+ tokenGuid = new Guid();
- if (settings == null || !settings.GetValueOrDefault(SystemSettings.WEBDAV_PASSWORD_RESET_ENABLED_KEY, false) ||!settings.Contains("WebdavPortalUrl"))
+ if (settings == null || !settings.GetValueOrDefault(SystemSettings.WEBDAV_PASSWORD_RESET_ENABLED_KEY, false) || !settings.Contains("WebdavPortalUrl"))
{
- tokenGuid = new Guid();
return string.Empty;
}
+ if (string.IsNullOrEmpty(resetUrl) == false)
+ {
+ return resetUrl;
+ }
+
+ string passwordResetUrlFormat = string.IsNullOrEmpty(pincode) ? "account/password-reset/step-2" : "account/password-reset/step-final";
+
var webdavPortalUrl = new Uri(settings["WebdavPortalUrl"]);
var token = CreateAccessToken(itemId, accountId, AccessTokenTypes.PasswrodReset);
@@ -1994,7 +1999,8 @@ namespace WebsitePanel.EnterpriseServer
AccountLockoutDuration = GetValueSafe(parts, 9, 0),
ResetAccountLockoutCounterAfter = GetValueSafe(parts, 10, 0),
LockoutSettingsEnabled = GetValueSafe(parts, 11, false),
- PasswordComplexityEnabled = GetValueSafe(parts, 11, true),
+ PasswordComplexityEnabled = GetValueSafe(parts, 12, true),
+ MaxPasswordAge = GetValueSafe(parts, 13, 42),
};
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esExchangeServer.asmx.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esExchangeServer.asmx.cs
index 7facde41..f3c56160 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esExchangeServer.asmx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esExchangeServer.asmx.cs
@@ -315,9 +315,9 @@ namespace WebsitePanel.EnterpriseServer
}
[WebMethod]
- public string GetMailboxSetupInstructions(int itemId, int accountId, bool pmm, bool emailMode, bool signup)
+ public string GetMailboxSetupInstructions(int itemId, int accountId, bool pmm, bool emailMode, bool signup, string passwordResetUrl)
{
- return ExchangeServerController.GetMailboxSetupInstructions(itemId, accountId, pmm, emailMode, signup);
+ return ExchangeServerController.GetMailboxSetupInstructions(itemId, accountId, pmm, emailMode, signup, passwordResetUrl);
}
[WebMethod]
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationPasswordSettings.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationPasswordSettings.cs
index cc00f552..1fc0ab6f 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationPasswordSettings.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationPasswordSettings.cs
@@ -5,6 +5,7 @@
public int MinimumLength { get; set; }
public int MaximumLength { get; set; }
public int EnforcePasswordHistory { get; set; }
+ public int MaxPasswordAge { get; set; }
public bool LockoutSettingsEnabled { get; set; }
public int AccountLockoutDuration { get; set; }
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/OrganizationProvider.cs b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/OrganizationProvider.cs
index e3b17f58..0a35e6d0 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/OrganizationProvider.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/OrganizationProvider.cs
@@ -740,7 +740,8 @@ namespace WebsitePanel.Providers.HostedSolution
cmd.Parameters.Add("MinPasswordLength", settings.MinimumLength);
cmd.Parameters.Add("PasswordHistoryCount", settings.EnforcePasswordHistory);
cmd.Parameters.Add("ComplexityEnabled", false);
- cmd.Parameters.Add("ReversibleEncryptionEnabled", false);
+ cmd.Parameters.Add("ReversibleEncryptionEnabled", false);
+ cmd.Parameters.Add("MaxPasswordAge", new TimeSpan(settings.MaxPasswordAge * 24, 0, 0));
if (settings.LockoutSettingsEnabled)
{
@@ -777,6 +778,7 @@ namespace WebsitePanel.Providers.HostedSolution
cmd.Parameters.Add("PasswordHistoryCount", settings.EnforcePasswordHistory);
cmd.Parameters.Add("ComplexityEnabled", false);
cmd.Parameters.Add("ReversibleEncryptionEnabled", false);
+ cmd.Parameters.Add("MaxPasswordAge", new TimeSpan(settings.MaxPasswordAge*24, 0, 0));
if (settings.LockoutSettingsEnabled)
{
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/RouteConfig.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/RouteConfig.cs
index d26285c0..022aa747 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/RouteConfig.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/RouteConfig.cs
@@ -48,6 +48,12 @@ namespace WebsitePanel.WebDavPortal
defaults: new { controller = "Account", action = "PasswordResetFinalStep", pincode = UrlParameter.Optional }
);
+ routes.MapRoute(
+ name: AccountRouteNames.PasswordResetSuccess,
+ url: "account/password-reset/success",
+ defaults: new { controller = "Account", action = "PasswordSuccessfullyChanged" }
+ );
+
routes.MapRoute(
name: AccountRouteNames.PasswordChange,
url: "account/profile/password-change",
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/Routes/AccountRouteNames.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/Routes/AccountRouteNames.cs
index cd3da37d..6d28ac8e 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/Routes/AccountRouteNames.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/Routes/AccountRouteNames.cs
@@ -16,6 +16,7 @@ namespace WebsitePanel.WebDavPortal.UI.Routes
public const string PasswordResetSms = "PasswordResetSmsRoute";
public const string PasswordResetSendSms = "PasswordResetSendSmsRoute";
public const string PasswordResetFinalStep = "PasswordResetFinalStepRoute";
+ public const string PasswordResetSuccess = "PasswordResetSuccess";
public const string PhoneNumberIsAvailible = "PhoneNumberIsAvailibleRoute";
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/AccountController.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/AccountController.cs
index 776aef2e..b63a7e2d 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/AccountController.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/AccountController.cs
@@ -299,7 +299,14 @@ namespace WebsitePanel.WebDavPortal.Controllers
AddMessage(MessageType.Success, Resources.Messages.PasswordSuccessfullyChanged);
- return RedirectToRoute(AccountRouteNames.Login);
+ return RedirectToRoute(AccountRouteNames.PasswordResetSuccess);
+ }
+
+ [HttpGet]
+ [AllowAnonymous]
+ public ActionResult PasswordSuccessfullyChanged()
+ {
+ return View();
}
[HttpGet]
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.Designer.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.Designer.cs
index deaab032..4fc8c9ae 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.Designer.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.Designer.cs
@@ -60,6 +60,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Account.
+ ///
+ public static string Account {
+ get {
+ return ResourceManager.GetString("Account", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Actions.
///
@@ -123,6 +132,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to You can now access your {0}..
+ ///
+ public static string CanAccessYourFormat {
+ get {
+ return ResourceManager.GetString("CanAccessYourFormat", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Cancel.
///
@@ -537,6 +555,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Your new password has been set..
+ ///
+ public static string NewPasswordBeenSet {
+ get {
+ return ResourceManager.GetString("NewPasswordBeenSet", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Confirm password.
///
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.resx b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.resx
index 232393d4..508f4a2d 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.resx
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.resx
@@ -396,4 +396,13 @@
Password never expires. If you want to change password then please click {0}.
+
+ Account
+
+
+ You can now access your {0}.
+
+
+ Your new password has been set.
+
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordSuccessfullyChanged.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordSuccessfullyChanged.cshtml
new file mode 100644
index 00000000..4051a02f
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordSuccessfullyChanged.cshtml
@@ -0,0 +1,18 @@
+@using WebsitePanel.WebDavPortal.Resources
+@using WebsitePanel.WebDavPortal.UI.Routes
+
+@{
+ string message = string.Format(UI.CanAccessYourFormat, Html.RouteLink(UI.Account,AccountRouteNames.Login));
+}
+
+
+
+
+
@Messages.PasswordSuccessfullyChanged
+
+
+
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/WebsitePanel.WebDavPortal.csproj b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/WebsitePanel.WebDavPortal.csproj
index 5125297a..62be767a 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/WebsitePanel.WebDavPortal.csproj
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/WebsitePanel.WebDavPortal.csproj
@@ -489,6 +489,7 @@
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/App_LocalResources/OrganizationSettingsPasswordSettings.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/App_LocalResources/OrganizationSettingsPasswordSettings.ascx.resx
index a513b285..e76f5f06 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/App_LocalResources/OrganizationSettingsPasswordSettings.ascx.resx
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/App_LocalResources/OrganizationSettingsPasswordSettings.ascx.resx
@@ -219,4 +219,13 @@
*
+
+ Max Password Age (days):
+
+
+ *
+
+
+ *
+
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeCreateMailbox.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeCreateMailbox.ascx.cs
index 84e1404d..5608b564 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeCreateMailbox.ascx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeCreateMailbox.ascx.cs
@@ -51,7 +51,7 @@ namespace WebsitePanel.Portal.ExchangeServer
{
BindPasswordSettings();
- string instructions = ES.Services.ExchangeServer.GetMailboxSetupInstructions(PanelRequest.ItemID, PanelRequest.AccountID, false, false, false);
+ string instructions = ES.Services.ExchangeServer.GetMailboxSetupInstructions(PanelRequest.ItemID, PanelRequest.AccountID, false, false, false, " ");
if (!string.IsNullOrEmpty(instructions))
{
chkSendInstructions.Checked = chkSendInstructions.Visible = sendInstructionEmail.Visible = true;
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeMailboxSetupInstructions.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeMailboxSetupInstructions.ascx.cs
index cac46a87..74247673 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeMailboxSetupInstructions.ascx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeMailboxSetupInstructions.ascx.cs
@@ -47,7 +47,12 @@ namespace WebsitePanel.Portal.ExchangeServer
// load content
litContent.Text = ES.Services.ExchangeServer.GetMailboxSetupInstructions(
PanelRequest.ItemID, PanelRequest.AccountID,
- false, false, false);
+ false, false, false,
+ PortalUtils.EditUrl("ItemID", PanelRequest.ItemID.ToString(),
+ "user_reset_password",
+ "SpaceID=" + PanelSecurity.PackageId,
+ "Context=Mailbox",
+ "AccountID=" + PanelRequest.AccountID).Trim('~'));
// bind user details
PackageInfo package = ES.Services.Packages.GetPackage(PanelSecurity.PackageId);
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx
index b9cc4ccb..f674f3d8 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx
@@ -7,35 +7,35 @@
<%@ Register Src="../UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" TagPrefix="wsp" %>
-
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
-
+
-
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
- |
+
+ |
|
- |
+
+ |
- |
+
- |
+
+ |
|
+
+
+ |
+
+
+
+ |
+
-
+
|
- |
+
+ |
|
-
+ |
+
|
-
+ |
+
-
+
|
|
@@ -116,31 +132,34 @@
-
+ |
+
- |
+
|
-
+ |
+
- |
+
|
-
+ |
+
-
+
|
|
-
-
-
-
-
-
-
-
-
\ No newline at end of file
+
+
+
+
+
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx.cs
index 48ceea57..de5799fe 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx.cs
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
+using System.Globalization;
using System.Linq;
using System.Web;
using System.Web.UI;
@@ -59,6 +60,8 @@ namespace WebsitePanel.Portal.ExchangeServer
txtResetAccountLockout.Text = PasswordPolicyEditor.GetValueSafe(parts, 10, "0");
chkLockOutSettigns.Checked = PasswordPolicyEditor.GetValueSafe(parts, 11, false);
chkPasswordComplexity.Checked = PasswordPolicyEditor.GetValueSafe(parts, 12, true);
+
+ txtMaxPasswordAge.Text = PasswordPolicyEditor.GetValueSafe(parts, 13, "42");
}
private void BindSettings(OrganizationPasswordSettings settings)
@@ -75,6 +78,8 @@ namespace WebsitePanel.Portal.ExchangeServer
txtResetAccountLockout.Text = settings.ResetAccountLockoutCounterAfter.ToString();
chkLockOutSettigns.Checked = settings.LockoutSettingsEnabled;
chkPasswordComplexity.Checked = settings.PasswordComplexityEnabled;
+
+ txtMaxPasswordAge.Text = settings.MaxPasswordAge.ToString();
}
private OrganizationPasswordSettings GetSettings()
@@ -94,6 +99,8 @@ namespace WebsitePanel.Portal.ExchangeServer
settings.LockoutSettingsEnabled = chkLockOutSettigns.Checked;
settings.PasswordComplexityEnabled =chkPasswordComplexity.Checked;
+ settings.MaxPasswordAge = Utils.ParseInt(txtMaxPasswordAge.Text, 42);
+
return settings;
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx.designer.cs
index 0b6398ac..67d8ca05 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx.designer.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/OrganizationSettingsPasswordSettings.ascx.designer.cs
@@ -210,6 +210,42 @@ namespace WebsitePanel.Portal.ExchangeServer {
///
protected global::System.Web.UI.WebControls.RegularExpressionValidator valCorrectEnforcePasswordHistory;
+ ///
+ /// lblMaxPasswordAge control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.Label lblMaxPasswordAge;
+
+ ///
+ /// txtMaxPasswordAge control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.TextBox txtMaxPasswordAge;
+
+ ///
+ /// valRequireMaxPasswordAge control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.RequiredFieldValidator valRequireMaxPasswordAge;
+
+ ///
+ /// valCorrectMaxPasswordAge control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.RegularExpressionValidator valCorrectMaxPasswordAge;
+
///
/// RowChkLockOutSettigns control.
///
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/UserControls/MailboxTabs.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/UserControls/MailboxTabs.ascx.cs
index 5dd96f73..adc6e55e 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/UserControls/MailboxTabs.ascx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/UserControls/MailboxTabs.ascx.cs
@@ -70,7 +70,7 @@ namespace WebsitePanel.Portal.ExchangeServer.UserControls
if (!hideItems) tabsList.Add(CreateTab("mailbox_mailflow", "Tab.Mailflow"));
if (!hideItems) tabsList.Add(CreateTab("mailbox_permissions", "Tab.Permissions"));
- string instructions = ES.Services.ExchangeServer.GetMailboxSetupInstructions(PanelRequest.ItemID, PanelRequest.AccountID, false, false, false);
+ string instructions = ES.Services.ExchangeServer.GetMailboxSetupInstructions(PanelRequest.ItemID, PanelRequest.AccountID, false, false, false, " ");
if (!string.IsNullOrEmpty(instructions))
tabsList.Add(CreateTab("mailbox_setup", "Tab.Setup"));
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/App_LocalResources/PasswordPolicyEditor.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/App_LocalResources/PasswordPolicyEditor.ascx.resx
index ea3bf9da..8a6a32e8 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/App_LocalResources/PasswordPolicyEditor.ascx.resx
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/App_LocalResources/PasswordPolicyEditor.ascx.resx
@@ -210,4 +210,13 @@
*
+
+ Max Password Age (days):
+
+
+ *
+
+
+ *
+
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/PasswordPolicyEditor.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/PasswordPolicyEditor.ascx
index 0180aba1..3f2d00f4 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/PasswordPolicyEditor.ascx
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/PasswordPolicyEditor.ascx
@@ -37,6 +37,16 @@
+
+ |
+
+
+
+ |
+
(string[] array, int index, T defaultValue)
{
- if (array.Length > index)
+ try
{
- if (string.IsNullOrEmpty(array[index]))
+ if (array.Length > index)
{
- return defaultValue;
- }
+ if (string.IsNullOrEmpty(array[index]))
+ {
+ return defaultValue;
+ }
- return (T)Convert.ChangeType(array[index], typeof(T));
+ return (T)Convert.ChangeType(array[index], typeof(T));
+ }
}
+ catch{}
return defaultValue;
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/PasswordPolicyEditor.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/PasswordPolicyEditor.ascx.designer.cs
index 557e0e74..ee474023 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/PasswordPolicyEditor.ascx.designer.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/UserControls/PasswordPolicyEditor.ascx.designer.cs
@@ -147,6 +147,42 @@ namespace WebsitePanel.Portal {
///
protected global::System.Web.UI.WebControls.RegularExpressionValidator valCorrectEnforcePasswordHistory;
+ ///
+ /// lblMaxPasswordAge control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.Label lblMaxPasswordAge;
+
+ ///
+ /// txtMaxPasswordAge control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.TextBox txtMaxPasswordAge;
+
+ ///
+ /// valRequireMaxPasswordAge control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.RequiredFieldValidator valRequireMaxPasswordAge;
+
+ ///
+ /// valCorrectMaxPasswordAge control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.RegularExpressionValidator valCorrectMaxPasswordAge;
+
///
/// RowChkLockOutSettigns control.
///
|