diff --git a/WebsitePanel/Database/update_db.sql b/WebsitePanel/Database/update_db.sql
index 1e4c80fe..7598159f 100644
--- a/WebsitePanel/Database/update_db.sql
+++ b/WebsitePanel/Database/update_db.sql
@@ -3812,6 +3812,7 @@ ALTER TABLE [dbo].[ExchangeAccounts] ADD
END
GO
+-- Password column removed
ALTER PROCEDURE [dbo].[GetExchangeAccount]
(
@ItemID int,
@@ -3828,7 +3829,6 @@ SELECT
E.MailEnabledPublicFolder,
E.MailboxManagerActions,
E.SamAccountName,
- E.AccountPassword,
E.MailboxPlanId,
P.MailboxPlan,
E.SubscriberNumber,
@@ -3847,7 +3847,7 @@ RETURN
GO
-
+-- Password column removed
ALTER PROCEDURE [dbo].[GetExchangeAccountByAccountName]
(
@ItemID int,
@@ -3864,7 +3864,6 @@ SELECT
E.MailEnabledPublicFolder,
E.MailboxManagerActions,
E.SamAccountName,
- E.AccountPassword,
E.MailboxPlanId,
P.MailboxPlan,
E.SubscriberNumber,
@@ -3886,7 +3885,7 @@ GO
-
+-- Password column removed
ALTER PROCEDURE [dbo].[GetExchangeAccountByMailboxPlanId]
(
@ItemID int,
@@ -3906,7 +3905,6 @@ SELECT
E.MailEnabledPublicFolder,
E.MailboxManagerActions,
E.SamAccountName,
- E.AccountPassword,
E.MailboxPlanId,
P.MailboxPlan,
E.SubscriberNumber,
@@ -3938,7 +3936,6 @@ SELECT
E.MailEnabledPublicFolder,
E.MailboxManagerActions,
E.SamAccountName,
- E.AccountPassword,
E.MailboxPlanId,
P.MailboxPlan,
E.SubscriberNumber,
@@ -3966,7 +3963,6 @@ SELECT
E.MailEnabledPublicFolder,
E.MailboxManagerActions,
E.SamAccountName,
- E.AccountPassword,
E.MailboxPlanId,
P.MailboxPlan,
E.SubscriberNumber,
@@ -4098,7 +4094,7 @@ RETURN
GO
-
+-- Password column removed
ALTER PROCEDURE [dbo].[UpdateExchangeAccount]
(
@AccountID int,
@@ -4109,7 +4105,6 @@ ALTER PROCEDURE [dbo].[UpdateExchangeAccount]
@SamAccountName nvarchar(100),
@MailEnabledPublicFolder bit,
@MailboxManagerActions varchar(200),
- @Password varchar(200),
@MailboxPlanId int,
@ArchivingMailboxPlanId int,
@SubscriberNumber varchar(32),
@@ -4146,14 +4141,6 @@ IF (@@ERROR <> 0 )
RETURN -1
END
-UPDATE ExchangeAccounts SET
- AccountPassword = @Password WHERE AccountID = @AccountID AND @Password IS NOT NULL
-
-IF (@@ERROR <> 0 )
- BEGIN
- ROLLBACK TRANSACTION
- RETURN -1
- END
COMMIT TRAN
RETURN
@@ -5046,6 +5033,7 @@ exec sp_executesql @sql, N'@ItemID int, @IncludeMailboxes bit',
RETURN
GO
+-- Password column removed
ALTER PROCEDURE [dbo].[GetExchangeAccount]
(
@ItemID int,
@@ -5062,7 +5050,6 @@ SELECT
E.MailEnabledPublicFolder,
E.MailboxManagerActions,
E.SamAccountName,
- E.AccountPassword,
E.MailboxPlanId,
P.MailboxPlan,
E.SubscriberNumber,
@@ -6073,7 +6060,7 @@ WHERE Id = @Id
GO
-
+-- Password column removed
IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'GetRDSCollectionUsersByRDSCollectionId')
DROP PROCEDURE GetRDSCollectionUsersByRDSCollectionId
GO
@@ -6092,7 +6079,6 @@ SELECT
[MailEnabledPublicFolder],
[MailboxManagerActions],
[SamAccountName],
- [AccountPassword],
[CreatedDate],
[MailboxPlanId],
[SubscriberNumber],
@@ -8228,6 +8214,8 @@ AS
WHERE SIP.PropertyName = 'RamSize' AND PT.ParentPackageID = @PackageID)
DECLARE @Result2 int = (SELECT SUM(CAST(SIP.PropertyValue AS int)) FROM ServiceItemProperties AS SIP
INNER JOIN ServiceItems AS SI ON SIP.ItemID = SI.ItemID
+ INNER JOIN ServiceItemProperties AS SIP2 ON
+ SIP2.ItemID = SI.ItemID AND SIP2.PropertyName = 'DynamicMemory.Enabled' AND SIP2.PropertyValue = 'True'
INNER JOIN PackagesTreeCache AS PT ON SI.PackageID = PT.PackageID
WHERE SIP.PropertyName = 'DynamicMemory.Maximum' AND PT.ParentPackageID = @PackageID)
SET @Result = CASE WHEN isnull(@Result1,0) > isnull(@Result2,0) THEN @Result1 ELSE @Result2 END
@@ -8723,7 +8711,7 @@ RETURN
GO
-
+-- Password column removed
IF OBJECTPROPERTY(object_id('dbo.GetExchangeAccountByAccountNameWithoutItemId'), N'IsProcedure') = 1
DROP PROCEDURE [dbo].[GetExchangeAccountByAccountNameWithoutItemId]
GO
@@ -8742,7 +8730,6 @@ SELECT
E.MailEnabledPublicFolder,
E.MailboxManagerActions,
E.SamAccountName,
- E.AccountPassword,
E.MailboxPlanId,
P.MailboxPlan,
E.SubscriberNumber,
@@ -9799,6 +9786,906 @@ GO
UPDATE [dbo].[ServiceItemTypes] SET TypeName ='WebsitePanel.Providers.SharePoint.SharePointEnterpriseSiteCollection, WebsitePanel.Providers.Base' WHERE DisplayName = 'SharePointEnterpriseSiteCollection'
GO
+-- USER PASSWORD EXPIRATION NOTIFICATION tasks
+
+IF NOT EXISTS (SELECT * FROM [dbo].[ScheduleTasks] WHERE [TaskID] = N'SCHEDULE_TASK_USER_PASSWORD_EXPIRATION_NOTIFICATION')
+BEGIN
+INSERT [dbo].[ScheduleTasks] ([TaskID], [TaskType], [RoleID]) VALUES (N'SCHEDULE_TASK_USER_PASSWORD_EXPIRATION_NOTIFICATION', N'WebsitePanel.EnterpriseServer.UserPasswordExpirationNotificationTask, WebsitePanel.EnterpriseServer.Code', 1)
+END
+GO
+
+IF NOT EXISTS (SELECT * FROM [dbo].[ScheduleTaskViewConfiguration] WHERE [TaskID] = N'SCHEDULE_TASK_USER_PASSWORD_EXPIRATION_NOTIFICATION')
+BEGIN
+INSERT [dbo].[ScheduleTaskViewConfiguration] ([TaskID], [ConfigurationID], [Environment], [Description]) VALUES (N'SCHEDULE_TASK_USER_PASSWORD_EXPIRATION_NOTIFICATION', N'ASP_NET', N'ASP.NET', N'~/DesktopModules/WebsitePanel/ScheduleTaskControls/UserPasswordExpirationNotificationView.ascx')
+END
+GO
+
+IF NOT EXISTS (SELECT * FROM [dbo].[ScheduleTaskParameters] WHERE [TaskID] = N'SCHEDULE_TASK_USER_PASSWORD_EXPIRATION_NOTIFICATION' AND [ParameterID]= N'DAYS_BEFORE_EXPIRATION' )
+BEGIN
+INSERT [dbo].[ScheduleTaskParameters] ([TaskID], [ParameterID], [DataTypeID], [DefaultValue], [ParameterOrder]) VALUES (N'SCHEDULE_TASK_USER_PASSWORD_EXPIRATION_NOTIFICATION', N'DAYS_BEFORE_EXPIRATION', N'String', NULL, 1)
+END
+GO
+
+
+-- USER PASSWORD EXPIRATION EMAIL TEMPLATE
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordExpirationLetter' AND [PropertyName]= N'From' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordExpirationLetter', N'From', N'support@HostingCompany.com')
+END
+GO
+
+DECLARE @UserPasswordExpirationLetterHtmlBody nvarchar(2500)
+
+Set @UserPasswordExpirationLetterHtmlBody = N'
+
+ Password expiration notification
+
+
+
+
+
+
Password expiration notification
+
+
+
+Hello #user.FirstName#,
+
+
+
+
+Your password expiration date is #user.PasswordExpirationDateTime#. You can reset your own password by visiting the following page:
+
+
+
#passwordResetLink#
+
+
+
+If you have any questions regarding your hosting account, feel free to contact our support department at any time.
+
+
+
+Best regards
+
+
+';
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordExpirationLetter' AND [PropertyName]= N'HtmlBody' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordExpirationLetter', N'HtmlBody', @UserPasswordExpirationLetterHtmlBody)
+END
+ELSE
+UPDATE [dbo].[UserSettings] SET [PropertyValue] = @UserPasswordExpirationLetterHtmlBody WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordExpirationLetter' AND [PropertyName]= N'HtmlBody'
+GO
+
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordExpirationLetter' AND [PropertyName]= N'Priority' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordExpirationLetter', N'Priority', N'Normal')
+END
+GO
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordExpirationLetter' AND [PropertyName]= N'Subject' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordExpirationLetter', N'Subject', N'Password expiration notification')
+END
+GO
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordExpirationLetter' AND [PropertyName]= N'LogoUrl' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordExpirationLetter', N'LogoUrl', N'https://controlpanel.virtuworks.net/App_Themes/Default/Images/logo.png')
+END
+GO
+
+
+DECLARE @UserPasswordExpirationLetterTextBody nvarchar(2500)
+
+Set @UserPasswordExpirationLetterTextBody = N'=========================================
+ Password expiration notification
+=========================================
+
+
+Hello #user.FirstName#,
+
+
+Your password expiration date is #user.PasswordExpirationDateTime#. You can reset your own password by visiting the following page:
+
+#passwordResetLink#
+
+If you have any questions regarding your hosting account, feel free to contact our support department at any time.
+
+Best regards'
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordExpirationLetter' AND [PropertyName]= N'TextBody' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordExpirationLetter', N'TextBody', @UserPasswordExpirationLetterTextBody)
+END
+ELSE
+UPDATE [dbo].[UserSettings] SET [PropertyValue] = @UserPasswordExpirationLetterTextBody WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordExpirationLetter' AND [PropertyName]= N'TextBody'
+GO
+
+
+-- USER PASSWORD RESET EMAIL TEMPLATE
+
+
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordResetLetter' AND [PropertyName]= N'From' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordResetLetter', N'From', N'support@HostingCompany.com')
+END
+GO
+
+DECLARE @UserPasswordResetLetterHtmlBody nvarchar(2500)
+
+Set @UserPasswordResetLetterHtmlBody = N'
+
+ Password reset notification
+
+
+
+
+
+
Password reset notification
+
+
+
+Hello #user.FirstName#,
+
+
+
+
+We received a request to reset the password for your account. If you made this request, click the link below. If you did not make this request, you can ignore this email.
+
+
+
#passwordResetLink#
+
+
+
+If you have any questions regarding your hosting account, feel free to contact our support department at any time.
+
+
+
+Best regards
+
+
+';
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordResetLetter' AND [PropertyName]= N'HtmlBody' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordResetLetter', N'HtmlBody', @UserPasswordResetLetterHtmlBody)
+END
+ELSE
+UPDATE [dbo].[UserSettings] SET [PropertyValue] = @UserPasswordResetLetterHtmlBody WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordResetLetter' AND [PropertyName]= N'HtmlBody'
+GO
+
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordResetLetter' AND [PropertyName]= N'Priority' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordResetLetter', N'Priority', N'Normal')
+END
+GO
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordResetLetter' AND [PropertyName]= N'Subject' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordResetLetter', N'Subject', N'Password reset notification')
+END
+GO
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordResetLetter' AND [PropertyName]= N'LogoUrl' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordResetLetter', N'LogoUrl', N'https://controlpanel.virtuworks.net/App_Themes/Default/Images/logo.png')
+END
+GO
+
+
+DECLARE @UserPasswordResetLetterTextBody nvarchar(2500)
+
+Set @UserPasswordResetLetterTextBody = N'=========================================
+ Password reset notification
+=========================================
+
+
+Hello #user.FirstName#,
+
+
+We received a request to reset the password for your account. If you made this request, click the link below. If you did not make this request, you can ignore this email.
+
+#passwordResetLink#
+
+If you have any questions regarding your hosting account, feel free to contact our support department at any time.
+
+Best regards'
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordResetLetter' AND [PropertyName]= N'TextBody' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'UserPasswordResetLetter', N'TextBody', @UserPasswordResetLetterTextBody)
+END
+ELSE
+UPDATE [dbo].[UserSettings] SET [PropertyValue] = @UserPasswordResetLetterTextBody WHERE [UserID] = 1 AND [SettingsName]= N'UserPasswordResetLetter' AND [PropertyName]= N'TextBody'
+GO
+
+
+-- Exchange setup EMAIL TEMPLATE
+
+
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'ExchangeMailboxSetupLetter' AND [PropertyName]= N'From' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'ExchangeMailboxSetupLetter', N'From', N'orders@virtuworks.com')
+END
+GO
+
+DECLARE @ExchangeMailboxSetupLetterHtmlBody nvarchar(max)
+
+Set @ExchangeMailboxSetupLetterHtmlBody = N'
+
+ Account Summary Information
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Hello #Account.DisplayName#,
+
+
+ Thanks for choosing VirtuWorks as your Exchange hosting provider.
+
+
+
+ User Accounts
+
+ The following user accounts have been created for you.
+
+
+
+ Username:
+ #Account.UserPrincipalName#
+
+
+ E-mail:
+ #Account.PrimaryEmailAddress#
+
+
+
+ Password Reset Url:
+ Click here
+
+
+
+
+
DNS
+
+ In order for us to accept mail for your domain, you will need to point your MX records to:
+
+
+
+ Webmail (OWA, Outlook Web Access)
+
+ https://mail.virtuworks.net/owa
+
+
+ Outlook (Windows Clients)
+
+ To configure Outlook 2013 to work with the VirtuWorks servers, please reference:
+
+
+ http://www.virtuworks.com/how-to-configure-my-outlook-2010-client-to-work-with-my-velum-hosted-exchange-account/
+
+
+ If you need to download and install the Outlook client:
+
+
+
+
+
+ ActiveSync, iPhone, iPad
+
+
+ Server:
+ #ActiveSyncServer#
+
+
+ Domain:
+ #SamDomain#
+
+
+ SSL:
+ must be checked
+
+
+ Your username:
+ #SamUsername#
+
+
+
+
Password Changes
+
+ Passwords can be changed at any time using Webmail or the Control Panel .
+
Control Panel
+
+ If you need to change the details of your account, you can easily do this using Control Panel .
+
Support
+
+ You have 2 options, email help@virtuworks.com or use the web interface at http://www.virtuworks.com/support
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+';
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'ExchangeMailboxSetupLetter' AND [PropertyName]= N'HtmlBody' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'ExchangeMailboxSetupLetter', N'HtmlBody', @ExchangeMailboxSetupLetterHtmlBody)
+END
+ELSE
+UPDATE [dbo].[UserSettings] SET [PropertyValue] = @ExchangeMailboxSetupLetterHtmlBody WHERE [UserID] = 1 AND [SettingsName]= N'ExchangeMailboxSetupLetter' AND [PropertyName]= N'HtmlBody'
+GO
+
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'ExchangeMailboxSetupLetter' AND [PropertyName]= N'Priority' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'ExchangeMailboxSetupLetter', N'Priority', N'Normal')
+END
+GO
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'ExchangeMailboxSetupLetter' AND [PropertyName]= N'Subject' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'ExchangeMailboxSetupLetter', N'Subject', N'Virtuworks Hosted Exchange Mailbox Setup')
+END
+GO
+
+
+DECLARE @ExchangeMailboxSetupLetterTextBody nvarchar(2500)
+
+Set @ExchangeMailboxSetupLetterTextBody = N'
+Hello #Account.DisplayName#,
+
+Thanks for choosing VirtuWorks as your Exchange hosting provider.
+
+
+User Accounts
+
+The following user accounts have been created for you.
+
+Username: #Account.UserPrincipalName#
+E-mail: #Account.PrimaryEmailAddress#
+
+Password Reset Url: #PswResetUrl#
+
+
+
+=================================
+DNS
+=================================
+
+In order for us to accept mail for your domain, you will need to point your MX records to:
+
+#SmtpServer#
+
+=================================
+Webmail (OWA, Outlook Web Access)
+=================================
+
+https://mail.virtuworks.net/owa
+
+=================================
+Outlook (Windows Clients)
+=================================
+
+To configure Outlook 2010 to work with VirtuWorks servers, please reference:
+
+https://portal.virtuworks.net/whmcs/knowledgebase.php?action=displayarticle&id=2
+
+If you need to download and install the Outlook 2010 client:
+
+Outlook 2010 Download URL:
+32 Bit - http://www.virtuworks.net/downloads/Outlook2010-32bit.zip
+64 Bit - http://www.virtuworks.net/downloads/Outlook2010-64bit.zip
+KEY: HXGFV-DY3HM-4W2BQ-3R7KQ-K8P49
+
+=================================
+ActiveSync, iPhone, iPad
+=================================
+
+Server: #ActiveSyncServer#
+Domain: #SamDomain#
+SSL: must be checked
+Your username: #SamUsername#
+
+=================================
+Password Changes
+=================================
+
+Passwords can be changed at any time using Webmail or the Control Panel (https://controlpanel.virtuworks.net).
+
+
+=================================
+Control Panel
+=================================
+
+If you need to change the details of your account, you can easily do this using the Control Panel (https://controlpanel.virtuworks.net).
+
+
+=================================
+Support
+=================================
+
+You have 2 options, email help@virtuworks.com or use the web interface at http://www.virtuworks.com/contact/'
+
+IF NOT EXISTS (SELECT * FROM [dbo].[UserSettings] WHERE [UserID] = 1 AND [SettingsName]= N'ExchangeMailboxSetupLetter' AND [PropertyName]= N'TextBody' )
+BEGIN
+INSERT [dbo].[UserSettings] ([UserID], [SettingsName], [PropertyName], [PropertyValue]) VALUES (1, N'ExchangeMailboxSetupLetter', N'TextBody', @ExchangeMailboxSetupLetterTextBody)
+END
+ELSE
+UPDATE [dbo].[UserSettings] SET [PropertyValue] = @ExchangeMailboxSetupLetterTextBody WHERE [UserID] = 1 AND [SettingsName]= N'ExchangeMailboxSetupLetter' AND [PropertyName]= N'TextBody'
+GO
+
+
+
+-- ORGANIZATION USER PASSWORD RESET TOKENS
+
+
+IF EXISTS (SELECT * FROM SYS.TABLES WHERE name = 'AccessTokens')
+DROP TABLE AccessTokens
+GO
+CREATE TABLE AccessTokens
+(
+ ID INT IDENTITY(1,1) NOT NULL PRIMARY KEY,
+ AccessTokenGuid UNIQUEIDENTIFIER NOT NULL,
+ ExpirationDate DATETIME NOT NULL,
+ AccountID INT NOT NULL ,
+ ItemId INT NOT NULL,
+ TokenType INT NOT NULL,
+ SmsResponse varchar(100)
+)
+GO
+
+ALTER TABLE [dbo].[AccessTokens] WITH CHECK ADD CONSTRAINT [FK_AccessTokens_UserId] FOREIGN KEY([AccountID])
+REFERENCES [dbo].[ExchangeAccounts] ([AccountID])
+ON DELETE CASCADE
+GO
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'AddAccessToken')
+DROP PROCEDURE AddAccessToken
+GO
+CREATE PROCEDURE [dbo].[AddAccessToken]
+(
+ @TokenID INT OUTPUT,
+ @AccessToken UNIQUEIDENTIFIER,
+ @ExpirationDate DATETIME,
+ @AccountID INT,
+ @ItemId INT,
+ @TokenType INT
+)
+AS
+INSERT INTO AccessTokens
+(
+ AccessTokenGuid,
+ ExpirationDate,
+ AccountID ,
+ ItemId,
+ TokenType
+)
+VALUES
+(
+ @AccessToken ,
+ @ExpirationDate ,
+ @AccountID,
+ @ItemId,
+ @TokenType
+)
+
+SET @TokenID = SCOPE_IDENTITY()
+
+RETURN
+GO
+
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'SetAccessTokenSmsResponse')
+DROP PROCEDURE SetAccessTokenSmsResponse
+GO
+CREATE PROCEDURE [dbo].[SetAccessTokenSmsResponse]
+(
+ @AccessToken UNIQUEIDENTIFIER,
+ @SmsResponse varchar(100)
+)
+AS
+UPDATE [dbo].[AccessTokens] SET [SmsResponse] = @SmsResponse WHERE [AccessTokenGuid] = @AccessToken
+RETURN
+GO
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'DeleteAccessToken')
+DROP PROCEDURE DeleteAccessToken
+GO
+CREATE PROCEDURE [dbo].[DeleteAccessToken]
+(
+ @AccessToken UNIQUEIDENTIFIER,
+ @TokenType INT
+)
+AS
+DELETE FROM AccessTokens
+WHERE AccessTokenGuid = @AccessToken AND TokenType = @TokenType
+GO
+
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'DeleteExpiredAccessTokenTokens')
+DROP PROCEDURE DeleteExpiredAccessTokenTokens
+GO
+CREATE PROCEDURE [dbo].[DeleteExpiredAccessTokenTokens]
+AS
+DELETE FROM AccessTokens
+WHERE ExpirationDate < getdate()
+GO
+
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'GetAccessTokenByAccessToken')
+DROP PROCEDURE GetAccessTokenByAccessToken
+GO
+CREATE PROCEDURE [dbo].[GetAccessTokenByAccessToken]
+(
+ @AccessToken UNIQUEIDENTIFIER,
+ @TokenType INT
+)
+AS
+SELECT
+ ID ,
+ AccessTokenGuid,
+ ExpirationDate,
+ AccountID,
+ ItemId,
+ TokenType,
+ SmsResponse
+ FROM AccessTokens
+ Where AccessTokenGuid = @AccessToken AND ExpirationDate > getdate() AND TokenType = @TokenType
+GO
+
+
+-- ORGANIZATION SETTINGS
+
+
+IF NOT EXISTS (SELECT * FROM SYS.TABLES WHERE name = 'ExchangeOrganizationSettings')
+BEGIN
+ CREATE TABLE ExchangeOrganizationSettings
+ (
+ ItemId INT NOT NULL,
+ SettingsName nvarchar(100) NOT NULL,
+ Xml nvarchar(max) NOT NULL
+ );
+
+ ALTER TABLE [dbo].[ExchangeOrganizationSettings] WITH CHECK ADD CONSTRAINT [FK_ExchangeOrganizationSettings_ExchangeOrganizations_ItemId] FOREIGN KEY([ItemId])
+ REFERENCES [dbo].[ExchangeOrganizations] ([ItemId])
+ ON DELETE CASCADE;
+END
+
+
+
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'UpdateExchangeOrganizationSettings')
+DROP PROCEDURE UpdateExchangeOrganizationSettings
+GO
+CREATE PROCEDURE [dbo].[UpdateExchangeOrganizationSettings]
+(
+ @ItemId INT ,
+ @SettingsName nvarchar(100) ,
+ @Xml nvarchar(max)
+)
+AS
+IF NOT EXISTS (SELECT * FROM [dbo].[ExchangeOrganizationSettings] WHERE [ItemId] = @ItemId AND [SettingsName]= @SettingsName )
+BEGIN
+INSERT [dbo].[ExchangeOrganizationSettings] ([ItemId], [SettingsName], [Xml]) VALUES (@ItemId, @SettingsName, @Xml)
+END
+ELSE
+UPDATE [dbo].[ExchangeOrganizationSettings] SET [Xml] = @Xml WHERE [ItemId] = @ItemId AND [SettingsName]= @SettingsName
+GO
+
+
+
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'GetExchangeOrganizationSettings')
+DROP PROCEDURE GetExchangeOrganizationSettings
+GO
+CREATE PROCEDURE [dbo].[GetExchangeOrganizationSettings]
+(
+ @ItemId INT ,
+ @SettingsName nvarchar(100)
+)
+AS
+SELECT
+ ItemId,
+ SettingsName,
+ Xml
+
+FROM ExchangeOrganizationSettings
+Where ItemId = @ItemId AND SettingsName = @SettingsName
+GO
+
+
+-- Exchange Account password column removed
+
+if exists(select * from sys.columns
+ where Name = N'AccountPassword' and Object_ID = Object_ID(N'ExchangeAccounts'))
+begin
+ ALTER TABLE [ExchangeAccounts] DROP COLUMN [AccountPassword]
+end
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'AddExchangeAccount')
+DROP PROCEDURE AddExchangeAccount
+GO
+CREATE PROCEDURE [dbo].[AddExchangeAccount]
+(
+ @AccountID int OUTPUT,
+ @ItemID int,
+ @AccountType int,
+ @AccountName nvarchar(300),
+ @DisplayName nvarchar(300),
+ @PrimaryEmailAddress nvarchar(300),
+ @MailEnabledPublicFolder bit,
+ @MailboxManagerActions varchar(200),
+ @SamAccountName nvarchar(100),
+ @MailboxPlanId int,
+ @SubscriberNumber nvarchar(32)
+)
+AS
+
+INSERT INTO ExchangeAccounts
+(
+ ItemID,
+ AccountType,
+ AccountName,
+ DisplayName,
+ PrimaryEmailAddress,
+ MailEnabledPublicFolder,
+ MailboxManagerActions,
+ SamAccountName,
+ MailboxPlanId,
+ SubscriberNumber,
+ UserPrincipalName
+)
+VALUES
+(
+ @ItemID,
+ @AccountType,
+ @AccountName,
+ @DisplayName,
+ @PrimaryEmailAddress,
+ @MailEnabledPublicFolder,
+ @MailboxManagerActions,
+ @SamAccountName,
+ @MailboxPlanId,
+ @SubscriberNumber,
+ @PrimaryEmailAddress
+)
+
+SET @AccountID = SCOPE_IDENTITY()
+
+RETURN
+
+GO
+SET ANSI_NULLS ON
+GO
+SET QUOTED_IDENTIFIER ON
+GO
+
+
+
+IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'SearchExchangeAccount')
+DROP PROCEDURE SearchExchangeAccount
+GO
+CREATE PROCEDURE [dbo].[SearchExchangeAccount]
+(
+ @ActorID int,
+ @AccountType int,
+ @PrimaryEmailAddress nvarchar(300)
+)
+AS
+
+DECLARE @PackageID int
+DECLARE @ItemID int
+DECLARE @AccountID int
+
+SELECT
+ @AccountID = AccountID,
+ @ItemID = ItemID
+FROM ExchangeAccounts
+WHERE PrimaryEmailAddress = @PrimaryEmailAddress
+AND AccountType = @AccountType
+
+
+-- check space rights
+SELECT @PackageID = PackageID FROM ServiceItems
+WHERE ItemID = @ItemID
+
+IF dbo.CheckActorPackageRights(@ActorID, @PackageID) = 0
+RAISERROR('You are not allowed to access this package', 16, 1)
+
+SELECT
+ AccountID,
+ ItemID,
+ @PackageID AS PackageID,
+ AccountType,
+ AccountName,
+ DisplayName,
+ PrimaryEmailAddress,
+ MailEnabledPublicFolder,
+ MailboxManagerActions,
+ SamAccountName,
+ SubscriberNumber,
+ UserPrincipalName
+FROM ExchangeAccounts
+WHERE AccountID = @AccountID
+
+RETURN
+
+
+GO
+SET ANSI_NULLS ON
+GO
+SET QUOTED_IDENTIFIER OFF
+GO
+
IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'GetSearchObject')
DROP PROCEDURE GetSearchObject
diff --git a/WebsitePanel/Sources/Tools/WebsitePanel.Import.Enterprise/OrganizationImporter.cs b/WebsitePanel/Sources/Tools/WebsitePanel.Import.Enterprise/OrganizationImporter.cs
index 9e8cbddf..92a0eafb 100644
--- a/WebsitePanel/Sources/Tools/WebsitePanel.Import.Enterprise/OrganizationImporter.cs
+++ b/WebsitePanel/Sources/Tools/WebsitePanel.Import.Enterprise/OrganizationImporter.cs
@@ -969,13 +969,13 @@ namespace WebsitePanel.Import.Enterprise
{
return DataProvider.AddExchangeAccount(itemId, (int)accountType,
accountName, displayName, primaryEmailAddress, mailEnabledPublicFolder,
- mailboxManagerActions.ToString(), samAccountName, CryptoUtils.Encrypt(accountPassword),0, string.Empty);
+ mailboxManagerActions.ToString(), samAccountName,0, string.Empty);
}
private static int AddOrganizationUser(int itemId, string accountName, string displayName, string email, string samAccountName, string accountPassword)
{
return DataProvider.AddExchangeAccount(itemId, (int)ExchangeAccountType.User, accountName, displayName, email, false, string.Empty,
- samAccountName, CryptoUtils.Encrypt(accountPassword), 0 , string.Empty);
+ samAccountName, 0 , string.Empty);
}
@@ -996,7 +996,7 @@ namespace WebsitePanel.Import.Enterprise
mailEnabledPublicFolder,
mailboxManagerActions,
samAccountName,
- CryptoUtils.Encrypt(accountPassword), mailboxPlanId , -1, string.Empty, false);
+ mailboxPlanId , -1, string.Empty, false);
}
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/HostedSolution/AccessToken.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/HostedSolution/AccessToken.cs
new file mode 100644
index 00000000..9556d1c3
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/HostedSolution/AccessToken.cs
@@ -0,0 +1,18 @@
+using System;
+
+namespace WebsitePanel.EnterpriseServer.Base.HostedSolution
+{
+ public class AccessToken
+ {
+ public int Id { get; set; }
+ public Guid AccessTokenGuid { get; set; }
+ public DateTime ExpirationDate { get; set; }
+ public int AccountId { get; set; }
+ public int ItemId { get; set; }
+ public AccessTokenTypes TokenType { get; set; }
+ public string SmsResponse { get; set; }
+ public bool IsSmsSent {
+ get { return !string.IsNullOrEmpty(SmsResponse); }
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/HostedSolution/AccessTokenTypes.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/HostedSolution/AccessTokenTypes.cs
new file mode 100644
index 00000000..059e43d5
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/HostedSolution/AccessTokenTypes.cs
@@ -0,0 +1,7 @@
+namespace WebsitePanel.EnterpriseServer.Base.HostedSolution
+{
+ public enum AccessTokenTypes
+ {
+ PasswrodReset = 1
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/System/SystemSettings.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/System/SystemSettings.cs
index 542a611c..7af8b4f3 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/System/SystemSettings.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/System/SystemSettings.cs
@@ -27,6 +27,7 @@
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
using System;
+using System.Linq;
using System.Xml;
using System.Collections.Generic;
using System.Text;
@@ -45,6 +46,8 @@ namespace WebsitePanel.EnterpriseServer
public const string FILEMANAGER_SETTINGS = "FileManagerSettings";
public const string PACKAGE_DISPLAY_SETTINGS = "PackageDisplaySettings";
public const string RDS_SETTINGS = "RdsSettings";
+ public const string WEBDAV_PORTAL_SETTINGS = "WebdavPortalSettings";
+ public const string WEBDAV_PASSWORD_RESET_ENABLED_KEY = "WebdavPswResetEnabled";
// key to access to wpi main & custom feed in wpi settings
public const string WPI_MAIN_FEED_KEY = "WpiMainFeedUrl";
@@ -97,7 +100,25 @@ namespace WebsitePanel.EnterpriseServer
}
}
- public int GetInt(string settingName)
+ public bool Contains(string settingName)
+ {
+ return Settings.AllKeys.Any(x => x.ToLowerInvariant() == (settingName ?? string.Empty).ToLowerInvariant());
+ }
+
+ public T GetValueOrDefault(string settingName, T defaultValue)
+ {
+ try
+ {
+ return (T)Convert.ChangeType(Settings[settingName], typeof(T));
+ }
+ catch
+ {
+ }
+
+ return defaultValue;
+ }
+
+ public int GetInt(string settingName)
{
return Int32.Parse(Settings[settingName]);
}
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/Users/UserSettings.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/Users/UserSettings.cs
index 251d5dbf..3d163d59 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/Users/UserSettings.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/Users/UserSettings.cs
@@ -65,6 +65,10 @@ namespace WebsitePanel.EnterpriseServer
public const string DEFAULT_LYNCUSERPLANS = "DefaultLyncUserPlans";
public const string RDS_SETUP_LETTER = "RDSSetupLetter";
public const string RDS_POLICY = "RdsPolicy";
+ public const string USER_PASSWORD_EXPIRATION_LETTER = "UserPasswordExpirationLetter";
+ public const string USER_PASSWORD_RESET_LETTER = "UserPasswordResetLetter";
+ public const string HOSTED_ORGANIZATION_PASSWORD_POLICY = "MailboxPasswordPolicy";
+
public int UserId;
public string SettingsName;
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/Virtualization/VirtualizationErrorCodes.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/Virtualization/VirtualizationErrorCodes.cs
index 7c92ee9f..d7f37e80 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/Virtualization/VirtualizationErrorCodes.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/Virtualization/VirtualizationErrorCodes.cs
@@ -114,7 +114,13 @@
public const string EJECT_DVD_DISK_ERROR = "VPS_EJECT_DVD_DISK_ERROR";
// Replication
- public const string SET_REPLICA_SERVER_ERROR = "SET_REPLICA_SERVER_ERROR";
+ public const string SET_REPLICA_SERVER_ERROR = "VPS_SET_REPLICA_SERVER_ERROR";
+ public const string UNSET_REPLICA_SERVER_ERROR = "VPS_UNSET_REPLICA_SERVER_ERROR";
+ public const string NO_REPLICA_SERVER_ERROR = "VPS_NO_REPLICA_SERVER_ERROR";
+ public const string SET_REPLICATION_ERROR = "VPS_SET_REPLICATION_ERROR";
+ public const string DISABLE_REPLICATION_ERROR = "VPS_DISABLE_REPLICATION_ERROR";
+ public const string PAUSE_REPLICATION_ERROR = "VPS_PAUSE_REPLICATION_ERROR";
+ public const string RESUME_REPLICATION_ERROR = "VPS_RESUME_REPLICATION_ERROR";
public const string HOST_NAMER_IS_ALREADY_USED = "HOST_NAMER_IS_ALREADY_USED";
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/WebsitePanel.EnterpriseServer.Base.csproj b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/WebsitePanel.EnterpriseServer.Base.csproj
index ba6f30a1..3a24cbb4 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/WebsitePanel.EnterpriseServer.Base.csproj
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Base/WebsitePanel.EnterpriseServer.Base.csproj
@@ -116,10 +116,12 @@
+
+
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/OrganizationProxy.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/OrganizationProxy.cs
index 02682edb..2976bfe4 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/OrganizationProxy.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/OrganizationProxy.cs
@@ -1,41 +1,7 @@
-// Copyright (c) 2015, Outercurve Foundation.
-// All rights reserved.
-//
-// Redistribution and use in source and binary forms, with or without modification,
-// are permitted provided that the following conditions are met:
-//
-// - Redistributions of source code must retain the above copyright notice, this
-// list of conditions and the following disclaimer.
-//
-// - Redistributions in binary form must reproduce the above copyright notice,
-// this list of conditions and the following disclaimer in the documentation
-// and/or other materials provided with the distribution.
-//
-// - Neither the name of the Outercurve Foundation nor the names of its
-// contributors may be used to endorse or promote products derived from this
-// software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
-// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
-// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
-// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
-// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
-// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-using WebsitePanel.Providers;
-using WebsitePanel.Providers.Common;
-using WebsitePanel.Providers.ResultObjects;
-using WebsitePanel.Providers.HostedSolution;
-using WebsitePanel.EnterpriseServer.Base.HostedSolution;
-
//------------------------------------------------------------------------------
//
// This code was generated by a tool.
-// Runtime Version:2.0.50727.5466
+// Runtime Version:2.0.50727.7905
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
@@ -43,8 +9,15 @@ using WebsitePanel.EnterpriseServer.Base.HostedSolution;
//------------------------------------------------------------------------------
//
-// This source code was auto-generated by wsdl, Version=2.0.50727.42.
+// This source code was auto-generated by wsdl, Version=2.0.50727.3038.
//
+
+using WebsitePanel.EnterpriseServer.Base.HostedSolution;
+using WebsitePanel.Providers;
+using WebsitePanel.Providers.Common;
+using WebsitePanel.Providers.HostedSolution;
+using WebsitePanel.Providers.ResultObjects;
+
namespace WebsitePanel.EnterpriseServer.HostedSolution {
using System.Xml.Serialization;
using System.Web.Services;
@@ -56,13 +29,31 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
[System.Web.Services.WebServiceBindingAttribute(Name="esOrganizationsSoap", Namespace="http://tempuri.org/")]
[System.Xml.Serialization.XmlIncludeAttribute(typeof(ServiceProviderItem))]
public partial class esOrganizations : Microsoft.Web.Services3.WebServicesClientProtocol {
+ private System.Threading.SendOrPostCallback CheckPhoneNumberIsInUseOperationCompleted;
+
+ private System.Threading.SendOrPostCallback DeletePasswordresetAccessTokenOperationCompleted;
+
+ private System.Threading.SendOrPostCallback SetAccessTokenResponseOperationCompleted;
+
+ private System.Threading.SendOrPostCallback GetPasswordresetAccessTokenOperationCompleted;
+
+ private System.Threading.SendOrPostCallback UpdateOrganizationGeneralSettingsOperationCompleted;
+
+ private System.Threading.SendOrPostCallback GetOrganizationGeneralSettingsOperationCompleted;
+
+ private System.Threading.SendOrPostCallback UpdateOrganizationPasswordSettingsOperationCompleted;
+
+ private System.Threading.SendOrPostCallback GetWebDavSystemSettingsOperationCompleted;
+
+ private System.Threading.SendOrPostCallback GetOrganizationPasswordSettingsOperationCompleted;
+
private System.Threading.SendOrPostCallback CheckOrgIdExistsOperationCompleted;
private System.Threading.SendOrPostCallback CreateOrganizationOperationCompleted;
@@ -129,6 +120,8 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
private System.Threading.SendOrPostCallback GetPasswordPolicyOperationCompleted;
+ private System.Threading.SendOrPostCallback SendResetUserPasswordEmailOperationCompleted;
+
private System.Threading.SendOrPostCallback CreateSecurityGroupOperationCompleted;
private System.Threading.SendOrPostCallback GetSecurityGroupGeneralSettingsOperationCompleted;
@@ -170,6 +163,33 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
this.Url = "http://localhost:9002/esOrganizations.asmx";
}
+ ///
+ public event CheckPhoneNumberIsInUseCompletedEventHandler CheckPhoneNumberIsInUseCompleted;
+
+ ///
+ public event DeletePasswordresetAccessTokenCompletedEventHandler DeletePasswordresetAccessTokenCompleted;
+
+ ///
+ public event SetAccessTokenResponseCompletedEventHandler SetAccessTokenResponseCompleted;
+
+ ///
+ public event GetPasswordresetAccessTokenCompletedEventHandler GetPasswordresetAccessTokenCompleted;
+
+ ///
+ public event UpdateOrganizationGeneralSettingsCompletedEventHandler UpdateOrganizationGeneralSettingsCompleted;
+
+ ///
+ public event GetOrganizationGeneralSettingsCompletedEventHandler GetOrganizationGeneralSettingsCompleted;
+
+ ///
+ public event UpdateOrganizationPasswordSettingsCompletedEventHandler UpdateOrganizationPasswordSettingsCompleted;
+
+ ///
+ public event GetWebDavSystemSettingsCompletedEventHandler GetWebDavSystemSettingsCompleted;
+
+ ///
+ public event GetOrganizationPasswordSettingsCompletedEventHandler GetOrganizationPasswordSettingsCompleted;
+
///
public event CheckOrgIdExistsCompletedEventHandler CheckOrgIdExistsCompleted;
@@ -269,6 +289,9 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
///
public event GetPasswordPolicyCompletedEventHandler GetPasswordPolicyCompleted;
+ ///
+ public event SendResetUserPasswordEmailCompletedEventHandler SendResetUserPasswordEmailCompleted;
+
///
public event CreateSecurityGroupCompletedEventHandler CreateSecurityGroupCompleted;
@@ -323,6 +346,379 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
///
public event GetSupportServiceLevelCompletedEventHandler GetSupportServiceLevelCompleted;
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CheckPhoneNumberIsInUse", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public bool CheckPhoneNumberIsInUse(int itemId, string phoneNumber, string userSamAccountName) {
+ object[] results = this.Invoke("CheckPhoneNumberIsInUse", new object[] {
+ itemId,
+ phoneNumber,
+ userSamAccountName});
+ return ((bool)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginCheckPhoneNumberIsInUse(int itemId, string phoneNumber, string userSamAccountName, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("CheckPhoneNumberIsInUse", new object[] {
+ itemId,
+ phoneNumber,
+ userSamAccountName}, callback, asyncState);
+ }
+
+ ///
+ public bool EndCheckPhoneNumberIsInUse(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((bool)(results[0]));
+ }
+
+ ///
+ public void CheckPhoneNumberIsInUseAsync(int itemId, string phoneNumber, string userSamAccountName) {
+ this.CheckPhoneNumberIsInUseAsync(itemId, phoneNumber, userSamAccountName, null);
+ }
+
+ ///
+ public void CheckPhoneNumberIsInUseAsync(int itemId, string phoneNumber, string userSamAccountName, object userState) {
+ if ((this.CheckPhoneNumberIsInUseOperationCompleted == null)) {
+ this.CheckPhoneNumberIsInUseOperationCompleted = new System.Threading.SendOrPostCallback(this.OnCheckPhoneNumberIsInUseOperationCompleted);
+ }
+ this.InvokeAsync("CheckPhoneNumberIsInUse", new object[] {
+ itemId,
+ phoneNumber,
+ userSamAccountName}, this.CheckPhoneNumberIsInUseOperationCompleted, userState);
+ }
+
+ private void OnCheckPhoneNumberIsInUseOperationCompleted(object arg) {
+ if ((this.CheckPhoneNumberIsInUseCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.CheckPhoneNumberIsInUseCompleted(this, new CheckPhoneNumberIsInUseCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeletePasswordresetAccessToken", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeletePasswordresetAccessToken(System.Guid accessToken) {
+ this.Invoke("DeletePasswordresetAccessToken", new object[] {
+ accessToken});
+ }
+
+ ///
+ public System.IAsyncResult BeginDeletePasswordresetAccessToken(System.Guid accessToken, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("DeletePasswordresetAccessToken", new object[] {
+ accessToken}, callback, asyncState);
+ }
+
+ ///
+ public void EndDeletePasswordresetAccessToken(System.IAsyncResult asyncResult) {
+ this.EndInvoke(asyncResult);
+ }
+
+ ///
+ public void DeletePasswordresetAccessTokenAsync(System.Guid accessToken) {
+ this.DeletePasswordresetAccessTokenAsync(accessToken, null);
+ }
+
+ ///
+ public void DeletePasswordresetAccessTokenAsync(System.Guid accessToken, object userState) {
+ if ((this.DeletePasswordresetAccessTokenOperationCompleted == null)) {
+ this.DeletePasswordresetAccessTokenOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeletePasswordresetAccessTokenOperationCompleted);
+ }
+ this.InvokeAsync("DeletePasswordresetAccessToken", new object[] {
+ accessToken}, this.DeletePasswordresetAccessTokenOperationCompleted, userState);
+ }
+
+ private void OnDeletePasswordresetAccessTokenOperationCompleted(object arg) {
+ if ((this.DeletePasswordresetAccessTokenCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.DeletePasswordresetAccessTokenCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetAccessTokenResponse", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void SetAccessTokenResponse(System.Guid accessToken, string response) {
+ this.Invoke("SetAccessTokenResponse", new object[] {
+ accessToken,
+ response});
+ }
+
+ ///
+ public System.IAsyncResult BeginSetAccessTokenResponse(System.Guid accessToken, string response, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("SetAccessTokenResponse", new object[] {
+ accessToken,
+ response}, callback, asyncState);
+ }
+
+ ///
+ public void EndSetAccessTokenResponse(System.IAsyncResult asyncResult) {
+ this.EndInvoke(asyncResult);
+ }
+
+ ///
+ public void SetAccessTokenResponseAsync(System.Guid accessToken, string response) {
+ this.SetAccessTokenResponseAsync(accessToken, response, null);
+ }
+
+ ///
+ public void SetAccessTokenResponseAsync(System.Guid accessToken, string response, object userState) {
+ if ((this.SetAccessTokenResponseOperationCompleted == null)) {
+ this.SetAccessTokenResponseOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSetAccessTokenResponseOperationCompleted);
+ }
+ this.InvokeAsync("SetAccessTokenResponse", new object[] {
+ accessToken,
+ response}, this.SetAccessTokenResponseOperationCompleted, userState);
+ }
+
+ private void OnSetAccessTokenResponseOperationCompleted(object arg) {
+ if ((this.SetAccessTokenResponseCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.SetAccessTokenResponseCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetPasswordresetAccessToken", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public AccessToken GetPasswordresetAccessToken(System.Guid token) {
+ object[] results = this.Invoke("GetPasswordresetAccessToken", new object[] {
+ token});
+ return ((AccessToken)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginGetPasswordresetAccessToken(System.Guid token, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("GetPasswordresetAccessToken", new object[] {
+ token}, callback, asyncState);
+ }
+
+ ///
+ public AccessToken EndGetPasswordresetAccessToken(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((AccessToken)(results[0]));
+ }
+
+ ///
+ public void GetPasswordresetAccessTokenAsync(System.Guid token) {
+ this.GetPasswordresetAccessTokenAsync(token, null);
+ }
+
+ ///
+ public void GetPasswordresetAccessTokenAsync(System.Guid token, object userState) {
+ if ((this.GetPasswordresetAccessTokenOperationCompleted == null)) {
+ this.GetPasswordresetAccessTokenOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetPasswordresetAccessTokenOperationCompleted);
+ }
+ this.InvokeAsync("GetPasswordresetAccessToken", new object[] {
+ token}, this.GetPasswordresetAccessTokenOperationCompleted, userState);
+ }
+
+ private void OnGetPasswordresetAccessTokenOperationCompleted(object arg) {
+ if ((this.GetPasswordresetAccessTokenCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.GetPasswordresetAccessTokenCompleted(this, new GetPasswordresetAccessTokenCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/UpdateOrganizationGeneralSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void UpdateOrganizationGeneralSettings(int itemId, OrganizationGeneralSettings settings) {
+ this.Invoke("UpdateOrganizationGeneralSettings", new object[] {
+ itemId,
+ settings});
+ }
+
+ ///
+ public System.IAsyncResult BeginUpdateOrganizationGeneralSettings(int itemId, OrganizationGeneralSettings settings, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("UpdateOrganizationGeneralSettings", new object[] {
+ itemId,
+ settings}, callback, asyncState);
+ }
+
+ ///
+ public void EndUpdateOrganizationGeneralSettings(System.IAsyncResult asyncResult) {
+ this.EndInvoke(asyncResult);
+ }
+
+ ///
+ public void UpdateOrganizationGeneralSettingsAsync(int itemId, OrganizationGeneralSettings settings) {
+ this.UpdateOrganizationGeneralSettingsAsync(itemId, settings, null);
+ }
+
+ ///
+ public void UpdateOrganizationGeneralSettingsAsync(int itemId, OrganizationGeneralSettings settings, object userState) {
+ if ((this.UpdateOrganizationGeneralSettingsOperationCompleted == null)) {
+ this.UpdateOrganizationGeneralSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnUpdateOrganizationGeneralSettingsOperationCompleted);
+ }
+ this.InvokeAsync("UpdateOrganizationGeneralSettings", new object[] {
+ itemId,
+ settings}, this.UpdateOrganizationGeneralSettingsOperationCompleted, userState);
+ }
+
+ private void OnUpdateOrganizationGeneralSettingsOperationCompleted(object arg) {
+ if ((this.UpdateOrganizationGeneralSettingsCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.UpdateOrganizationGeneralSettingsCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetOrganizationGeneralSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public OrganizationGeneralSettings GetOrganizationGeneralSettings(int itemId) {
+ object[] results = this.Invoke("GetOrganizationGeneralSettings", new object[] {
+ itemId});
+ return ((OrganizationGeneralSettings)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginGetOrganizationGeneralSettings(int itemId, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("GetOrganizationGeneralSettings", new object[] {
+ itemId}, callback, asyncState);
+ }
+
+ ///
+ public OrganizationGeneralSettings EndGetOrganizationGeneralSettings(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((OrganizationGeneralSettings)(results[0]));
+ }
+
+ ///
+ public void GetOrganizationGeneralSettingsAsync(int itemId) {
+ this.GetOrganizationGeneralSettingsAsync(itemId, null);
+ }
+
+ ///
+ public void GetOrganizationGeneralSettingsAsync(int itemId, object userState) {
+ if ((this.GetOrganizationGeneralSettingsOperationCompleted == null)) {
+ this.GetOrganizationGeneralSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetOrganizationGeneralSettingsOperationCompleted);
+ }
+ this.InvokeAsync("GetOrganizationGeneralSettings", new object[] {
+ itemId}, this.GetOrganizationGeneralSettingsOperationCompleted, userState);
+ }
+
+ private void OnGetOrganizationGeneralSettingsOperationCompleted(object arg) {
+ if ((this.GetOrganizationGeneralSettingsCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.GetOrganizationGeneralSettingsCompleted(this, new GetOrganizationGeneralSettingsCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/UpdateOrganizationPasswordSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void UpdateOrganizationPasswordSettings(int itemId, OrganizationPasswordSettings settings) {
+ this.Invoke("UpdateOrganizationPasswordSettings", new object[] {
+ itemId,
+ settings});
+ }
+
+ ///
+ public System.IAsyncResult BeginUpdateOrganizationPasswordSettings(int itemId, OrganizationPasswordSettings settings, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("UpdateOrganizationPasswordSettings", new object[] {
+ itemId,
+ settings}, callback, asyncState);
+ }
+
+ ///
+ public void EndUpdateOrganizationPasswordSettings(System.IAsyncResult asyncResult) {
+ this.EndInvoke(asyncResult);
+ }
+
+ ///
+ public void UpdateOrganizationPasswordSettingsAsync(int itemId, OrganizationPasswordSettings settings) {
+ this.UpdateOrganizationPasswordSettingsAsync(itemId, settings, null);
+ }
+
+ ///
+ public void UpdateOrganizationPasswordSettingsAsync(int itemId, OrganizationPasswordSettings settings, object userState) {
+ if ((this.UpdateOrganizationPasswordSettingsOperationCompleted == null)) {
+ this.UpdateOrganizationPasswordSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnUpdateOrganizationPasswordSettingsOperationCompleted);
+ }
+ this.InvokeAsync("UpdateOrganizationPasswordSettings", new object[] {
+ itemId,
+ settings}, this.UpdateOrganizationPasswordSettingsOperationCompleted, userState);
+ }
+
+ private void OnUpdateOrganizationPasswordSettingsOperationCompleted(object arg) {
+ if ((this.UpdateOrganizationPasswordSettingsCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.UpdateOrganizationPasswordSettingsCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetWebDavSystemSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public SystemSettings GetWebDavSystemSettings() {
+ object[] results = this.Invoke("GetWebDavSystemSettings", new object[0]);
+ return ((SystemSettings)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginGetWebDavSystemSettings(System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("GetWebDavSystemSettings", new object[0], callback, asyncState);
+ }
+
+ ///
+ public SystemSettings EndGetWebDavSystemSettings(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((SystemSettings)(results[0]));
+ }
+
+ ///
+ public void GetWebDavSystemSettingsAsync() {
+ this.GetWebDavSystemSettingsAsync(null);
+ }
+
+ ///
+ public void GetWebDavSystemSettingsAsync(object userState) {
+ if ((this.GetWebDavSystemSettingsOperationCompleted == null)) {
+ this.GetWebDavSystemSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetWebDavSystemSettingsOperationCompleted);
+ }
+ this.InvokeAsync("GetWebDavSystemSettings", new object[0], this.GetWebDavSystemSettingsOperationCompleted, userState);
+ }
+
+ private void OnGetWebDavSystemSettingsOperationCompleted(object arg) {
+ if ((this.GetWebDavSystemSettingsCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.GetWebDavSystemSettingsCompleted(this, new GetWebDavSystemSettingsCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetOrganizationPasswordSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public OrganizationPasswordSettings GetOrganizationPasswordSettings(int itemId) {
+ object[] results = this.Invoke("GetOrganizationPasswordSettings", new object[] {
+ itemId});
+ return ((OrganizationPasswordSettings)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginGetOrganizationPasswordSettings(int itemId, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("GetOrganizationPasswordSettings", new object[] {
+ itemId}, callback, asyncState);
+ }
+
+ ///
+ public OrganizationPasswordSettings EndGetOrganizationPasswordSettings(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((OrganizationPasswordSettings)(results[0]));
+ }
+
+ ///
+ public void GetOrganizationPasswordSettingsAsync(int itemId) {
+ this.GetOrganizationPasswordSettingsAsync(itemId, null);
+ }
+
+ ///
+ public void GetOrganizationPasswordSettingsAsync(int itemId, object userState) {
+ if ((this.GetOrganizationPasswordSettingsOperationCompleted == null)) {
+ this.GetOrganizationPasswordSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetOrganizationPasswordSettingsOperationCompleted);
+ }
+ this.InvokeAsync("GetOrganizationPasswordSettings", new object[] {
+ itemId}, this.GetOrganizationPasswordSettingsOperationCompleted, userState);
+ }
+
+ private void OnGetOrganizationPasswordSettingsOperationCompleted(object arg) {
+ if ((this.GetOrganizationPasswordSettingsCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.GetOrganizationPasswordSettingsCompleted(this, new GetOrganizationPasswordSettingsCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
///
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CheckOrgIdExists", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
public bool CheckOrgIdExists(string orgId) {
@@ -2097,6 +2493,54 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
}
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SendResetUserPasswordEmail", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void SendResetUserPasswordEmail(int itemId, int accountId, string reason, string mailTo) {
+ this.Invoke("SendResetUserPasswordEmail", new object[] {
+ itemId,
+ accountId,
+ reason,
+ mailTo});
+ }
+
+ ///
+ public System.IAsyncResult BeginSendResetUserPasswordEmail(int itemId, int accountId, string reason, string mailTo, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("SendResetUserPasswordEmail", new object[] {
+ itemId,
+ accountId,
+ reason,
+ mailTo}, callback, asyncState);
+ }
+
+ ///
+ public void EndSendResetUserPasswordEmail(System.IAsyncResult asyncResult) {
+ this.EndInvoke(asyncResult);
+ }
+
+ ///
+ public void SendResetUserPasswordEmailAsync(int itemId, int accountId, string reason, string mailTo) {
+ this.SendResetUserPasswordEmailAsync(itemId, accountId, reason, mailTo, null);
+ }
+
+ ///
+ public void SendResetUserPasswordEmailAsync(int itemId, int accountId, string reason, string mailTo, object userState) {
+ if ((this.SendResetUserPasswordEmailOperationCompleted == null)) {
+ this.SendResetUserPasswordEmailOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSendResetUserPasswordEmailOperationCompleted);
+ }
+ this.InvokeAsync("SendResetUserPasswordEmail", new object[] {
+ itemId,
+ accountId,
+ reason,
+ mailTo}, this.SendResetUserPasswordEmailOperationCompleted, userState);
+ }
+
+ private void OnSendResetUserPasswordEmailOperationCompleted(object arg) {
+ if ((this.SendResetUserPasswordEmailCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.SendResetUserPasswordEmailCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
///
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateSecurityGroup", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
public int CreateSecurityGroup(int itemId, string displayName) {
@@ -2911,11 +3355,157 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void CheckPhoneNumberIsInUseCompletedEventHandler(object sender, CheckPhoneNumberIsInUseCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class CheckPhoneNumberIsInUseCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal CheckPhoneNumberIsInUseCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public bool Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((bool)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void DeletePasswordresetAccessTokenCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void SetAccessTokenResponseCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void GetPasswordresetAccessTokenCompletedEventHandler(object sender, GetPasswordresetAccessTokenCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class GetPasswordresetAccessTokenCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal GetPasswordresetAccessTokenCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public AccessToken Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((AccessToken)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void UpdateOrganizationGeneralSettingsCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void GetOrganizationGeneralSettingsCompletedEventHandler(object sender, GetOrganizationGeneralSettingsCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class GetOrganizationGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal GetOrganizationGeneralSettingsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public OrganizationGeneralSettings Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((OrganizationGeneralSettings)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void UpdateOrganizationPasswordSettingsCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void GetWebDavSystemSettingsCompletedEventHandler(object sender, GetWebDavSystemSettingsCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class GetWebDavSystemSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal GetWebDavSystemSettingsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public SystemSettings Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((SystemSettings)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void GetOrganizationPasswordSettingsCompletedEventHandler(object sender, GetOrganizationPasswordSettingsCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class GetOrganizationPasswordSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal GetOrganizationPasswordSettingsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public OrganizationPasswordSettings Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((OrganizationPasswordSettings)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CheckOrgIdExistsCompletedEventHandler(object sender, CheckOrgIdExistsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class CheckOrgIdExistsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -2937,11 +3527,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CreateOrganizationCompletedEventHandler(object sender, CreateOrganizationCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class CreateOrganizationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -2963,11 +3553,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetRawOrganizationsPagedCompletedEventHandler(object sender, GetRawOrganizationsPagedCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetRawOrganizationsPagedCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -2989,11 +3579,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationsCompletedEventHandler(object sender, GetOrganizationsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3015,11 +3605,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationByIdCompletedEventHandler(object sender, GetOrganizationByIdCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationByIdCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3041,11 +3631,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationUserSummuryLetterCompletedEventHandler(object sender, GetOrganizationUserSummuryLetterCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationUserSummuryLetterCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3067,11 +3657,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SendOrganizationUserSummuryLetterCompletedEventHandler(object sender, SendOrganizationUserSummuryLetterCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SendOrganizationUserSummuryLetterCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3093,11 +3683,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteOrganizationCompletedEventHandler(object sender, DeleteOrganizationCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class DeleteOrganizationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3119,11 +3709,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationStatisticsCompletedEventHandler(object sender, GetOrganizationStatisticsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationStatisticsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3145,11 +3735,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationStatisticsByOrganizationCompletedEventHandler(object sender, GetOrganizationStatisticsByOrganizationCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationStatisticsByOrganizationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3171,11 +3761,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationCompletedEventHandler(object sender, GetOrganizationCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3197,11 +3787,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetAccountIdByUserPrincipalNameCompletedEventHandler(object sender, GetAccountIdByUserPrincipalNameCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetAccountIdByUserPrincipalNameCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3223,15 +3813,15 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetDefaultOrganizationCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void AddOrganizationDomainCompletedEventHandler(object sender, AddOrganizationDomainCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class AddOrganizationDomainCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3253,11 +3843,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void ChangeOrganizationDomainTypeCompletedEventHandler(object sender, ChangeOrganizationDomainTypeCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class ChangeOrganizationDomainTypeCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3279,11 +3869,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationDomainsCompletedEventHandler(object sender, GetOrganizationDomainsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationDomainsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3305,11 +3895,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteOrganizationDomainCompletedEventHandler(object sender, DeleteOrganizationDomainCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class DeleteOrganizationDomainCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3331,11 +3921,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetOrganizationDefaultDomainCompletedEventHandler(object sender, SetOrganizationDefaultDomainCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SetOrganizationDefaultDomainCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3357,11 +3947,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationObjectsByDomainCompletedEventHandler(object sender, GetOrganizationObjectsByDomainCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationObjectsByDomainCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3383,11 +3973,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CheckDomainUsedByHostedOrganizationCompletedEventHandler(object sender, CheckDomainUsedByHostedOrganizationCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class CheckDomainUsedByHostedOrganizationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3409,11 +3999,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CreateUserCompletedEventHandler(object sender, CreateUserCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class CreateUserCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3435,11 +4025,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void ImportUserCompletedEventHandler(object sender, ImportUserCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class ImportUserCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3461,11 +4051,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationDeletedUsersPagedCompletedEventHandler(object sender, GetOrganizationDeletedUsersPagedCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationDeletedUsersPagedCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3487,11 +4077,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationUsersPagedCompletedEventHandler(object sender, GetOrganizationUsersPagedCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationUsersPagedCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3513,11 +4103,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetUserGeneralSettingsCompletedEventHandler(object sender, GetUserGeneralSettingsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetUserGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3539,11 +4129,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetUserGeneralSettingsCompletedEventHandler(object sender, SetUserGeneralSettingsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SetUserGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3565,11 +4155,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetUserPrincipalNameCompletedEventHandler(object sender, SetUserPrincipalNameCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SetUserPrincipalNameCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3591,11 +4181,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetUserPasswordCompletedEventHandler(object sender, SetUserPasswordCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SetUserPasswordCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3617,11 +4207,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SearchAccountsCompletedEventHandler(object sender, SearchAccountsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SearchAccountsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3643,11 +4233,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetDeletedUserCompletedEventHandler(object sender, SetDeletedUserCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SetDeletedUserCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3669,11 +4259,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetArchiveFileBinaryChunkCompletedEventHandler(object sender, GetArchiveFileBinaryChunkCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetArchiveFileBinaryChunkCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3695,11 +4285,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteUserCompletedEventHandler(object sender, DeleteUserCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class DeleteUserCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3721,11 +4311,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetPasswordPolicyCompletedEventHandler(object sender, GetPasswordPolicyCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetPasswordPolicyCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3747,11 +4337,15 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void SendResetUserPasswordEmailCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CreateSecurityGroupCompletedEventHandler(object sender, CreateSecurityGroupCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class CreateSecurityGroupCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3773,11 +4367,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetSecurityGroupGeneralSettingsCompletedEventHandler(object sender, GetSecurityGroupGeneralSettingsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetSecurityGroupGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3799,11 +4393,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteSecurityGroupCompletedEventHandler(object sender, DeleteSecurityGroupCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class DeleteSecurityGroupCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3825,11 +4419,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetSecurityGroupGeneralSettingsCompletedEventHandler(object sender, SetSecurityGroupGeneralSettingsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SetSecurityGroupGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3851,11 +4445,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetOrganizationSecurityGroupsPagedCompletedEventHandler(object sender, GetOrganizationSecurityGroupsPagedCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetOrganizationSecurityGroupsPagedCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3877,11 +4471,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void AddObjectToSecurityGroupCompletedEventHandler(object sender, AddObjectToSecurityGroupCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class AddObjectToSecurityGroupCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3903,11 +4497,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteObjectFromSecurityGroupCompletedEventHandler(object sender, DeleteObjectFromSecurityGroupCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class DeleteObjectFromSecurityGroupCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3929,11 +4523,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetSecurityGroupsByMemberCompletedEventHandler(object sender, GetSecurityGroupsByMemberCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetSecurityGroupsByMemberCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3955,11 +4549,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SearchOrganizationAccountsCompletedEventHandler(object sender, SearchOrganizationAccountsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SearchOrganizationAccountsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -3981,11 +4575,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetAdditionalGroupsCompletedEventHandler(object sender, GetAdditionalGroupsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetAdditionalGroupsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -4007,19 +4601,19 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void UpdateAdditionalGroupCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteAdditionalGroupCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void AddAdditionalGroupCompletedEventHandler(object sender, AddAdditionalGroupCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class AddAdditionalGroupCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -4041,11 +4635,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetSupportServiceLevelsCompletedEventHandler(object sender, GetSupportServiceLevelsCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetSupportServiceLevelsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -4067,15 +4661,15 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void UpdateSupportServiceLevelCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteSupportServiceLevelCompletedEventHandler(object sender, DeleteSupportServiceLevelCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class DeleteSupportServiceLevelCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -4097,11 +4691,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void AddSupportServiceLevelCompletedEventHandler(object sender, AddSupportServiceLevelCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class AddSupportServiceLevelCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
@@ -4123,11 +4717,11 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
}
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetSupportServiceLevelCompletedEventHandler(object sender, GetSupportServiceLevelCompletedEventArgs e);
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class GetSupportServiceLevelCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/VirtualizationServerProxy2012.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/VirtualizationServerProxy2012.cs
index b52ec841..4a093ead 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/VirtualizationServerProxy2012.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/VirtualizationServerProxy2012.cs
@@ -148,7 +148,21 @@ namespace WebsitePanel.EnterpriseServer {
private System.Threading.SendOrPostCallback SetReplicaServerOperationCompleted;
- private System.Threading.SendOrPostCallback IsReplicaServerOperationCompleted;
+ private System.Threading.SendOrPostCallback UnsetReplicaServerOperationCompleted;
+
+ private System.Threading.SendOrPostCallback GetReplicaServerOperationCompleted;
+
+ private System.Threading.SendOrPostCallback GetReplicationOperationCompleted;
+
+ private System.Threading.SendOrPostCallback GetReplicationInfoOperationCompleted;
+
+ private System.Threading.SendOrPostCallback SetVmReplicationOperationCompleted;
+
+ private System.Threading.SendOrPostCallback DisableVmReplicationOperationCompleted;
+
+ private System.Threading.SendOrPostCallback PauseReplicationOperationCompleted;
+
+ private System.Threading.SendOrPostCallback ResumeReplicationOperationCompleted;
///
public esVirtualizationServer2012() {
@@ -327,7 +341,28 @@ namespace WebsitePanel.EnterpriseServer {
public event SetReplicaServerCompletedEventHandler SetReplicaServerCompleted;
///
- public event IsReplicaServerCompletedEventHandler IsReplicaServerCompleted;
+ public event UnsetReplicaServerCompletedEventHandler UnsetReplicaServerCompleted;
+
+ ///
+ public event GetReplicaServerCompletedEventHandler GetReplicaServerCompleted;
+
+ ///
+ public event GetReplicationCompletedEventHandler GetReplicationCompleted;
+
+ ///
+ public event GetReplicationInfoCompletedEventHandler GetReplicationInfoCompleted;
+
+ ///
+ public event SetVmReplicationCompletedEventHandler SetVmReplicationCompleted;
+
+ ///
+ public event DisableVmReplicationCompletedEventHandler DisableVmReplicationCompleted;
+
+ ///
+ public event PauseReplicationCompletedEventHandler PauseReplicationCompleted;
+
+ ///
+ public event ResumeReplicationCompletedEventHandler ResumeReplicationCompleted;
///
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetVirtualMachines", RequestNamespace="http://smbsaas/websitepanel/enterpriseserver", ResponseNamespace="http://smbsaas/websitepanel/enterpriseserver", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
@@ -3234,46 +3269,339 @@ namespace WebsitePanel.EnterpriseServer {
}
///
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/IsReplicaServer", 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 bool IsReplicaServer(int serviceId, string remoteServer) {
- object[] results = this.Invoke("IsReplicaServer", new object[] {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/UnsetReplicaServer", 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 ResultObject UnsetReplicaServer(int serviceId, string remoteServer) {
+ object[] results = this.Invoke("UnsetReplicaServer", new object[] {
serviceId,
remoteServer});
- return ((bool)(results[0]));
+ return ((ResultObject)(results[0]));
}
///
- public System.IAsyncResult BeginIsReplicaServer(int serviceId, string remoteServer, System.AsyncCallback callback, object asyncState) {
- return this.BeginInvoke("IsReplicaServer", new object[] {
+ public System.IAsyncResult BeginUnsetReplicaServer(int serviceId, string remoteServer, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("UnsetReplicaServer", new object[] {
serviceId,
remoteServer}, callback, asyncState);
}
///
- public bool EndIsReplicaServer(System.IAsyncResult asyncResult) {
+ public ResultObject EndUnsetReplicaServer(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
- return ((bool)(results[0]));
+ return ((ResultObject)(results[0]));
}
///
- public void IsReplicaServerAsync(int serviceId, string remoteServer) {
- this.IsReplicaServerAsync(serviceId, remoteServer, null);
+ public void UnsetReplicaServerAsync(int serviceId, string remoteServer) {
+ this.UnsetReplicaServerAsync(serviceId, remoteServer, null);
}
///
- public void IsReplicaServerAsync(int serviceId, string remoteServer, object userState) {
- if ((this.IsReplicaServerOperationCompleted == null)) {
- this.IsReplicaServerOperationCompleted = new System.Threading.SendOrPostCallback(this.OnIsReplicaServerOperationCompleted);
+ public void UnsetReplicaServerAsync(int serviceId, string remoteServer, object userState) {
+ if ((this.UnsetReplicaServerOperationCompleted == null)) {
+ this.UnsetReplicaServerOperationCompleted = new System.Threading.SendOrPostCallback(this.OnUnsetReplicaServerOperationCompleted);
}
- this.InvokeAsync("IsReplicaServer", new object[] {
+ this.InvokeAsync("UnsetReplicaServer", new object[] {
serviceId,
- remoteServer}, this.IsReplicaServerOperationCompleted, userState);
+ remoteServer}, this.UnsetReplicaServerOperationCompleted, userState);
}
- private void OnIsReplicaServerOperationCompleted(object arg) {
- if ((this.IsReplicaServerCompleted != null)) {
+ private void OnUnsetReplicaServerOperationCompleted(object arg) {
+ if ((this.UnsetReplicaServerCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
- this.IsReplicaServerCompleted(this, new IsReplicaServerCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ this.UnsetReplicaServerCompleted(this, new UnsetReplicaServerCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetReplicaServer", 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 ReplicationServerInfo GetReplicaServer(int serviceId, string remoteServer) {
+ object[] results = this.Invoke("GetReplicaServer", new object[] {
+ serviceId,
+ remoteServer});
+ return ((ReplicationServerInfo)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginGetReplicaServer(int serviceId, string remoteServer, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("GetReplicaServer", new object[] {
+ serviceId,
+ remoteServer}, callback, asyncState);
+ }
+
+ ///
+ public ReplicationServerInfo EndGetReplicaServer(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((ReplicationServerInfo)(results[0]));
+ }
+
+ ///
+ public void GetReplicaServerAsync(int serviceId, string remoteServer) {
+ this.GetReplicaServerAsync(serviceId, remoteServer, null);
+ }
+
+ ///
+ public void GetReplicaServerAsync(int serviceId, string remoteServer, object userState) {
+ if ((this.GetReplicaServerOperationCompleted == null)) {
+ this.GetReplicaServerOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetReplicaServerOperationCompleted);
+ }
+ this.InvokeAsync("GetReplicaServer", new object[] {
+ serviceId,
+ remoteServer}, this.GetReplicaServerOperationCompleted, userState);
+ }
+
+ private void OnGetReplicaServerOperationCompleted(object arg) {
+ if ((this.GetReplicaServerCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.GetReplicaServerCompleted(this, new GetReplicaServerCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetReplication", 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 VmReplication GetReplication(int itemId) {
+ object[] results = this.Invoke("GetReplication", new object[] {
+ itemId});
+ return ((VmReplication)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginGetReplication(int itemId, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("GetReplication", new object[] {
+ itemId}, callback, asyncState);
+ }
+
+ ///
+ public VmReplication EndGetReplication(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((VmReplication)(results[0]));
+ }
+
+ ///
+ public void GetReplicationAsync(int itemId) {
+ this.GetReplicationAsync(itemId, null);
+ }
+
+ ///
+ public void GetReplicationAsync(int itemId, object userState) {
+ if ((this.GetReplicationOperationCompleted == null)) {
+ this.GetReplicationOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetReplicationOperationCompleted);
+ }
+ this.InvokeAsync("GetReplication", new object[] {
+ itemId}, this.GetReplicationOperationCompleted, userState);
+ }
+
+ private void OnGetReplicationOperationCompleted(object arg) {
+ if ((this.GetReplicationCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.GetReplicationCompleted(this, new GetReplicationCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetReplicationInfo", 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 ReplicationDetailInfo GetReplicationInfo(int itemId) {
+ object[] results = this.Invoke("GetReplicationInfo", new object[] {
+ itemId});
+ return ((ReplicationDetailInfo)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginGetReplicationInfo(int itemId, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("GetReplicationInfo", new object[] {
+ itemId}, callback, asyncState);
+ }
+
+ ///
+ public ReplicationDetailInfo EndGetReplicationInfo(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((ReplicationDetailInfo)(results[0]));
+ }
+
+ ///
+ public void GetReplicationInfoAsync(int itemId) {
+ this.GetReplicationInfoAsync(itemId, null);
+ }
+
+ ///
+ public void GetReplicationInfoAsync(int itemId, object userState) {
+ if ((this.GetReplicationInfoOperationCompleted == null)) {
+ this.GetReplicationInfoOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetReplicationInfoOperationCompleted);
+ }
+ this.InvokeAsync("GetReplicationInfo", new object[] {
+ itemId}, this.GetReplicationInfoOperationCompleted, userState);
+ }
+
+ private void OnGetReplicationInfoOperationCompleted(object arg) {
+ if ((this.GetReplicationInfoCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.GetReplicationInfoCompleted(this, new GetReplicationInfoCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/SetVmReplication", 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 ResultObject SetVmReplication(int itemId, VmReplication replication) {
+ object[] results = this.Invoke("SetVmReplication", new object[] {
+ itemId,
+ replication});
+ return ((ResultObject)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginSetVmReplication(int itemId, VmReplication replication, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("SetVmReplication", new object[] {
+ itemId,
+ replication}, callback, asyncState);
+ }
+
+ ///
+ public ResultObject EndSetVmReplication(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((ResultObject)(results[0]));
+ }
+
+ ///
+ public void SetVmReplicationAsync(int itemId, VmReplication replication) {
+ this.SetVmReplicationAsync(itemId, replication, null);
+ }
+
+ ///
+ public void SetVmReplicationAsync(int itemId, VmReplication replication, object userState) {
+ if ((this.SetVmReplicationOperationCompleted == null)) {
+ this.SetVmReplicationOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSetVmReplicationOperationCompleted);
+ }
+ this.InvokeAsync("SetVmReplication", new object[] {
+ itemId,
+ replication}, this.SetVmReplicationOperationCompleted, userState);
+ }
+
+ private void OnSetVmReplicationOperationCompleted(object arg) {
+ if ((this.SetVmReplicationCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.SetVmReplicationCompleted(this, new SetVmReplicationCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/DisableVmReplication", 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 ResultObject DisableVmReplication(int itemId) {
+ object[] results = this.Invoke("DisableVmReplication", new object[] {
+ itemId});
+ return ((ResultObject)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginDisableVmReplication(int itemId, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("DisableVmReplication", new object[] {
+ itemId}, callback, asyncState);
+ }
+
+ ///
+ public ResultObject EndDisableVmReplication(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((ResultObject)(results[0]));
+ }
+
+ ///
+ public void DisableVmReplicationAsync(int itemId) {
+ this.DisableVmReplicationAsync(itemId, null);
+ }
+
+ ///
+ public void DisableVmReplicationAsync(int itemId, object userState) {
+ if ((this.DisableVmReplicationOperationCompleted == null)) {
+ this.DisableVmReplicationOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDisableVmReplicationOperationCompleted);
+ }
+ this.InvokeAsync("DisableVmReplication", new object[] {
+ itemId}, this.DisableVmReplicationOperationCompleted, userState);
+ }
+
+ private void OnDisableVmReplicationOperationCompleted(object arg) {
+ if ((this.DisableVmReplicationCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.DisableVmReplicationCompleted(this, new DisableVmReplicationCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/PauseReplication", 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 ResultObject PauseReplication(int itemId) {
+ object[] results = this.Invoke("PauseReplication", new object[] {
+ itemId});
+ return ((ResultObject)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginPauseReplication(int itemId, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("PauseReplication", new object[] {
+ itemId}, callback, asyncState);
+ }
+
+ ///
+ public ResultObject EndPauseReplication(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((ResultObject)(results[0]));
+ }
+
+ ///
+ public void PauseReplicationAsync(int itemId) {
+ this.PauseReplicationAsync(itemId, null);
+ }
+
+ ///
+ public void PauseReplicationAsync(int itemId, object userState) {
+ if ((this.PauseReplicationOperationCompleted == null)) {
+ this.PauseReplicationOperationCompleted = new System.Threading.SendOrPostCallback(this.OnPauseReplicationOperationCompleted);
+ }
+ this.InvokeAsync("PauseReplication", new object[] {
+ itemId}, this.PauseReplicationOperationCompleted, userState);
+ }
+
+ private void OnPauseReplicationOperationCompleted(object arg) {
+ if ((this.PauseReplicationCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.PauseReplicationCompleted(this, new PauseReplicationCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/ResumeReplication", 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 ResultObject ResumeReplication(int itemId) {
+ object[] results = this.Invoke("ResumeReplication", new object[] {
+ itemId});
+ return ((ResultObject)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginResumeReplication(int itemId, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("ResumeReplication", new object[] {
+ itemId}, callback, asyncState);
+ }
+
+ ///
+ public ResultObject EndResumeReplication(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((ResultObject)(results[0]));
+ }
+
+ ///
+ public void ResumeReplicationAsync(int itemId) {
+ this.ResumeReplicationAsync(itemId, null);
+ }
+
+ ///
+ public void ResumeReplicationAsync(int itemId, object userState) {
+ if ((this.ResumeReplicationOperationCompleted == null)) {
+ this.ResumeReplicationOperationCompleted = new System.Threading.SendOrPostCallback(this.OnResumeReplicationOperationCompleted);
+ }
+ this.InvokeAsync("ResumeReplication", new object[] {
+ itemId}, this.ResumeReplicationOperationCompleted, userState);
+ }
+
+ private void OnResumeReplicationOperationCompleted(object arg) {
+ if ((this.ResumeReplicationCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.ResumeReplicationCompleted(this, new ResumeReplicationCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
@@ -4767,26 +5095,208 @@ namespace WebsitePanel.EnterpriseServer {
///
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
- public delegate void IsReplicaServerCompletedEventHandler(object sender, IsReplicaServerCompletedEventArgs e);
+ public delegate void UnsetReplicaServerCompletedEventHandler(object sender, UnsetReplicaServerCompletedEventArgs e);
///
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class IsReplicaServerCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+ public partial class UnsetReplicaServerCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
private object[] results;
- internal IsReplicaServerCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ internal UnsetReplicaServerCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
base(exception, cancelled, userState) {
this.results = results;
}
///
- public bool Result {
+ public ResultObject Result {
get {
this.RaiseExceptionIfNecessary();
- return ((bool)(this.results[0]));
+ return ((ResultObject)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ public delegate void GetReplicaServerCompletedEventHandler(object sender, GetReplicaServerCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class GetReplicaServerCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal GetReplicaServerCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public ReplicationServerInfo Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((ReplicationServerInfo)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ public delegate void GetReplicationCompletedEventHandler(object sender, GetReplicationCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class GetReplicationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal GetReplicationCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public VmReplication Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((VmReplication)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ public delegate void GetReplicationInfoCompletedEventHandler(object sender, GetReplicationInfoCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class GetReplicationInfoCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal GetReplicationInfoCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public ReplicationDetailInfo Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((ReplicationDetailInfo)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ public delegate void SetVmReplicationCompletedEventHandler(object sender, SetVmReplicationCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class SetVmReplicationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal SetVmReplicationCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public ResultObject Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((ResultObject)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ public delegate void DisableVmReplicationCompletedEventHandler(object sender, DisableVmReplicationCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class DisableVmReplicationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal DisableVmReplicationCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public ResultObject Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((ResultObject)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ public delegate void PauseReplicationCompletedEventHandler(object sender, PauseReplicationCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class PauseReplicationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal PauseReplicationCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public ResultObject Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((ResultObject)(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ public delegate void ResumeReplicationCompletedEventHandler(object sender, ResumeReplicationCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class ResumeReplicationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal ResumeReplicationCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public ResultObject Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((ResultObject)(this.results[0]));
}
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Common/Extensions/UriExtensions.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Common/Extensions/UriExtensions.cs
new file mode 100644
index 00000000..2ec58ede
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Common/Extensions/UriExtensions.cs
@@ -0,0 +1,13 @@
+using System;
+using System.Linq;
+
+namespace WebsitePanel.EnterpriseServer.Extensions
+{
+ public static class UriExtensions
+ {
+ public static Uri Append(this Uri uri, params string[] paths)
+ {
+ return new Uri(paths.Aggregate(uri.AbsoluteUri, (current, path) => string.Format("{0}/{1}", current.TrimEnd('/'), path.TrimStart('/'))));
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Common/ObjectUtils.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Common/ObjectUtils.cs
index b8e28155..0756c3b3 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Common/ObjectUtils.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Common/ObjectUtils.cs
@@ -27,11 +27,13 @@
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
using System;
+using System.IO;
using System.Reflection;
using System.Data;
using System.Collections;
using System.Collections.Generic;
-
+using System.Xml;
+using System.Xml.Serialization;
using WebsitePanel.Providers;
namespace WebsitePanel.EnterpriseServer
@@ -704,6 +706,37 @@ namespace WebsitePanel.EnterpriseServer
return type.FullName + ", " + type.Assembly.GetName().Name;
}
+ public static TResult Deserialize(string inputString)
+ {
+ TResult result;
+
+ var serializer = new XmlSerializer(typeof(TResult));
+
+ using (TextReader reader = new StringReader(inputString))
+ {
+ result = (TResult)serializer.Deserialize(reader);
+ }
+
+ return result;
+ }
+
+ public static string Serialize(TEntity entity)
+ {
+ string result = string.Empty;
+
+ var xmlSerializer = new XmlSerializer(typeof(TEntity));
+
+ using (var stringWriter = new StringWriter())
+ {
+ using (XmlWriter writer = XmlWriter.Create(stringWriter))
+ {
+ xmlSerializer.Serialize(writer, entity);
+ result = stringWriter.ToString();
+ }
+ }
+
+ return result;
+ }
#region Helper Functions
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Data/DataProvider.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Data/DataProvider.cs
index 637e08bb..23a0578e 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Data/DataProvider.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Data/DataProvider.cs
@@ -31,6 +31,7 @@ using System.Configuration;
using System.Data;
using System.Data.SqlClient;
using System.Text.RegularExpressions;
+using WebsitePanel.EnterpriseServer.Base.HostedSolution;
using WebsitePanel.Providers.HostedSolution;
using Microsoft.ApplicationBlocks.Data;
using System.Collections.Generic;
@@ -2409,7 +2410,7 @@ namespace WebsitePanel.EnterpriseServer
public static int AddExchangeAccount(int itemId, int accountType, string accountName,
string displayName, string primaryEmailAddress, bool mailEnabledPublicFolder,
- string mailboxManagerActions, string samAccountName, string accountPassword, int mailboxPlanId, string subscriberNumber)
+ string mailboxManagerActions, string samAccountName, int mailboxPlanId, string subscriberNumber)
{
SqlParameter outParam = new SqlParameter("@AccountID", SqlDbType.Int);
outParam.Direction = ParameterDirection.Output;
@@ -2427,7 +2428,6 @@ namespace WebsitePanel.EnterpriseServer
new SqlParameter("@MailEnabledPublicFolder", mailEnabledPublicFolder),
new SqlParameter("@MailboxManagerActions", mailboxManagerActions),
new SqlParameter("@SamAccountName", samAccountName),
- new SqlParameter("@AccountPassword", accountPassword),
new SqlParameter("@MailboxPlanId", (mailboxPlanId == 0) ? (object)DBNull.Value : (object)mailboxPlanId),
new SqlParameter("@SubscriberNumber", (string.IsNullOrEmpty(subscriberNumber) ? (object)DBNull.Value : (object)subscriberNumber))
);
@@ -2612,7 +2612,7 @@ namespace WebsitePanel.EnterpriseServer
public static void UpdateExchangeAccount(int accountId, string accountName, ExchangeAccountType accountType,
string displayName, string primaryEmailAddress, bool mailEnabledPublicFolder,
- string mailboxManagerActions, string samAccountName, string accountPassword, int mailboxPlanId, int archivePlanId, string subscriberNumber,
+ string mailboxManagerActions, string samAccountName, int mailboxPlanId, int archivePlanId, string subscriberNumber,
bool EnableArchiving)
{
SqlHelper.ExecuteNonQuery(
@@ -2626,7 +2626,6 @@ namespace WebsitePanel.EnterpriseServer
new SqlParameter("@PrimaryEmailAddress", primaryEmailAddress),
new SqlParameter("@MailEnabledPublicFolder", mailEnabledPublicFolder),
new SqlParameter("@MailboxManagerActions", mailboxManagerActions),
- new SqlParameter("@Password", string.IsNullOrEmpty(accountPassword) ? (object)DBNull.Value : (object)accountPassword),
new SqlParameter("@SamAccountName", samAccountName),
new SqlParameter("@MailboxPlanId", (mailboxPlanId == 0) ? (object)DBNull.Value : (object)mailboxPlanId),
new SqlParameter("@ArchivingMailboxPlanId", (archivePlanId < 1) ? (object)DBNull.Value : (object)archivePlanId),
@@ -3210,6 +3209,91 @@ namespace WebsitePanel.EnterpriseServer
#region Organizations
+ public static int AddAccessToken(AccessToken token)
+ {
+ return AddAccessToken(token.AccessTokenGuid, token.AccountId, token.ItemId, token.ExpirationDate, token.TokenType);
+ }
+
+ public static int AddAccessToken(Guid accessToken, int accountId, int itemId, DateTime expirationDate, AccessTokenTypes type)
+ {
+ SqlParameter prmId = new SqlParameter("@TokenID", SqlDbType.Int);
+ prmId.Direction = ParameterDirection.Output;
+
+ SqlHelper.ExecuteNonQuery(
+ ConnectionString,
+ CommandType.StoredProcedure,
+ "AddAccessToken",
+ prmId,
+ new SqlParameter("@AccessToken", accessToken),
+ new SqlParameter("@ExpirationDate", expirationDate),
+ new SqlParameter("@AccountID", accountId),
+ new SqlParameter("@ItemId", itemId),
+ new SqlParameter("@TokenType", (int)type)
+ );
+
+ // read identity
+ return Convert.ToInt32(prmId.Value);
+ }
+
+ public static void SetAccessTokenResponseMessage(Guid accessToken, string response)
+ {
+ SqlHelper.ExecuteNonQuery(
+ ConnectionString,
+ CommandType.StoredProcedure,
+ "SetAccessTokenSmsResponse",
+ new SqlParameter("@AccessToken", accessToken),
+ new SqlParameter("@SmsResponse", response)
+ );
+ }
+
+ public static void DeleteExpiredAccessTokens()
+ {
+ SqlHelper.ExecuteNonQuery(
+ ConnectionString,
+ CommandType.StoredProcedure,
+ "DeleteExpiredAccessTokenTokens"
+ );
+ }
+
+ public static IDataReader GetAccessTokenByAccessToken(Guid accessToken, AccessTokenTypes type)
+ {
+ return SqlHelper.ExecuteReader(
+ ConnectionString,
+ CommandType.StoredProcedure,
+ "GetAccessTokenByAccessToken",
+ new SqlParameter("@AccessToken", accessToken),
+ new SqlParameter("@TokenType", type)
+ );
+ }
+
+ public static void DeleteAccessToken(Guid accessToken, AccessTokenTypes type)
+ {
+ SqlHelper.ExecuteNonQuery(
+ ConnectionString,
+ CommandType.StoredProcedure,
+ "DeleteAccessToken",
+ new SqlParameter("@AccessToken", accessToken),
+ new SqlParameter("@TokenType", type)
+ );
+ }
+
+ public static void UpdateOrganizationSettings(int itemId, string settingsName, string xml)
+ {
+ SqlHelper.ExecuteNonQuery(ConnectionString, CommandType.StoredProcedure,
+ ObjectQualifier + "UpdateExchangeOrganizationSettings",
+ new SqlParameter("@ItemId", itemId),
+ new SqlParameter("@SettingsName", settingsName),
+ new SqlParameter("@Xml", xml));
+ }
+
+ public static IDataReader GetOrganizationSettings(int itemId, string settingsName)
+ {
+ return SqlHelper.ExecuteReader(ConnectionString, CommandType.StoredProcedure,
+ ObjectQualifier + "GetExchangeOrganizationSettings",
+ new SqlParameter("@ItemId", itemId),
+ new SqlParameter("@SettingsName", settingsName));
+ }
+
public static int AddOrganizationDeletedUser(int accountId, int originAT, string storagePath, string folderName, string fileName, DateTime expirationDate)
{
SqlParameter outParam = new SqlParameter("@ID", SqlDbType.Int);
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/EnterpriseStorage/EnterpriseStorageController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/EnterpriseStorage/EnterpriseStorageController.cs
index 200a52fb..b8093c0a 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/EnterpriseStorage/EnterpriseStorageController.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/EnterpriseStorage/EnterpriseStorageController.cs
@@ -1650,12 +1650,12 @@ namespace WebsitePanel.EnterpriseServer
return result;
}
- public static ResultObject DeleteMappedDrive(int itemId, string driveLetter)
+ public static ResultObject DeleteMappedDrive(int itemId, string folderName)
{
- return DeleteMappedDriveInternal(itemId, driveLetter);
+ return DeleteMappedDriveInternal(itemId, folderName);
}
- protected static ResultObject DeleteMappedDriveInternal(int itemId, string driveLetter)
+ protected static ResultObject DeleteMappedDriveInternal(int itemId, string folderName)
{
ResultObject result = TaskManager.StartResultTask("ENTERPRISE_STORAGE", "DELETE_MAPPED_DRIVE", itemId);
@@ -1670,9 +1670,13 @@ namespace WebsitePanel.EnterpriseServer
return result;
}
+ var webDavSetting = ObjectUtils.FillObjectFromDataReader(DataProvider.GetEnterpriseFolder(itemId, folderName));
+
+ string path = string.Format(@"\\{0}@SSL\{1}\{2}", webDavSetting.Domain.Split('.')[0], org.OrganizationId, folderName);
+
Organizations orgProxy = OrganizationController.GetOrganizationProxy(org.ServiceId);
- orgProxy.DeleteMappedDrive(org.OrganizationId, driveLetter);
+ orgProxy.DeleteMappedDriveByPath(org.OrganizationId, path);
}
catch (Exception ex)
{
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/ExchangeServer/ExchangeServerController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/ExchangeServer/ExchangeServerController.cs
index ca374742..47a17473 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/ExchangeServer/ExchangeServerController.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/ExchangeServer/ExchangeServerController.cs
@@ -1211,9 +1211,6 @@ namespace WebsitePanel.EnterpriseServer
if (account == null)
return null;
- // decrypt password
- account.AccountPassword = CryptoUtils.Decrypt(account.AccountPassword);
-
return account;
}
@@ -1225,9 +1222,6 @@ namespace WebsitePanel.EnterpriseServer
if (account == null)
return null;
- // decrypt password
- account.AccountPassword = CryptoUtils.Decrypt(account.AccountPassword);
-
return account;
}
@@ -1268,9 +1262,6 @@ namespace WebsitePanel.EnterpriseServer
if (account == null)
return null;
- // decrypt password
- account.AccountPassword = CryptoUtils.Decrypt(account.AccountPassword);
-
return account;
}
@@ -1280,14 +1271,14 @@ namespace WebsitePanel.EnterpriseServer
{
return DataProvider.AddExchangeAccount(itemId, (int)accountType,
accountName, displayName, primaryEmailAddress, mailEnabledPublicFolder,
- mailboxManagerActions.ToString(), samAccountName, CryptoUtils.Encrypt(accountPassword), mailboxPlanId, (string.IsNullOrEmpty(subscriberNumber) ? null : subscriberNumber.Trim()));
+ mailboxManagerActions.ToString(), samAccountName, mailboxPlanId, (string.IsNullOrEmpty(subscriberNumber) ? null : subscriberNumber.Trim()));
}
private static void UpdateAccount(ExchangeAccount account)
{
DataProvider.UpdateExchangeAccount(account.AccountId, account.AccountName, account.AccountType, account.DisplayName,
account.PrimaryEmailAddress, account.MailEnabledPublicFolder,
- account.MailboxManagerActions.ToString(), account.SamAccountName, account.AccountPassword, account.MailboxPlanId, account.ArchivingMailboxPlanId,
+ account.MailboxManagerActions.ToString(), account.SamAccountName, account.MailboxPlanId, account.ArchivingMailboxPlanId,
(string.IsNullOrEmpty(account.SubscriberNumber) ? null : account.SubscriberNumber.Trim()),
account.EnableArchiving);
}
@@ -1674,7 +1665,6 @@ namespace WebsitePanel.EnterpriseServer
mailEnabledPublicFolder,
mailboxManagerActions,
samAccountName,
- CryptoUtils.Encrypt(accountPassword),
mailboxPlanId, archivePlanId,
(string.IsNullOrEmpty(subscriberNumber) ? null : subscriberNumber.Trim()), EnableArchiving);
}
@@ -1952,7 +1942,6 @@ namespace WebsitePanel.EnterpriseServer
account.AccountType = ExchangeAccountType.User;
account.MailEnabledPublicFolder = false;
- account.AccountPassword = null;
UpdateAccount(account);
DataProvider.DeleteUserEmailAddresses(account.AccountId, account.PrimaryEmailAddress);
@@ -2338,7 +2327,6 @@ namespace WebsitePanel.EnterpriseServer
}
// save account
- account.AccountPassword = null;
UpdateAccount(account);
return 0;
@@ -2562,7 +2550,6 @@ namespace WebsitePanel.EnterpriseServer
else account.MailboxManagerActions &= ~action;
// update account
- account.AccountPassword = null;
UpdateAccount(account);
return 0;
@@ -2629,6 +2616,13 @@ namespace WebsitePanel.EnterpriseServer
items["AccountDomain"] = account.PrimaryEmailAddress.Substring(account.PrimaryEmailAddress.IndexOf("@") + 1);
items["DefaultDomain"] = org.DefaultDomain;
+ var passwordResetUrl = OrganizationController.GenerateUserPasswordResetLink(account.ItemId, account.AccountId);
+ if (!string.IsNullOrEmpty(passwordResetUrl))
+ {
+ items["PswResetUrl"] = passwordResetUrl;
+ }
+
+
if (!String.IsNullOrEmpty(account.SamAccountName))
{
int idx = account.SamAccountName.IndexOf("\\");
@@ -3895,7 +3889,6 @@ namespace WebsitePanel.EnterpriseServer
// update account
account.DisplayName = displayName;
account.PrimaryEmailAddress = emailAddress;
- account.AccountPassword = null;
UpdateAccount(account);
return 0;
@@ -4218,7 +4211,6 @@ namespace WebsitePanel.EnterpriseServer
// update account
account.DisplayName = displayName;
- account.AccountPassword = null;
UpdateAccount(account);
return 0;
@@ -4434,7 +4426,6 @@ namespace WebsitePanel.EnterpriseServer
addressLists.ToArray());
// save account
- account.AccountPassword = null;
UpdateAccount(account);
return 0;
@@ -4997,7 +4988,6 @@ namespace WebsitePanel.EnterpriseServer
account.AccountName = accountName;
account.MailEnabledPublicFolder = true;
account.PrimaryEmailAddress = email;
- account.AccountPassword = null;
UpdateAccount(account);
// register e-mail
@@ -5049,7 +5039,6 @@ namespace WebsitePanel.EnterpriseServer
// update and save account
account.MailEnabledPublicFolder = false;
account.PrimaryEmailAddress = "";
- account.AccountPassword = null;
UpdateAccount(account);
@@ -5168,7 +5157,6 @@ namespace WebsitePanel.EnterpriseServer
{
// rename original folder
account.DisplayName = newFullName;
- account.AccountPassword = null;
UpdateAccount(account);
// rename nested folders
@@ -5383,7 +5371,6 @@ namespace WebsitePanel.EnterpriseServer
emailAddress);
// save account
- account.AccountPassword = null;
UpdateAccount(account);
return 0;
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs
index acd5f507..2622e03f 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs
@@ -33,8 +33,10 @@ using System.Collections.Specialized;
using System.Data;
using System.Net.Mail;
using System.Text;
+using System.Threading.Tasks;
using WebsitePanel.EnterpriseServer.Code.HostedSolution;
using WebsitePanel.EnterpriseServer.Code.SharePoint;
+using WebsitePanel.EnterpriseServer.Extensions;
using WebsitePanel.Providers;
using WebsitePanel.Providers.HostedSolution;
using WebsitePanel.Providers.ResultObjects;
@@ -1532,7 +1534,359 @@ namespace WebsitePanel.EnterpriseServer
return result;
}
+ public static List GetOrganizationUsersWithExpiredPassword(int itemId, int daysBeforeExpiration)
+ {
+ // load organization
+ Organization org = GetOrganization(itemId);
+ if (org == null)
+ {
+ return null;
+ }
+
+ Organizations orgProxy = GetOrganizationProxy(org.ServiceId);
+
+ var expiredUsersAd = orgProxy.GetOrganizationUsersWithExpiredPassword(org.OrganizationId, daysBeforeExpiration);
+
+ var expiredUsersDb = GetOrganizationUsersPaged(itemId, null, null, null, 0, int.MaxValue).PageUsers.Where(x => expiredUsersAd.Any(z => z.SamAccountName == x.SamAccountName)).ToList();
+
+ foreach (var user in expiredUsersDb)
+ {
+ var adUser = expiredUsersAd.First(x => x.SamAccountName == user.SamAccountName);
+
+ user.PasswordExpirationDateTime = adUser.PasswordExpirationDateTime;
+ }
+
+ return expiredUsersDb;
+ }
+
+ ///
+ /// Send reset user password email
+ ///
+ /// Organization Id
+ /// User Id
+ /// Reason why reset email is sent.
+ /// Optional, if null accountID user PrimaryEmailAddress will be used
+ public static void SendResetUserPasswordEmail(int itemId, int accountId, string reason, string mailTo = null)
+ {
+ // load organization
+ Organization org = GetOrganization(itemId);
+
+ if (org == null)
+ {
+ throw new Exception(string.Format("Organization not found (ItemId = {0})", itemId));
+ }
+
+ Organizations orgProxy = GetOrganizationProxy(org.ServiceId);
+
+
+ UserInfo owner = PackageController.GetPackageOwner(org.PackageId);
+ OrganizationUser user = OrganizationController.GetAccount(itemId, accountId);
+
+ OrganizationUser settings = orgProxy.GetUserGeneralSettings(user.AccountName, org.OrganizationId);
+
+ user.PasswordExpirationDateTime = settings.PasswordExpirationDateTime;
+
+ if (string.IsNullOrEmpty(mailTo))
+ {
+ mailTo = user.PrimaryEmailAddress;
+ }
+
+ var generalSettings = OrganizationController.GetOrganizationGeneralSettings(itemId);
+
+ var logoUrl = generalSettings != null ? generalSettings.OrganizationLogoUrl : string.Empty;
+
+ SendUserPasswordEmail(owner, user, reason, mailTo, logoUrl, UserSettings.USER_PASSWORD_RESET_LETTER, "USER_PASSWORD_RESET_LETTER");
+ }
+
+ public static void SendUserExpirationPasswordEmail(UserInfo owner, OrganizationUser user, string reason,
+ string mailTo, string logoUrl)
+ {
+ SendUserPasswordEmail(owner, user, reason, user.PrimaryEmailAddress, logoUrl, UserSettings.USER_PASSWORD_EXPIRATION_LETTER, "USER_PASSWORD_EXPIRATION_LETTER");
+ }
+
+ public static void SendUserPasswordEmail(UserInfo owner, OrganizationUser user, string reason, string mailTo, string logoUrl, string settingsName, string taskName)
+ {
+ UserSettings settings = UserController.GetUserSettings(owner.UserId,
+ settingsName);
+
+ TaskManager.StartTask("ORGANIZATION", "SEND_" + taskName, user.ItemId);
+
+ try
+ {
+ if (string.IsNullOrEmpty(logoUrl))
+ {
+ logoUrl = settings["LogoUrl"];
+ }
+
+ string from = settings["From"];
+
+ string subject = settings["Subject"];
+ string body = owner.HtmlMail ? settings["HtmlBody"] : settings["TextBody"];
+ bool isHtml = owner.HtmlMail;
+
+ MailPriority priority = MailPriority.Normal;
+
+ if (!String.IsNullOrEmpty(settings["Priority"]))
+ {
+ priority = (MailPriority) Enum.Parse(typeof (MailPriority), settings["Priority"], true);
+ }
+
+ Hashtable items = new Hashtable();
+
+ items["user"] = user;
+ items["logoUrl"] = logoUrl;
+ items["passwordResetLink"] = GenerateUserPasswordResetLink(user.ItemId, user.AccountId);
+
+ body = PackageController.EvaluateTemplate(body, items);
+
+ TaskManager.Write("Organization ID : " + user.ItemId);
+ TaskManager.Write("Account : " + user.DisplayName);
+ TaskManager.Write("Reason : " + reason);
+ TaskManager.Write("MailTo : " + mailTo);
+
+ // send mail message
+ MailHelper.SendMessage(from, mailTo, null, subject, body, priority, isHtml);
+ }
+ catch (Exception ex)
+ {
+ throw TaskManager.WriteError(ex);
+ }
+ finally
+ {
+ TaskManager.CompleteTask();
+ }
+ }
+
+ public static AccessToken GetAccessToken(Guid accessToken, AccessTokenTypes type)
+ {
+ return ObjectUtils.FillObjectFromDataReader(DataProvider.GetAccessTokenByAccessToken(accessToken, type));
+ }
+
+ public static void DeleteAccessToken(Guid accessToken, AccessTokenTypes type)
+ {
+ DataProvider.DeleteAccessToken(accessToken, type);
+ }
+
+ public static void DeleteAllExpiredTokens()
+ {
+ DataProvider.DeleteExpiredAccessTokens();
+ }
+
+ public static SystemSettings GetWebDavSystemSettings()
+ {
+ return SystemController.GetSystemSettingsInternal(SystemSettings.WEBDAV_PORTAL_SETTINGS, false);
+ }
+
+ public static string GenerateUserPasswordResetLink(int itemId, int accountId)
+ {
+ string passwordResetUrlFormat = "account/password-reset/step-2";
+
+ var settings = GetWebDavSystemSettings();
+
+ if (settings == null || !settings.GetValueOrDefault(SystemSettings.WEBDAV_PASSWORD_RESET_ENABLED_KEY, false) ||!settings.Contains("WebdavPortalUrl"))
+ {
+ return string.Empty;
+ }
+
+ var webdavPortalUrl = new Uri(settings["WebdavPortalUrl"]);
+
+ var token = CreateAccessToken(itemId, accountId, AccessTokenTypes.PasswrodReset);
+
+ return webdavPortalUrl.Append(passwordResetUrlFormat)
+ .Append(token.AccessTokenGuid.ToString("n")).ToString();
+ }
+
+ private static AccessToken CreateAccessToken(int itemId, int accountId, AccessTokenTypes type)
+ {
+ var token = new AccessToken
+ {
+ AccessTokenGuid = Guid.NewGuid(),
+ ItemId = itemId,
+ AccountId = accountId,
+ TokenType = type,
+ ExpirationDate = DateTime.Now.AddHours(12)
+ };
+
+ token.Id = DataProvider.AddAccessToken(token);
+
+ return token;
+ }
+
+ public static void SetAccessTokenResponse(Guid accessToken, string response)
+ {
+ DataProvider.SetAccessTokenResponseMessage(accessToken, response);
+ }
+
+ public static bool CheckPhoneNumberIsInUse(int itemId, string phoneNumber, string userSamAccountName = null)
+ {
+ // load organization
+ Organization org = GetOrganization(itemId);
+
+ if (org == null)
+ {
+ throw new Exception(string.Format("Organization with id '{0}' not found", itemId));
+ }
+
+ Organizations orgProxy = GetOrganizationProxy(org.ServiceId);
+
+ return orgProxy.CheckPhoneNumberIsInUse(phoneNumber, userSamAccountName);
+ }
+
+ public static void UpdateOrganizationPasswordSettings(int itemId, OrganizationPasswordSettings settings)
+ {
+ TaskManager.StartTask("ORGANIZATION", "UPDATE_PASSWORD_SETTINGS");
+
+ try
+ {
+ // load organization
+ Organization org = GetOrganization(itemId);
+
+ if (org == null)
+ {
+ TaskManager.WriteWarning("Organization with itemId '{0}' not found", itemId.ToString());
+ return;
+ }
+
+ Organizations orgProxy = GetOrganizationProxy(org.ServiceId);
+
+ orgProxy.ApplyPasswordSettings(org.OrganizationId, settings);
+
+ var xml = ObjectUtils.Serialize(settings);
+
+ DataProvider.UpdateOrganizationSettings(itemId, OrganizationSettings.PasswordSettings, xml);
+ }
+ catch (Exception ex)
+ {
+ throw TaskManager.WriteError(ex);
+ }
+ finally
+ {
+ TaskManager.CompleteTask();
+ }
+ }
+
+ public static OrganizationPasswordSettings GetOrganizationPasswordSettings(int itemId)
+ {
+ var passwordSettings = GetOrganizationSettings(itemId, OrganizationSettings.PasswordSettings);
+
+ if (passwordSettings == null)
+ {
+ Organization org = GetOrganization(itemId);
+
+ if (org == null)
+ {
+ throw new Exception(string.Format("Organization not found (ItemId = {0})", itemId));
+ }
+
+ var package = PackageController.GetPackage(org.PackageId);
+
+ UserSettings userSettings = UserController.GetUserSettings(package.UserId, UserSettings.EXCHANGE_POLICY);
+
+ if (userSettings != null)
+ {
+ string policyValue = userSettings["MailboxPasswordPolicy"];
+
+ if (policyValue != null)
+ {
+ string[] parts = policyValue.Split(';');
+
+ passwordSettings = new OrganizationPasswordSettings
+ {
+ MinimumLength = GetValueSafe(parts, 1, 0),
+ MaximumLength = GetValueSafe(parts, 2, 0),
+ UppercaseLettersCount = GetValueSafe(parts, 3, 0),
+ NumbersCount = GetValueSafe(parts, 4, 0),
+ SymbolsCount = GetValueSafe(parts, 5, 0),
+ AccountLockoutThreshold = GetValueSafe(parts, 7, 0),
+
+ EnforcePasswordHistory = GetValueSafe(parts, 8, 0),
+ AccountLockoutDuration = GetValueSafe(parts, 9, 0),
+ ResetAccountLockoutCounterAfter = GetValueSafe(parts, 10, 0),
+ LockoutSettingsEnabled = GetValueSafe(parts, 11, false),
+ PasswordComplexityEnabled = GetValueSafe(parts, 11, true),
+ };
+
+
+ PasswordPolicyResult passwordPolicy = GetPasswordPolicy(itemId);
+
+ if (passwordPolicy.IsSuccess)
+ {
+ passwordSettings.MinimumLength = passwordPolicy.Value.MinLength;
+ if (passwordPolicy.Value.IsComplexityEnable)
+ {
+ passwordSettings.NumbersCount = 1;
+ passwordSettings.SymbolsCount = 1;
+ passwordSettings.UppercaseLettersCount = 1;
+ }
+ }
+ }
+ }
+ }
+
+ return passwordSettings;
+ }
+
+ public static T GetValueSafe(string[] array, int index, T defaultValue)
+ {
+ if (array.Length > index)
+ {
+ if (string.IsNullOrEmpty(array[index]))
+ {
+ return defaultValue;
+ }
+
+ return (T)Convert.ChangeType(array[index], typeof(T));
+ }
+
+ return defaultValue;
+ }
+
+ public static void UpdateOrganizationGeneralSettings(int itemId, OrganizationGeneralSettings settings)
+ {
+ TaskManager.StartTask("ORGANIZATION", "UPDATE_GENERAL_SETTINGS");
+
+ try
+ {
+ // load organization
+ Organization org = GetOrganization(itemId);
+
+ if (org == null)
+ {
+ TaskManager.WriteWarning("Organization with itemId '{0}' not found", itemId.ToString());
+ return;
+ }
+
+ var xml = ObjectUtils.Serialize(settings);
+
+ DataProvider.UpdateOrganizationSettings(itemId, OrganizationSettings.GeneralSettings, xml);
+ }
+ catch (Exception ex)
+ {
+ throw TaskManager.WriteError(ex);
+ }
+ finally
+ {
+ TaskManager.CompleteTask();
+ }
+ }
+
+ public static OrganizationGeneralSettings GetOrganizationGeneralSettings(int itemId)
+ {
+ return GetOrganizationSettings(itemId, OrganizationSettings.GeneralSettings);
+ }
+
+ private static T GetOrganizationSettings(int itemId, string settingsName)
+ {
+ var entity = ObjectUtils.FillObjectFromDataReader(DataProvider.GetOrganizationSettings(itemId, settingsName));
+
+ if (entity == null)
+ {
+ return default(T);
+ }
+
+ return ObjectUtils.Deserialize(entity.Xml);
+ }
private static bool EmailAddressExists(string emailAddress)
{
@@ -1543,7 +1897,7 @@ namespace WebsitePanel.EnterpriseServer
private static int AddOrganizationUser(int itemId, string accountName, string displayName, string email, string sAMAccountName, string accountPassword, string subscriberNumber)
{
return DataProvider.AddExchangeAccount(itemId, (int)ExchangeAccountType.User, accountName, displayName, email, false, string.Empty,
- sAMAccountName, CryptoUtils.Encrypt(accountPassword), 0, subscriberNumber.Trim());
+ sAMAccountName, 0, subscriberNumber.Trim());
}
@@ -2231,9 +2585,6 @@ namespace WebsitePanel.EnterpriseServer
if (account == null)
return null;
- // decrypt password
- account.AccountPassword = CryptoUtils.Decrypt(account.AccountPassword);
-
return account;
}
@@ -2268,7 +2619,7 @@ namespace WebsitePanel.EnterpriseServer
#endregion
// place log record
- TaskManager.StartTask("ORGANIZATION", "GET_USER_GENERAL", itemId);
+ //TaskManager.StartTask("ORGANIZATION", "GET_USER_GENERAL", itemId);
OrganizationUser account = null;
Organization org = null;
@@ -2311,7 +2662,7 @@ namespace WebsitePanel.EnterpriseServer
catch { }
finally
{
- TaskManager.CompleteTask();
+ //TaskManager.CompleteTask();
}
return (account);
@@ -2395,10 +2746,6 @@ namespace WebsitePanel.EnterpriseServer
account.IsVIP = isVIP;
//account.
- if (!String.IsNullOrEmpty(password))
- account.AccountPassword = CryptoUtils.Encrypt(password);
- else
- account.AccountPassword = null;
UpdateAccount(account);
UpdateAccountServiceLevelSettings(account);
@@ -2526,6 +2873,9 @@ namespace WebsitePanel.EnterpriseServer
// place log record
TaskManager.StartTask("ORGANIZATION", "SET_USER_PASSWORD", itemId);
+ TaskManager.Write("ItemId: {0}", itemId.ToString());
+ TaskManager.Write("AccountId: {0}", accountId.ToString());
+
try
{
// load organization
@@ -2549,10 +2899,6 @@ namespace WebsitePanel.EnterpriseServer
password);
//account.
- if (!String.IsNullOrEmpty(password))
- account.AccountPassword = CryptoUtils.Encrypt(password);
- else
- account.AccountPassword = null;
UpdateAccount(account);
@@ -2577,7 +2923,7 @@ namespace WebsitePanel.EnterpriseServer
{
DataProvider.UpdateExchangeAccount(account.AccountId, account.AccountName, account.AccountType, account.DisplayName,
account.PrimaryEmailAddress, account.MailEnabledPublicFolder,
- account.MailboxManagerActions.ToString(), account.SamAccountName, account.AccountPassword, account.MailboxPlanId, account.ArchivingMailboxPlanId,
+ account.MailboxManagerActions.ToString(), account.SamAccountName, account.MailboxPlanId, account.ArchivingMailboxPlanId,
(string.IsNullOrEmpty(account.SubscriberNumber) ? null : account.SubscriberNumber.Trim()),
account.EnableArchiving);
}
@@ -2814,7 +3160,7 @@ namespace WebsitePanel.EnterpriseServer
{
return DataProvider.AddExchangeAccount(itemId, (int)accountType,
accountName, displayName, primaryEmailAddress, mailEnabledPublicFolder,
- mailboxManagerActions.ToString(), samAccountName, CryptoUtils.Encrypt(accountPassword), mailboxPlanId, (string.IsNullOrEmpty(subscriberNumber) ? null : subscriberNumber.Trim()));
+ mailboxManagerActions.ToString(), samAccountName, mailboxPlanId, (string.IsNullOrEmpty(subscriberNumber) ? null : subscriberNumber.Trim()));
}
#region Additional Default Groups
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/SchedulerTasks/UserPasswordExpirationNotificationTask.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/SchedulerTasks/UserPasswordExpirationNotificationTask.cs
new file mode 100644
index 00000000..bda161b1
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/SchedulerTasks/UserPasswordExpirationNotificationTask.cs
@@ -0,0 +1,67 @@
+using System;
+using System.Collections;
+using System.Collections.Generic;
+using System.Linq;
+using System.Net.Mail;
+using WebsitePanel.Providers.HostedSolution;
+
+namespace WebsitePanel.EnterpriseServer
+{
+ public class UserPasswordExpirationNotificationTask : SchedulerTask
+ {
+ // Input parameters:
+ private static readonly string DaysBeforeNotify = "DAYS_BEFORE_EXPIRATION";
+
+ public override void DoWork()
+ {
+ BackgroundTask topTask = TaskManager.TopTask;
+
+ int daysBeforeNotify;
+
+ // check input parameters
+ if (!int.TryParse((string)topTask.GetParamValue(DaysBeforeNotify), out daysBeforeNotify))
+ {
+ TaskManager.WriteWarning("Specify 'Notify before (days)' task parameter");
+ return;
+ }
+
+ OrganizationController.DeleteAllExpiredTokens();
+
+ var owner = UserController.GetUser(topTask.EffectiveUserId);
+
+ var packages = PackageController.GetMyPackages(topTask.EffectiveUserId);
+
+ foreach (var package in packages)
+ {
+ var organizations = ExchangeServerController.GetExchangeOrganizations(package.PackageId, true);
+
+ foreach (var organization in organizations)
+ {
+ var usersWithExpiredPasswords = OrganizationController.GetOrganizationUsersWithExpiredPassword(organization.Id, daysBeforeNotify);
+
+ var generalSettings = OrganizationController.GetOrganizationGeneralSettings(organization.Id);
+
+ var logoUrl = generalSettings != null ? generalSettings.OrganizationLogoUrl : string.Empty;
+
+ foreach (var user in usersWithExpiredPasswords)
+ {
+ user.ItemId = organization.Id;
+
+ if (string.IsNullOrEmpty(user.PrimaryEmailAddress))
+ {
+ TaskManager.WriteWarning(string.Format("Unable to send email to {0} user (organization: {1}), user primary email address is not set.", user.DisplayName, organization.OrganizationId));
+ continue;
+ }
+
+ OrganizationController.SendUserExpirationPasswordEmail(owner, user, "Scheduler Password Expiration Notification", user.PrimaryEmailAddress, logoUrl);
+ }
+ }
+ }
+
+ // send mail message
+ // MailHelper.SendMessage(mailFrom, mailTo, mailSubject, mailBody, false);
+ }
+
+
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Virtualization2012/VirtualizationServerController2012.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Virtualization2012/VirtualizationServerController2012.cs
index 79a19aeb..6c0b6a96 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Virtualization2012/VirtualizationServerController2012.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/Virtualization2012/VirtualizationServerController2012.cs
@@ -3720,6 +3720,8 @@ namespace WebsitePanel.EnterpriseServer
#region Replication
+ #region IsReplicaServer Part
+
public static CertificateInfo[] GetCertificates(int serviceId, string remoteServer)
{
VirtualizationServer2012 vs = GetVirtualizationProxy(serviceId);
@@ -3745,12 +3747,208 @@ namespace WebsitePanel.EnterpriseServer
return result;
}
- public static bool IsReplicaServer(int serviceId, string remoteServer)
+ public static ResultObject UnsetReplicaServer(int serviceId, string remoteServer)
+ {
+ ResultObject result = new ResultObject();
+ try
+ {
+ VirtualizationServer2012 vs = GetVirtualizationProxy(serviceId);
+ vs.UnsetReplicaServer(remoteServer);
+ result.IsSuccess = true;
+ }
+ catch (Exception ex)
+ {
+ result.AddError(VirtualizationErrorCodes.UNSET_REPLICA_SERVER_ERROR, ex);
+ }
+ return result;
+ }
+
+ public static ReplicationServerInfo GetReplicaServer(int serviceId, string remoteServer)
{
VirtualizationServer2012 vs = GetVirtualizationProxy(serviceId);
- return vs.IsReplicaServer(remoteServer);
+ return vs.GetReplicaServer(remoteServer);
}
#endregion
+
+ public static VmReplication GetReplication(int itemId)
+ {
+ VirtualMachine vm = GetVirtualMachineByItemId(itemId);
+ VirtualizationServer2012 vs = GetVirtualizationProxy(vm.ServiceId);
+ return vs.GetReplication(vm.VirtualMachineId);
+ }
+
+ public static ReplicationDetailInfo GetReplicationInfo(int itemId)
+ {
+ VirtualMachine vm = GetVirtualMachineByItemId(itemId);
+ VirtualizationServer2012 vs = GetVirtualizationProxy(vm.ServiceId);
+ return vs.GetReplicationInfo(vm.VirtualMachineId);
+ }
+
+ public static ResultObject SetVmReplication(int itemId, VmReplication replication)
+ {
+ TaskManager.StartTask("VPS2012", "SetVmReplication");
+
+ ResultObject result = new ResultObject();
+ try
+ {
+ VirtualMachine vm = GetVirtualMachineByItemId(itemId);
+ VirtualizationServer2012 vs = GetVirtualizationProxy(vm.ServiceId);
+
+ // Get replica server
+ var replicaServerInfo = GetReplicaInfoForService(vm.ServiceId, ref result);
+ if (result.ErrorCodes.Count > 0)
+ return result;
+
+ // We should use enable replication or set replication?
+ var vmReplica = vs.GetReplication(vm.VirtualMachineId);
+ if (vmReplica == null) // need enable
+ {
+ vs.EnableVmReplication(vm.VirtualMachineId, replicaServerInfo.ComputerName, replication);
+ vs.StartInitialReplication(vm.VirtualMachineId);
+ }
+ else // need set
+ {
+ vs.SetVmReplication(vm.VirtualMachineId, replicaServerInfo.ComputerName, replication);
+ }
+ result.IsSuccess = true;
+ }
+ catch (Exception ex)
+ {
+ throw TaskManager.WriteError(ex);
+ }
+ finally
+ {
+ TaskManager.CompleteTask();
+ }
+ TaskManager.WriteWarning("Organization with itemId '{0}' not found", itemId.ToString());
+ return result;
+ }
+
+ public static ResultObject DisableVmReplication(int itemId)
+ {
+ ResultObject result = new ResultObject();
+ try
+ {
+ VirtualMachine vm = GetVirtualMachineByItemId(itemId);
+ VirtualizationServer2012 vs = GetVirtualizationProxy(vm.ServiceId);
+ vs.DisableVmReplication(vm.VirtualMachineId);
+
+ CleanUpReplicaServer(vm);
+
+ result.IsSuccess = true;
+ }
+ catch (Exception ex)
+ {
+ result.AddError(VirtualizationErrorCodes.DISABLE_REPLICATION_ERROR, ex);
+ }
+ return result;
+ }
+
+ public static ResultObject PauseReplication(int itemId)
+ {
+ ResultObject result = new ResultObject();
+ try
+ {
+ VirtualMachine vm = GetVirtualMachineByItemId(itemId);
+ VirtualizationServer2012 vs = GetVirtualizationProxy(vm.ServiceId);
+ vs.PauseReplication(vm.VirtualMachineId);
+
+ result.IsSuccess = true;
+ }
+ catch (Exception ex)
+ {
+ result.AddError(VirtualizationErrorCodes.PAUSE_REPLICATION_ERROR, ex);
+ }
+ return result;
+ }
+
+ public static ResultObject ResumeReplication(int itemId)
+ {
+ ResultObject result = new ResultObject();
+ try
+ {
+ VirtualMachine vm = GetVirtualMachineByItemId(itemId);
+ VirtualizationServer2012 vs = GetVirtualizationProxy(vm.ServiceId);
+ vs.ResumeReplication(vm.VirtualMachineId);
+
+ result.IsSuccess = true;
+ }
+ catch (Exception ex)
+ {
+ result.AddError(VirtualizationErrorCodes.RESUME_REPLICATION_ERROR, ex);
+ }
+ return result;
+ }
+
+ #region Private methods
+
+ private static void CleanUpReplicaServer(VirtualMachine originalVm)
+ {
+ try
+ {
+ ResultObject result = new ResultObject();
+
+ // Get replica server
+ var replicaServer = GetReplicaForService(originalVm.ServiceId, ref result);
+
+ // Clean up replica server
+ var replicaVm = replicaServer.GetVirtualMachines().FirstOrDefault(m => m.Name == originalVm.Name);
+ if (replicaVm != null)
+ {
+ replicaServer.DisableVmReplication(replicaVm.VirtualMachineId);
+ replicaServer.ShutDownVirtualMachine(replicaVm.VirtualMachineId, true, "ReplicaDelete");
+ replicaServer.DeleteVirtualMachine(replicaVm.VirtualMachineId);
+ }
+ }
+ catch { /* skip */ }
+ }
+
+ private static ReplicationServerInfo GetReplicaInfoForService(int serviceId, ref ResultObject result)
+ {
+ // Get service id of replica server
+ StringDictionary vsSesstings = ServerController.GetServiceSettings(serviceId);
+ string replicaServiceId = vsSesstings["ReplicaServerId"];
+
+ if (string.IsNullOrEmpty(replicaServiceId))
+ {
+ result.ErrorCodes.Add(VirtualizationErrorCodes.NO_REPLICA_SERVER_ERROR);
+ return null;
+ }
+
+ // get replica server info for replica service id
+ VirtualizationServer2012 vsReplica = GetVirtualizationProxy(Convert.ToInt32(replicaServiceId));
+ StringDictionary vsReplicaSesstings = ServerController.GetServiceSettings(Convert.ToInt32(replicaServiceId));
+ string computerName = vsReplicaSesstings["ServerName"];
+ var replicaServerInfo = vsReplica.GetReplicaServer(computerName);
+
+ if (!replicaServerInfo.Enabled)
+ {
+ result.ErrorCodes.Add(VirtualizationErrorCodes.NO_REPLICA_SERVER_ERROR);
+ return null;
+ }
+
+ return replicaServerInfo;
+ }
+
+ private static VirtualizationServer2012 GetReplicaForService(int serviceId, ref ResultObject result)
+ {
+ // Get service id of replica server
+ StringDictionary vsSesstings = ServerController.GetServiceSettings(serviceId);
+ string replicaServiceId = vsSesstings["ReplicaServerId"];
+
+ if (string.IsNullOrEmpty(replicaServiceId))
+ {
+ result.ErrorCodes.Add(VirtualizationErrorCodes.NO_REPLICA_SERVER_ERROR);
+ return null;
+ }
+
+ // get replica server for replica service id
+ return GetVirtualizationProxy(Convert.ToInt32(replicaServiceId));
+ }
+
+ #endregion
+
+ #endregion
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/WebsitePanel.EnterpriseServer.Code.csproj b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/WebsitePanel.EnterpriseServer.Code.csproj
index 3a684ae0..7cf712ca 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/WebsitePanel.EnterpriseServer.Code.csproj
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/WebsitePanel.EnterpriseServer.Code.csproj
@@ -75,6 +75,7 @@
+
@@ -158,6 +159,7 @@
+
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esOrganizations.asmx.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esOrganizations.asmx.cs
index 6db1e5f2..b261da3f 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esOrganizations.asmx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esOrganizations.asmx.cs
@@ -26,6 +26,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
@@ -47,6 +48,60 @@ namespace WebsitePanel.EnterpriseServer
{
#region Organizations
+ [WebMethod]
+ public bool CheckPhoneNumberIsInUse(int itemId, string phoneNumber, string userSamAccountName = null)
+ {
+ return OrganizationController.CheckPhoneNumberIsInUse(itemId, phoneNumber, userSamAccountName);
+ }
+
+ [WebMethod]
+ public void DeletePasswordresetAccessToken(Guid accessToken)
+ {
+ OrganizationController.DeleteAccessToken(accessToken, AccessTokenTypes.PasswrodReset);
+ }
+
+ [WebMethod]
+ public void SetAccessTokenResponse(Guid accessToken, string response)
+ {
+ OrganizationController.SetAccessTokenResponse(accessToken, response);
+ }
+
+ [WebMethod]
+ public AccessToken GetPasswordresetAccessToken(Guid token)
+ {
+ return OrganizationController.GetAccessToken(token, AccessTokenTypes.PasswrodReset);
+ }
+
+ [WebMethod]
+ public void UpdateOrganizationGeneralSettings(int itemId, OrganizationGeneralSettings settings)
+ {
+ OrganizationController.UpdateOrganizationGeneralSettings(itemId, settings);
+ }
+
+ [WebMethod]
+ public OrganizationGeneralSettings GetOrganizationGeneralSettings(int itemId)
+ {
+ return OrganizationController.GetOrganizationGeneralSettings(itemId);
+ }
+
+ [WebMethod]
+ public void UpdateOrganizationPasswordSettings(int itemId, OrganizationPasswordSettings settings)
+ {
+ OrganizationController.UpdateOrganizationPasswordSettings(itemId, settings);
+ }
+
+ [WebMethod]
+ public SystemSettings GetWebDavSystemSettings()
+ {
+ return OrganizationController.GetWebDavSystemSettings();
+ }
+
+ [WebMethod]
+ public OrganizationPasswordSettings GetOrganizationPasswordSettings(int itemId)
+ {
+ return OrganizationController.GetOrganizationPasswordSettings(itemId);
+ }
+
[WebMethod]
public bool CheckOrgIdExists(string orgId)
{
@@ -280,6 +335,11 @@ namespace WebsitePanel.EnterpriseServer
return OrganizationController.GetPasswordPolicy(itemId);
}
+ [WebMethod]
+ public void SendResetUserPasswordEmail(int itemId, int accountId, string reason, string mailTo = null)
+ {
+ OrganizationController.SendResetUserPasswordEmail(itemId, accountId, reason, mailTo);
+ }
#endregion
diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esVirtualizationServer2012.asmx.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esVirtualizationServer2012.asmx.cs
index 2d8275d2..0f5a3104 100644
--- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esVirtualizationServer2012.asmx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esVirtualizationServer2012.asmx.cs
@@ -488,12 +488,54 @@ namespace WebsitePanel.EnterpriseServer
}
[WebMethod]
- public bool IsReplicaServer(int serviceId, string remoteServer)
+ public ResultObject UnsetReplicaServer(int serviceId, string remoteServer)
{
- return VirtualizationServerController2012.IsReplicaServer(serviceId, remoteServer);
+ return VirtualizationServerController2012.UnsetReplicaServer(serviceId, remoteServer);
+ }
+
+ [WebMethod]
+ public ReplicationServerInfo GetReplicaServer(int serviceId, string remoteServer)
+ {
+ return VirtualizationServerController2012.GetReplicaServer(serviceId, remoteServer);
+ }
+
+ [WebMethod]
+ public VmReplication GetReplication(int itemId)
+ {
+ return VirtualizationServerController2012.GetReplication(itemId);
+ }
+
+ [WebMethod]
+ public ReplicationDetailInfo GetReplicationInfo(int itemId)
+ {
+ return VirtualizationServerController2012.GetReplicationInfo(itemId);
+ }
+
+ [WebMethod]
+ public ResultObject SetVmReplication(int itemId, VmReplication replication)
+ {
+ return VirtualizationServerController2012.SetVmReplication(itemId, replication);
+ }
+
+ [WebMethod]
+ public ResultObject DisableVmReplication(int itemId)
+ {
+ return VirtualizationServerController2012.DisableVmReplication(itemId);
+ }
+
+ [WebMethod]
+ public ResultObject PauseReplication(int itemId)
+ {
+ return VirtualizationServerController2012.PauseReplication(itemId);
+ }
+
+ [WebMethod]
+ public ResultObject ResumeReplication(int itemId)
+ {
+ return VirtualizationServerController2012.ResumeReplication(itemId);
}
#endregion
- }
+ }
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/ExchangeAccount.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/ExchangeAccount.cs
index 80f42fce..9a1fdc98 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/ExchangeAccount.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/ExchangeAccount.cs
@@ -108,11 +108,11 @@ namespace WebsitePanel.Providers.HostedSolution
set { this.mailEnabledPublicFolder = value; }
}
- public string AccountPassword
- {
- get { return this.accountPassword; }
- set { this.accountPassword = value; }
- }
+ //public string AccountPassword
+ //{
+ // get { return this.accountPassword; }
+ // set { this.accountPassword = value; }
+ //}
public MailboxManagerActions MailboxManagerActions
{
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/IOrganization.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/IOrganization.cs
index ea66403f..a14161a8 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/IOrganization.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/IOrganization.cs
@@ -26,6 +26,7 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+using System.Collections.Generic;
using WebsitePanel.Providers.OS;
using WebsitePanel.Providers.ResultObjects;
@@ -96,5 +97,10 @@ namespace WebsitePanel.Providers.HostedSolution
void SetDriveMapsTargetingFilter(string organizationId, ExchangeAccount[] accounts, string folderName);
void ChangeDriveMapFolderPath(string organizationId, string oldFolder, string newFolder);
+
+ List GetOrganizationUsersWithExpiredPassword(string organizationId, int daysBeforeExpiration);
+ void ApplyPasswordSettings(string organizationId, OrganizationPasswordSettings passwordSettings);
+
+ bool CheckPhoneNumberIsInUse(string phoneNumber, string userSamAccountName = null);
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationGeneralSettings.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationGeneralSettings.cs
new file mode 100644
index 00000000..345fd0e2
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationGeneralSettings.cs
@@ -0,0 +1,7 @@
+namespace WebsitePanel.Providers.HostedSolution
+{
+ public class OrganizationGeneralSettings
+ {
+ public string OrganizationLogoUrl { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationPasswordSettings.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationPasswordSettings.cs
new file mode 100644
index 00000000..cc00f552
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationPasswordSettings.cs
@@ -0,0 +1,19 @@
+namespace WebsitePanel.Providers.HostedSolution
+{
+ public class OrganizationPasswordSettings
+ {
+ public int MinimumLength { get; set; }
+ public int MaximumLength { get; set; }
+ public int EnforcePasswordHistory { get; set; }
+
+ public bool LockoutSettingsEnabled { get; set; }
+ public int AccountLockoutDuration { get; set; }
+ public int AccountLockoutThreshold { get; set; }
+ public int ResetAccountLockoutCounterAfter { get; set; }
+
+ public bool PasswordComplexityEnabled { get; set; }
+ public int UppercaseLettersCount { get; set; }
+ public int NumbersCount { get; set; }
+ public int SymbolsCount { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationSettings.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationSettings.cs
new file mode 100644
index 00000000..4fe39b96
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationSettings.cs
@@ -0,0 +1,8 @@
+namespace WebsitePanel.Providers.HostedSolution
+{
+ public class OrganizationSettings
+ {
+ public const string PasswordSettings = "PasswordSettings";
+ public const string GeneralSettings = "GeneralSettings";
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationSettingsEntity.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationSettingsEntity.cs
new file mode 100644
index 00000000..750e26a2
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationSettingsEntity.cs
@@ -0,0 +1,9 @@
+namespace WebsitePanel.Providers.HostedSolution
+{
+ public class OrganizationSettingsEntity
+ {
+ public int ItemId { get; set; }
+ public string SettingsName { get; set; }
+ public string Xml { get; set; }
+ }
+}
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationUser.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationUser.cs
index b0c18b83..41fed7a4 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationUser.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/OrganizationUser.cs
@@ -268,11 +268,11 @@ namespace WebsitePanel.Providers.HostedSolution
}
- public string AccountPassword
- {
- get { return accountPassword; }
- set { accountPassword = value; }
- }
+ //public string AccountPassword
+ //{
+ // get { return accountPassword; }
+ // set { accountPassword = value; }
+ //}
public string ExternalEmail { get; set; }
@@ -334,5 +334,7 @@ namespace WebsitePanel.Providers.HostedSolution
get { return userMustChangePassword; }
set { userMustChangePassword = value; }
}
+
+ public DateTime PasswordExpirationDateTime { get; set; }
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/IVirtualizationServer2012.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/IVirtualizationServer2012.cs
index ce81e1ac..479f1bc8 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/IVirtualizationServer2012.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/IVirtualizationServer2012.cs
@@ -109,7 +109,7 @@ namespace WebsitePanel.Providers.Virtualization
void TestReplicationServer(string vmId, string replicaServer, string localThumbprint);
void StartInitialReplication(string vmId);
VmReplication GetReplication(string vmId);
- bool DisableVmReplication(string vmId, string replicaServer);
+ void DisableVmReplication(string vmId);
ReplicationDetailInfo GetReplicationInfo(string vmId);
void PauseReplication(string vmId);
void ResumeReplication(string vmId);
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/ReplicationDetailInfo.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/ReplicationDetailInfo.cs
index 77fe5aa6..df941862 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/ReplicationDetailInfo.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/ReplicationDetailInfo.cs
@@ -17,6 +17,7 @@ namespace WebsitePanel.Providers.Virtualization
public TimeSpan AverageLatency { get; set; }
public int Errors { get; set; }
public int SuccessfulReplications { get; set; }
+ public int MissedReplicationCount { get; set; }
public string PendingSize { get; set; }
public DateTime LastSynhronizedAt { get; set; }
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/ReplicationState.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/ReplicationState.cs
index 394a7aa5..4dbd9e76 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/ReplicationState.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/ReplicationState.cs
@@ -14,6 +14,7 @@ namespace WebsitePanel.Providers.Virtualization
FailedOver,
NotApplicable,
ReadyForInitialReplication,
+ InitialReplicationInProgress,
Replicating,
Resynchronizing,
ResynchronizeSuspended,
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/VmReplication.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/VmReplication.cs
index 915c3a0e..2db4f114 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/VmReplication.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/Virtualization/Replication/VmReplication.cs
@@ -7,7 +7,7 @@
public string Thumbprint { get; set; }
[Persistent]
- public string VhdToReplicate { get; set; }
+ public string[] VhdToReplicate { get; set; }
[Persistent]
public ReplicaFrequency ReplicaFrequency { get; set; }
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj b/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj
index 79730c35..80c567d5 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj
@@ -119,9 +119,13 @@
+
+
+
+
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/OrganizationProvider.cs b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/OrganizationProvider.cs
index a39ff22d..f6f5015f 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/OrganizationProvider.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution/OrganizationProvider.cs
@@ -27,6 +27,7 @@
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
using System;
+using System.DirectoryServices.ActiveDirectory;
using System.IO;
using System.Xml;
using System.Linq;
@@ -394,11 +395,28 @@ namespace WebsitePanel.Providers.HostedSolution
throw new ArgumentNullException("organizationId");
string groupPath = GetGroupPath(organizationId);
+ string psoName = FormOrganizationPSOName(organizationId);
+ Runspace runspace = null;
+
try
{
+ runspace = OpenRunspace();
+
+ if (FineGrainedPasswordPolicyExist(runspace, psoName))
+ {
+ RemoveFineGrainedPasswordPolicy(runspace, psoName);
+ }
+
ActiveDirectoryUtils.DeleteADObject(groupPath);
}
- catch { /* skip */ }
+ catch
+ {
+ /* skip */
+ }
+ finally
+ {
+ CloseRunspace(runspace);
+ }
string path = GetOrganizationPath(organizationId);
ActiveDirectoryUtils.DeleteADObject(path, true);
@@ -480,6 +498,310 @@ namespace WebsitePanel.Providers.HostedSolution
return Errors.OK;
}
+ public List GetOrganizationUsersWithExpiredPassword(string organizationId, int daysBeforeExpiration)
+ {
+ return GetOrganizationUsersWithExpiredPasswordInternal(organizationId, daysBeforeExpiration);
+ }
+
+ internal List GetOrganizationUsersWithExpiredPasswordInternal(string organizationId, int daysBeforeExpiration)
+ {
+ var result = new List();
+
+ if (string.IsNullOrEmpty(organizationId))
+ {
+ return result;
+ }
+
+ Runspace runspace = null;
+
+ try
+ {
+ runspace = OpenRunspace();
+
+ var psoName = FormOrganizationPSOName(organizationId);
+
+ var maxPasswordAgeSpan = GetMaxPasswordAge(runspace, psoName);
+
+ var searchRoot = new DirectoryEntry(GetOrganizationPath(organizationId));
+
+ var search = new DirectorySearcher(searchRoot)
+ {
+ SearchScope = SearchScope.Subtree,
+ Filter = "(objectClass=user)"
+ };
+
+ search.PropertiesToLoad.Add("pwdLastSet");
+ search.PropertiesToLoad.Add("sAMAccountName");
+
+ SearchResultCollection searchResults = search.FindAll();
+
+ foreach (SearchResult searchResult in searchResults)
+ {
+ var pwdLastSetTicks = (long) searchResult.Properties["pwdLastSet"][0];
+
+ var pwdLastSetDate = DateTime.FromFileTimeUtc(pwdLastSetTicks);
+
+ var expirationDate = maxPasswordAgeSpan == TimeSpan.MaxValue ? DateTime.MaxValue : pwdLastSetDate.AddDays(maxPasswordAgeSpan.Days);
+
+ if (expirationDate.AddDays(-daysBeforeExpiration) < DateTime.Now)
+ {
+ var user = new OrganizationUser();
+
+ user.PasswordExpirationDateTime = expirationDate;
+ user.SamAccountName = (string) searchResult.Properties["sAMAccountName"][0];
+
+ result.Add(user);
+ }
+ }
+ }
+ catch (Exception)
+ {
+ throw;
+ }
+ finally
+ {
+ CloseRunspace(runspace);
+ }
+
+ return result;
+ }
+
+ internal TimeSpan GetMaxPasswordAge(Runspace runspace, string psoName)
+ {
+ if (FineGrainedPasswordPolicyExist(runspace, psoName))
+ {
+ var psoObject = GetFineGrainedPasswordPolicy(runspace, psoName);
+
+ var span = GetPSObjectProperty(psoObject, "MaxPasswordAge") as TimeSpan?;
+
+ if (span != null)
+ {
+ return span.Value;
+ }
+ }
+
+
+ using (Domain d = Domain.GetCurrentDomain())
+ {
+ using (DirectoryEntry domain = d.GetDirectoryEntry())
+ {
+ DirectorySearcher ds = new DirectorySearcher(
+ domain,
+ "(objectClass=*)",
+ null,
+ SearchScope.Base
+ );
+
+ SearchResult sr = ds.FindOne();
+
+ if (sr != null && sr.Properties.Contains("maxPwdAge"))
+ {
+ try
+ {
+ return TimeSpan.FromTicks((long)sr.Properties["maxPwdAge"][0]).Duration();
+
+ }
+ catch (Exception)
+ {
+ return TimeSpan.MaxValue;
+ }
+ }
+
+ throw new Exception("'maxPwdAge' property not found.");
+ }
+ }
+ }
+
+ public bool CheckPhoneNumberIsInUse(string phoneNumber, string userPrincipalName = null)
+ {
+ if (string.IsNullOrEmpty(phoneNumber))
+ {
+ return false;
+ }
+
+ phoneNumber = phoneNumber.Replace("+", "");
+
+ var userExcludeQuery = string.IsNullOrEmpty(userPrincipalName) ? string.Empty : string.Format("(!(UserPrincipalName={0}))", userPrincipalName);
+
+ string query = string.Format("(&" +
+ "(objectClass=user)" +
+ "(|" +
+ "(|(facsimileTelephoneNumber=+{0})(facsimileTelephoneNumber={0}))" +
+ "(|(homePhone=+{0})(homePhone={0}))" +
+ "(|(mobile=+{0})(mobile={0}))" +
+ "(|(pager=+{0})(pager={0}))" +
+ "(|(telephoneNumber=+{0})(telephoneNumber={0}))" +
+ ")" +
+ "{1}" +
+ ")", phoneNumber, userExcludeQuery);
+
+ using (Domain d = Domain.GetCurrentDomain())
+ {
+ using (DirectoryEntry domain = d.GetDirectoryEntry())
+ {
+
+ var search = new DirectorySearcher(domain)
+ {
+ SearchScope = SearchScope.Subtree,
+ Filter = query
+ };
+
+ search.PropertiesToLoad.Add(ADAttributes.Fax);
+ search.PropertiesToLoad.Add(ADAttributes.HomePhone);
+ search.PropertiesToLoad.Add(ADAttributes.MobilePhone);
+ search.PropertiesToLoad.Add(ADAttributes.Pager);
+ search.PropertiesToLoad.Add(ADAttributes.BusinessPhone);
+
+ SearchResult result = search.FindOne();
+
+ if (result != null)
+ {
+ return true;
+ }
+
+ return false;
+ }
+ }
+ }
+
+ public void ApplyPasswordSettings(string organizationId, OrganizationPasswordSettings settings)
+ {
+ HostedSolutionLog.LogStart("ApplyPasswordPolicy");
+
+ Runspace runspace = null;
+
+ var psoName = FormOrganizationPSOName(organizationId);
+
+ try
+ {
+ runspace = OpenRunspace();
+
+ if (!FineGrainedPasswordPolicyExist(runspace, psoName))
+ {
+ CreateFineGrainedPasswordPolicy(runspace, organizationId, psoName, settings);
+
+ string groupPath = GetGroupPath(organizationId);
+
+ SetFineGrainedPasswordPolicySubject(runspace, groupPath, psoName);
+ }
+ else
+ {
+ UpdateFineGrainedPasswordPolicy(runspace, psoName, settings);
+ }
+ }
+ catch (Exception ex)
+ {
+ HostedSolutionLog.LogError(ex);
+ throw;
+ }
+ finally
+ {
+ CloseRunspace(runspace);
+ HostedSolutionLog.LogEnd("ApplyPasswordPolicy");
+ }
+ }
+
+ private string FormOrganizationPSOName(string organizationId)
+ {
+ return string.Format("{0}-PSO", organizationId);
+ }
+
+ private bool FineGrainedPasswordPolicyExist(Runspace runspace, string psoName)
+ {
+ try
+ {
+ var cmd = new Command("Get-ADFineGrainedPasswordPolicy");
+ cmd.Parameters.Add("Identity", psoName);
+
+ var result = ExecuteShellCommand(runspace, cmd);
+ }
+ catch (Exception e)
+ {
+ return false;
+ }
+
+ return true;
+ }
+
+ private PSObject GetFineGrainedPasswordPolicy(Runspace runspace, string psoName)
+ {
+ var cmd = new Command("Get-ADFineGrainedPasswordPolicy");
+ cmd.Parameters.Add("Identity", psoName);
+
+ return ExecuteShellCommand(runspace, cmd).FirstOrDefault();
+ }
+
+ private void CreateFineGrainedPasswordPolicy(Runspace runspace, string organizationId, string psoName, OrganizationPasswordSettings settings)
+ {
+ var cmd = new Command("New-ADFineGrainedPasswordPolicy");
+ cmd.Parameters.Add("Name", psoName);
+ cmd.Parameters.Add("Description", string.Format("The {0} Password Policy", organizationId));
+ cmd.Parameters.Add("Precedence", 50);
+ cmd.Parameters.Add("MinPasswordLength", settings.MinimumLength);
+ cmd.Parameters.Add("PasswordHistoryCount", settings.EnforcePasswordHistory);
+ cmd.Parameters.Add("ComplexityEnabled", false);
+ cmd.Parameters.Add("ReversibleEncryptionEnabled", false);
+
+ if (settings.LockoutSettingsEnabled)
+ {
+ cmd.Parameters.Add("LockoutDuration", new TimeSpan(0, settings.AccountLockoutDuration, 0));
+ cmd.Parameters.Add("LockoutThreshold", settings.AccountLockoutThreshold);
+ cmd.Parameters.Add("LockoutObservationWindow", new TimeSpan(0, settings.ResetAccountLockoutCounterAfter, 0));
+ }
+
+ ExecuteShellCommand(runspace, cmd);
+ }
+
+ private void SetFineGrainedPasswordPolicySubject(Runspace runspace, string subjectPath, string psoName)
+ {
+ var entry = new DirectoryEntry(subjectPath);
+
+ var cmd = new Command("Add-ADFineGrainedPasswordPolicySubject");
+ cmd.Parameters.Add("Identity", psoName);
+ cmd.Parameters.Add("Subjects", entry.Properties[ADAttributes.SAMAccountName].Value.ToString());
+
+ ExecuteShellCommand(runspace, cmd);
+
+ cmd = new Command("Set-ADGroup");
+ cmd.Parameters.Add("Identity", entry.Properties[ADAttributes.SAMAccountName].Value.ToString());
+ cmd.Parameters.Add("GroupScope", "Global");
+
+ ExecuteShellCommand(runspace, cmd);
+ }
+
+ private void UpdateFineGrainedPasswordPolicy(Runspace runspace, string psoName, OrganizationPasswordSettings settings)
+ {
+ var cmd = new Command("Set-ADFineGrainedPasswordPolicy");
+ cmd.Parameters.Add("Identity", psoName);
+ cmd.Parameters.Add("MinPasswordLength", settings.MinimumLength);
+ cmd.Parameters.Add("PasswordHistoryCount", settings.EnforcePasswordHistory);
+ cmd.Parameters.Add("ComplexityEnabled", false);
+ cmd.Parameters.Add("ReversibleEncryptionEnabled", false);
+
+ if (settings.LockoutSettingsEnabled)
+ {
+ cmd.Parameters.Add("LockoutDuration", new TimeSpan(0, settings.AccountLockoutDuration, 0));
+ cmd.Parameters.Add("LockoutThreshold", settings.AccountLockoutThreshold);
+ cmd.Parameters.Add("LockoutObservationWindow", new TimeSpan(0, settings.ResetAccountLockoutCounterAfter, 0));
+ }
+ else
+ {
+ cmd.Parameters.Add("LockoutDuration", new TimeSpan(0));
+ cmd.Parameters.Add("LockoutThreshold", 0);
+ cmd.Parameters.Add("LockoutObservationWindow", 0);
+ }
+
+ ExecuteShellCommand(runspace, cmd);
+ }
+
+ private void RemoveFineGrainedPasswordPolicy(Runspace runspace, string psoName)
+ {
+ var cmd = new Command("Remove-ADFineGrainedPasswordPolicy");
+ cmd.Parameters.Add("Identity", psoName);
+
+ ExecuteShellCommand(runspace, cmd);
+ }
+
public PasswordPolicyResult GetPasswordPolicy()
{
return GetPasswordPolicyInternal();
@@ -597,7 +919,7 @@ namespace WebsitePanel.Providers.HostedSolution
string path = GetUserPath(organizationId, loginName);
- OrganizationUser retUser = GetUser(path);
+ OrganizationUser retUser = GetUser(organizationId, path);
HostedSolutionLog.LogEnd("GetUserGeneralSettingsInternal");
return retUser;
@@ -650,7 +972,7 @@ namespace WebsitePanel.Providers.HostedSolution
user.Properties[ADAttributes.PwdLastSet].Value = userMustChangePassword ? 0 : -1;
}
- private OrganizationUser GetUser(string path)
+ private OrganizationUser GetUser(string organizationId, string path)
{
OrganizationUser retUser = new OrganizationUser();
@@ -686,9 +1008,41 @@ namespace WebsitePanel.Providers.HostedSolution
retUser.UserPrincipalName = (string)entry.InvokeGet(ADAttributes.UserPrincipalName);
retUser.UserMustChangePassword = GetUserMustChangePassword(entry);
+ var psoName = FormOrganizationPSOName(organizationId);
+
+ retUser.PasswordExpirationDateTime = GetPasswordExpirationDate(psoName, entry);
+
return retUser;
}
+ private DateTime GetPasswordExpirationDate(string psoName, DirectoryEntry entry)
+ {
+ Runspace runspace = null;
+
+ try
+ {
+ runspace = OpenRunspace();
+
+ var maxPasswordAgeSpan = GetMaxPasswordAge(runspace, psoName);
+
+ var pwdLastSetTicks = ConvertADSLargeIntegerToInt64(entry.Properties[ADAttributes.PwdLastSet].Value);
+
+ var pwdLastSetDate = DateTime.FromFileTimeUtc(pwdLastSetTicks);
+
+ if (maxPasswordAgeSpan == TimeSpan.MaxValue)
+ {
+ return DateTime.MaxValue;
+ }
+
+ return pwdLastSetDate.AddDays(maxPasswordAgeSpan.Days);
+ }
+ finally
+ {
+ CloseRunspace(runspace);
+ }
+
+ }
+
private string GetDomainName(string username)
{
string domain = ActiveDirectoryUtils.GetNETBIOSDomainName(RootDomain);
@@ -1055,7 +1409,7 @@ namespace WebsitePanel.Providers.HostedSolution
foreach (string userPath in ActiveDirectoryUtils.GetGroupObjects(groupName, "user", organizationEntry))
{
- OrganizationUser tmpUser = GetUser(userPath);
+ OrganizationUser tmpUser = GetUser(organizationId, userPath);
members.Add(new ExchangeAccount
{
@@ -1326,12 +1680,46 @@ namespace WebsitePanel.Providers.HostedSolution
internal void DeleteMappedDriveByPathInternal(string organizationId, string path)
{
- MappedDrive drive = GetDriveMaps(organizationId).Where(x => x.Path == path).FirstOrDefault();
+ HostedSolutionLog.LogStart("DeleteMappedDriveInternal");
+ HostedSolutionLog.DebugInfo("path : {0}:", path);
+ HostedSolutionLog.DebugInfo("organizationId : {0}", organizationId);
- if (drive != null)
- {
- DeleteMappedDriveInternal(organizationId, drive.DriveLetter);
- }
+ if (string.IsNullOrEmpty(organizationId))
+ throw new ArgumentNullException("organizationId");
+
+ if (string.IsNullOrEmpty(path))
+ throw new ArgumentNullException("path");
+
+ string gpoId;
+
+ if (!CheckMappedDriveGpoExists(organizationId, out gpoId))
+ {
+ CreateAndLinkMappedDrivesGPO(organizationId, out gpoId);
+ }
+
+ if (!string.IsNullOrEmpty(gpoId))
+ {
+ string filePath = string.Format("{0}\\{1}",
+ string.Format(GROUP_POLICY_MAPPED_DRIVES_FILE_PATH_TEMPLATE, RootDomain, gpoId),
+ "Drives.xml");
+
+ // open xml document
+ XmlDocument xml = new XmlDocument();
+ xml.Load(filePath);
+
+ XmlNode drive = xml.SelectSingleNode(string.Format("./Drives/Drive[contains(Properties/@path,'{0}')]", path));
+
+ if (drive != null)
+ {
+ drive.ParentNode.RemoveChild(drive);
+ }
+
+ xml.Save(filePath);
+
+ IncrementGPOVersion(organizationId, gpoId);
+ }
+
+ HostedSolutionLog.LogEnd("DeleteMappedDriveInternal");
}
public void DeleteMappedDrive(string organizationId, string drive)
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Mail.IceWarp/IceWarp.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Mail.IceWarp/IceWarp.cs
index a4fe06aa..43c2c9a4 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Mail.IceWarp/IceWarp.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Mail.IceWarp/IceWarp.cs
@@ -31,6 +31,7 @@ using System.IO;
using System.Net.Mail;
using System.Collections.Generic;
using System.Linq;
+using System.Runtime.InteropServices;
using System.Text;
using System.Text.RegularExpressions;
using Microsoft.Win32;
@@ -38,15 +39,15 @@ using WebsitePanel.Server.Utils;
namespace WebsitePanel.Providers.Mail
{
- public class IceWarp : HostingServiceProviderBase, IMailServer
+ public class IceWarp : HostingServiceProviderBase, IMailServer, IDisposable
{
protected const string API_PROGID = "IceWarpServer.APIObject";
protected const string DOMAIN_PROGID = "IceWarpServer.DomainObject";
protected const string ACCOUNT_PROGID = "IceWarpServer.AccountObject";
-
+
private dynamic _currentApiObject = null;
- #region IceWarp Enums
+ #region Protected Enums
protected enum IceWarpErrorCode
{
@@ -109,8 +110,8 @@ namespace WebsitePanel.Providers.Mail
get
{
var apiObject = GetApiObject();
- var adresses = ((object) apiObject.GetProperty("C_System_Services_BindIPAddress"));
- return adresses == null ? "" : adresses.ToString().Split(new[] {';'}, StringSplitOptions.RemoveEmptyEntries).FirstOrDefault();
+ var adresses = ((object)apiObject.GetProperty("C_System_Services_BindIPAddress"));
+ return adresses == null ? "" : adresses.ToString().Split(new[] { ';' }, StringSplitOptions.RemoveEmptyEntries).FirstOrDefault();
}
}
@@ -119,7 +120,7 @@ namespace WebsitePanel.Providers.Mail
get
{
var apiObject = GetApiObject();
- return Convert.ToBoolean((object) apiObject.GetProperty("C_Accounts_Global_Domains_UseDiskQuota"));
+ return Convert.ToBoolean((object)apiObject.GetProperty("C_Accounts_Global_Domains_UseDiskQuota"));
}
}
@@ -128,7 +129,7 @@ namespace WebsitePanel.Providers.Mail
get
{
var apiObject = GetApiObject();
- return Convert.ToBoolean((object) apiObject.GetProperty("C_Accounts_Global_Domains_UseDomainLimits"));
+ return Convert.ToBoolean((object)apiObject.GetProperty("C_Accounts_Global_Domains_UseDomainLimits"));
}
}
@@ -137,7 +138,7 @@ namespace WebsitePanel.Providers.Mail
get
{
var apiObject = GetApiObject();
- return Convert.ToBoolean((object) apiObject.GetProperty("C_Accounts_Global_Domains_UseUserLimits"));
+ return Convert.ToBoolean((object)apiObject.GetProperty("C_Accounts_Global_Domains_UseUserLimits"));
}
}
@@ -146,7 +147,7 @@ namespace WebsitePanel.Providers.Mail
get
{
var apiObject = GetApiObject();
- return Convert.ToBoolean((object) apiObject.GetProperty("C_Accounts_Global_Domains_OverrideGlobal"));
+ return Convert.ToBoolean((object)apiObject.GetProperty("C_Accounts_Global_Domains_OverrideGlobal"));
}
}
@@ -155,16 +156,16 @@ namespace WebsitePanel.Providers.Mail
get
{
var apiObject = GetApiObject();
- return Convert.ToInt32((object) apiObject.GetProperty("C_Mail_SMTP_Delivery_MaxMsgSize"))/1024/1024;
+ return Convert.ToInt32((object)apiObject.GetProperty("C_Mail_SMTP_Delivery_MaxMsgSize")) / 1024 / 1024;
}
}
-
+
protected int WarnMailboxUsage
{
get
{
var apiObject = GetApiObject();
- return Convert.ToInt32((object)apiObject.GetProperty("C_Accounts_Global_Domains_WarnMailboxUsage"));
+ return Convert.ToInt32((object)apiObject.GetProperty("C_Accounts_Global_Domains_WarnMailboxUsage"));
}
}
@@ -176,7 +177,7 @@ namespace WebsitePanel.Providers.Mail
return Convert.ToInt32((object)apiObject.GetProperty("C_Accounts_Global_Domains_WarnDomainSize"));
}
}
-
+
private void SaveApiSetting(dynamic apiObject)
{
@@ -194,7 +195,7 @@ namespace WebsitePanel.Providers.Mail
protected static string GetErrorMessage(int errorCode)
{
- switch ((IceWarpErrorCode) errorCode)
+ switch ((IceWarpErrorCode)errorCode)
{
case IceWarpErrorCode.S_OK:
return "OK";
@@ -248,6 +249,11 @@ namespace WebsitePanel.Providers.Mail
}
}
+ protected void DisposeObject(object obj)
+ {
+ Marshal.FinalReleaseComObject(obj);
+ }
+
protected dynamic GetApiObject()
{
if (_currentApiObject != null) return _currentApiObject;
@@ -386,6 +392,8 @@ namespace WebsitePanel.Providers.Mail
}
}
+ DisposeObject(accountObject);
+
return mailAccounts.ToArray();
}
@@ -399,7 +407,7 @@ namespace WebsitePanel.Providers.Mail
apiObject.SetProperty("C_Accounts_Global_Domains_WarnMailboxUsage", ProviderSettings["WarnMailboxUsage"]);
apiObject.SetProperty("C_Accounts_Global_Domains_WarnDomainSize", ProviderSettings["WarnDomainSize"]);
- apiObject.SetProperty("C_Mail_SMTP_Delivery_MaxMsgSize", Convert.ToInt32(ProviderSettings["MaxMessageSize"])*1024*1024);
+ apiObject.SetProperty("C_Mail_SMTP_Delivery_MaxMsgSize", Convert.ToInt32(ProviderSettings["MaxMessageSize"]) * 1024 * 1024);
apiObject.SetProperty("C_Mail_SMTP_Delivery_LimitMsgSize", Convert.ToInt32(ProviderSettings["MaxMessageSize"]) > 0);
SaveApiSetting(apiObject);
@@ -407,11 +415,11 @@ namespace WebsitePanel.Providers.Mail
#endregion
- #region IHostingServiceProvier methods
+ #region IHostingServiceProvier methods
- public override SettingPair[] GetProviderDefaultSettings()
- {
- var settings = new []
+ public override SettingPair[] GetProviderDefaultSettings()
+ {
+ var settings = new[]
{
new SettingPair("UseDomainDiskQuota", UseDomainDiskQuota.ToString()),
new SettingPair("UseDomainLimits", UseDomainLimits.ToString()),
@@ -423,8 +431,8 @@ namespace WebsitePanel.Providers.Mail
new SettingPair("ServerIpAddress", BindIpAddress)
};
- return settings;
- }
+ return settings;
+ }
public override string[] Install()
{
@@ -433,25 +441,25 @@ namespace WebsitePanel.Providers.Mail
}
public override void ChangeServiceItemsState(ServiceProviderItem[] items, bool enabled)
- {
- foreach (var item in items.OfType())
- {
- try
- {
- // enable/disable mail domain
- if (DomainExists(item.Name))
- {
- var mailDomain = GetDomain(item.Name);
- mailDomain.Enabled = enabled;
- UpdateDomain(mailDomain);
- }
- }
- catch (Exception ex)
- {
- Log.WriteError(String.Format("Error switching '{0}' IceWarp domain", item.Name), ex);
- }
- }
- }
+ {
+ foreach (var item in items.OfType())
+ {
+ try
+ {
+ // enable/disable mail domain
+ if (DomainExists(item.Name))
+ {
+ var mailDomain = GetDomain(item.Name);
+ mailDomain.Enabled = enabled;
+ UpdateDomain(mailDomain);
+ }
+ }
+ catch (Exception ex)
+ {
+ Log.WriteError(String.Format("Error switching '{0}' IceWarp domain", item.Name), ex);
+ }
+ }
+ }
public override void DeleteServiceItems(ServiceProviderItem[] items)
{
@@ -470,64 +478,69 @@ namespace WebsitePanel.Providers.Mail
}
public override ServiceProviderItemDiskSpace[] GetServiceItemsDiskSpace(ServiceProviderItem[] items)
- {
- var itemsDiskspace = new List();
+ {
+ var itemsDiskspace = new List();
+
+ var accountObject = GetAccountObject();
- // update items with diskspace
- foreach (var item in items.OfType())
- {
- try
- {
- Log.WriteStart(String.Format("Calculating mail account '{0}' size", item.Name));
- // calculate disk space
- var accountObject = GetAccountObject(item.Name);
- var size = Convert.ToInt64((object)accountObject.GetProperty("U_MailboxSize")) * 1024;
+ // update items with diskspace
+ foreach (var item in items.OfType())
+ {
+ try
+ {
+ Log.WriteStart(String.Format("Calculating mail account '{0}' size", item.Name));
+ // calculate disk space
+ accountObject.Open(item.Name);
+ var size = Convert.ToInt64((object)accountObject.GetProperty("U_MailboxSize")) * 1024;
- var diskspace = new ServiceProviderItemDiskSpace {ItemId = item.Id, DiskSpace = size};
- itemsDiskspace.Add(diskspace);
- Log.WriteEnd(String.Format("Calculating mail account '{0}' size", item.Name));
- }
- catch (Exception ex)
- {
- Log.WriteError(ex);
- }
- }
- return itemsDiskspace.ToArray();
- }
+ var diskspace = new ServiceProviderItemDiskSpace { ItemId = item.Id, DiskSpace = size };
+ itemsDiskspace.Add(diskspace);
- public override ServiceProviderItemBandwidth[] GetServiceItemsBandwidth(ServiceProviderItem[] items, DateTime since)
- {
- var itemsBandwidth = new ServiceProviderItemBandwidth[items.Length];
+ Log.WriteEnd(String.Format("Calculating mail account '{0}' size", item.Name));
+ }
+ catch (Exception ex)
+ {
+ Log.WriteError(ex);
+ }
+ }
- // update items with diskspace
- for (int i = 0; i < items.Length; i++)
- {
- ServiceProviderItem item = items[i];
+ DisposeObject(accountObject);
- // create new bandwidth object
- itemsBandwidth[i] = new ServiceProviderItemBandwidth
- {
- ItemId = item.Id,
+ return itemsDiskspace.ToArray();
+ }
+
+ public override ServiceProviderItemBandwidth[] GetServiceItemsBandwidth(ServiceProviderItem[] items, DateTime since)
+ {
+ var itemsBandwidth = new ServiceProviderItemBandwidth[items.Length];
+
+ // update items with bandwidth
+ for (var i = 0; i < items.Length; i++)
+ {
+ var item = items[i];
+
+ // create new bandwidth object
+ itemsBandwidth[i] = new ServiceProviderItemBandwidth
+ {
+ ItemId = item.Id,
Days = new DailyStatistics[0]
- };
+ };
- if (item is MailDomain)
- {
- try
- {
- // get daily statistics
- itemsBandwidth[i].Days = GetDailyStatistics(since, item.Name);
- }
- catch (Exception ex)
- {
- Log.WriteError(ex);
- System.Diagnostics.Debug.WriteLine(ex);
- }
- }
- }
+ if (!(item is MailDomain)) continue;
- return itemsBandwidth;
- }
+ try
+ {
+ // get daily statistics
+ itemsBandwidth[i].Days = GetDailyStatistics(since, item.Name);
+ }
+ catch (Exception ex)
+ {
+ Log.WriteError(ex);
+ System.Diagnostics.Debug.WriteLine(ex);
+ }
+ }
+
+ return itemsBandwidth;
+ }
public DailyStatistics[] GetDailyStatistics(DateTime since, string maildomainName)
{
@@ -565,11 +578,11 @@ namespace WebsitePanel.Providers.Mail
case '*':
var dailyStats = new DailyStatistics
{
- Year = date.Year,
- Month = date.Month,
- Day = date.Day,
- BytesSent = Convert.ToInt64(fields[mailSentField])*1024,
- BytesReceived = Convert.ToInt64(fields[mailReceivedField])*1024
+ Year = date.Year,
+ Month = date.Month,
+ Day = date.Day,
+ BytesSent = Convert.ToInt64(fields[mailSentField]) * 1024,
+ BytesReceived = Convert.ToInt64(fields[mailReceivedField]) * 1024
};
days.Add(dailyStats);
continue;
@@ -618,7 +631,7 @@ namespace WebsitePanel.Providers.Mail
// Checking for version 10.4.0 (released 2012-03-21) or newer
// This version introduced L_ListFile_Contents, G_ListFile_Contents and M_ListFileContents that is the latest API variable used by this provider
- var split = version.Split(new[] {'.'});
+ var split = version.Split(new[] { '.' });
var majorVersion = Convert.ToInt32(split[0]);
var minVersion = Convert.ToInt32(split[1]);
@@ -636,32 +649,34 @@ namespace WebsitePanel.Providers.Mail
public string[] GetDomains()
{
var api = GetApiObject();
- return api.GetDomainList().Split(new[] {';'}, StringSplitOptions.RemoveEmptyEntries);
+ return api.GetDomainList().Split(new[] { ';' }, StringSplitOptions.RemoveEmptyEntries);
}
public MailDomain GetDomain(string domainName)
{
- var domain = GetDomainObject(domainName);
+ var domainObject = GetDomainObject(domainName);
var mailDomain = new MailDomain
{
- Name = domain.Name,
- PostmasterAccount = domain.GetProperty("D_AdminEmail"),
- CatchAllAccount = domain.GetProperty("D_UnknownForwardTo"),
- Enabled = Convert.ToBoolean((object) domain.GetProperty("D_DisableLogin")),
- MaxDomainSizeInMB = Convert.ToInt32((object) domain.GetProperty("D_DiskQuota"))/1024,
- MaxDomainUsers = Convert.ToInt32((object) domain.GetProperty("D_AccountNumber")),
- MegaByteSendLimit = Convert.ToInt32((object) domain.GetProperty("D_VolumeLimit"))/1024,
- NumberSendLimit = Convert.ToInt32((object) domain.GetProperty("D_NumberLimit")),
- DefaultUserQuotaInMB = Convert.ToInt32((object) domain.GetProperty("D_UserMailbox"))/1024,
- DefaultUserMaxMessageSizeMegaByte = Convert.ToInt32((object) domain.GetProperty("D_UserMsg"))/1024,
- DefaultUserMegaByteSendLimit = Convert.ToInt32((object) domain.GetProperty("D_UserMB")),
- DefaultUserNumberSendLimit = Convert.ToInt32((object) domain.GetProperty("D_UserNumber")),
+ Name = domainObject.Name,
+ PostmasterAccount = domainObject.GetProperty("D_AdminEmail"),
+ CatchAllAccount = domainObject.GetProperty("D_UnknownForwardTo"),
+ Enabled = Convert.ToBoolean((object)domainObject.GetProperty("D_DisableLogin")),
+ MaxDomainSizeInMB = Convert.ToInt32((object)domainObject.GetProperty("D_DiskQuota")) / 1024,
+ MaxDomainUsers = Convert.ToInt32((object)domainObject.GetProperty("D_AccountNumber")),
+ MegaByteSendLimit = Convert.ToInt32((object)domainObject.GetProperty("D_VolumeLimit")) / 1024,
+ NumberSendLimit = Convert.ToInt32((object)domainObject.GetProperty("D_NumberLimit")),
+ DefaultUserQuotaInMB = Convert.ToInt32((object)domainObject.GetProperty("D_UserMailbox")) / 1024,
+ DefaultUserMaxMessageSizeMegaByte = Convert.ToInt32((object)domainObject.GetProperty("D_UserMsg")) / 1024,
+ DefaultUserMegaByteSendLimit = Convert.ToInt32((object)domainObject.GetProperty("D_UserMB")),
+ DefaultUserNumberSendLimit = Convert.ToInt32((object)domainObject.GetProperty("D_UserNumber")),
UseDomainDiskQuota = Convert.ToBoolean(ProviderSettings["UseDomainDiskQuota"]),
UseDomainLimits = Convert.ToBoolean(ProviderSettings["UseDomainLimits"]),
UseUserLimits = Convert.ToBoolean(ProviderSettings["UseUserLimits"])
};
+ DisposeObject(domainObject);
+
return mailDomain;
}
@@ -685,6 +700,8 @@ namespace WebsitePanel.Providers.Mail
SaveDomain(domainObject);
+ DisposeObject(domainObject);
+
UpdateDomain(domain);
}
@@ -706,17 +723,19 @@ namespace WebsitePanel.Providers.Mail
}
domainObject.SetProperty("D_DisableLogin", !domain.Enabled);
- domainObject.SetProperty("D_DiskQuota", domain.MaxDomainSizeInMB*1024);
+ domainObject.SetProperty("D_DiskQuota", domain.MaxDomainSizeInMB * 1024);
domainObject.SetProperty("D_AccountNumber", domain.MaxDomainUsers);
- domainObject.SetProperty("D_VolumeLimit", domain.MegaByteSendLimit*1024);
+ domainObject.SetProperty("D_VolumeLimit", domain.MegaByteSendLimit * 1024);
domainObject.SetProperty("D_NumberLimit", domain.NumberSendLimit);
- domainObject.SetProperty("D_UserMailbox", domain.DefaultUserQuotaInMB*1024);
- domainObject.SetProperty("D_UserMsg", domain.DefaultUserMaxMessageSizeMegaByte*1024);
+ domainObject.SetProperty("D_UserMailbox", domain.DefaultUserQuotaInMB * 1024);
+ domainObject.SetProperty("D_UserMsg", domain.DefaultUserMaxMessageSizeMegaByte * 1024);
domainObject.SetProperty("D_UserMB", domain.DefaultUserMegaByteSendLimit);
domainObject.SetProperty("D_UserNumber", domain.DefaultUserNumberSendLimit);
SaveDomain(domainObject);
+
+ DisposeObject(domainObject);
}
public void DeleteDomain(string domainName)
@@ -732,6 +751,8 @@ namespace WebsitePanel.Providers.Mail
{
Log.WriteError("Could not delete domain" + GetErrorMessage(domainObject.LastErr), null);
}
+
+ DisposeObject(domainObject);
}
#endregion
@@ -747,7 +768,11 @@ namespace WebsitePanel.Providers.Mail
var domainObject = GetDomainObject(aliasName);
- return Convert.ToInt32((object) domainObject.GetProperty("D_Type")) == 2 && string.Compare(domainObject.GetProperty("D_DomainValue").ToString(), domainName, true) == 0;
+ var result = Convert.ToInt32((object)domainObject.GetProperty("D_Type")) == 2 && string.Compare(domainObject.GetProperty("D_DomainValue").ToString(), domainName, true) == 0;
+
+ DisposeObject(domainObject);
+
+ return result;
}
public string[] GetDomainAliases(string domainName)
@@ -772,13 +797,15 @@ namespace WebsitePanel.Providers.Mail
public void AddDomainAlias(string domainName, string aliasName)
{
- var mailDomain = new MailDomain {Name = aliasName};
+ var mailDomain = new MailDomain { Name = aliasName };
CreateDomain(mailDomain);
var domainObject = GetDomainObject(aliasName);
domainObject.SetProperty("D_Type", 2);
domainObject.SetProperty("D_DomainValue", domainName);
SaveDomain(domainObject);
+
+ DisposeObject(domainObject);
}
public void DeleteDomainAlias(string domainName, string aliasName)
@@ -794,7 +821,11 @@ namespace WebsitePanel.Providers.Mail
{
var accountObject = GetAccountObject();
- return accountObject.Open(mailboxName) && Convert.ToInt32((object) accountObject.GetProperty("U_Type")) == (int) IceWarpAccountType.User;
+ var result = accountObject.Open(mailboxName) && Convert.ToInt32((object)accountObject.GetProperty("U_Type")) == (int)IceWarpAccountType.User;
+
+ DisposeObject(accountObject);
+
+ return result;
}
protected class IceWarpResponderContent
@@ -840,35 +871,35 @@ namespace WebsitePanel.Providers.Mail
return result;
}
- protected static MailAccount CreateMailAccountFromAccountObject(dynamic accountObject)
+ protected MailAccount CreateMailAccountFromAccountObject(dynamic accountObject)
{
var mailAccount = new MailAccount
{
Name = accountObject.EmailAddress,
FullName = accountObject.GetProperty("U_Name"),
- Enabled = Convert.ToInt32((object) accountObject.GetProperty("U_AccountDisabled")) == 0,
- ForwardingEnabled = !string.IsNullOrWhiteSpace(accountObject.GetProperty("U_ForwardTo")) || string.IsNullOrWhiteSpace(accountObject.GetProperty("U_RemoteAddress")) && Convert.ToBoolean((object) accountObject.GetProperty("U_UseRemoteAddress")),
- IsDomainAdmin = Convert.ToBoolean((object) accountObject.GetProperty("U_DomainAdmin")),
- MaxMailboxSize = Convert.ToBoolean((object) accountObject.GetProperty("U_MaxBox")) ? Convert.ToInt32((object) accountObject.GetProperty("U_MaxBoxSize"))/1024 : 0,
+ Enabled = Convert.ToInt32((object)accountObject.GetProperty("U_AccountDisabled")) == 0,
+ ForwardingEnabled = !string.IsNullOrWhiteSpace(accountObject.GetProperty("U_ForwardTo")) || string.IsNullOrWhiteSpace(accountObject.GetProperty("U_RemoteAddress")) && Convert.ToBoolean((object)accountObject.GetProperty("U_UseRemoteAddress")),
+ IsDomainAdmin = Convert.ToBoolean((object)accountObject.GetProperty("U_DomainAdmin")),
+ MaxMailboxSize = Convert.ToBoolean((object)accountObject.GetProperty("U_MaxBox")) ? Convert.ToInt32((object)accountObject.GetProperty("U_MaxBoxSize")) / 1024 : 0,
Password = accountObject.GetProperty("U_Password"),
- ResponderEnabled = Convert.ToInt32((object) accountObject.GetProperty("U_Respond")) > 0,
- QuotaUsed = Convert.ToInt64((object) accountObject.GetProperty("U_MailBoxSize")),
- MaxMessageSizeMegaByte = Convert.ToInt32((object) accountObject.GetProperty("U_MaxMessageSize"))/1024,
- MegaByteSendLimit = Convert.ToInt32((object) accountObject.GetProperty("U_MegabyteSendLimit")),
- NumberSendLimit = Convert.ToInt32((object) accountObject.GetProperty("U_NumberSendLimit")),
- DeleteOlder = Convert.ToBoolean((object) accountObject.GetProperty("U_DeleteOlder")),
- DeleteOlderDays = Convert.ToInt32((object) accountObject.GetProperty("U_DeleteOlderDays")),
- ForwardOlder = Convert.ToBoolean((object) accountObject.GetProperty("U_ForwardOlder")),
- ForwardOlderDays = Convert.ToInt32((object) accountObject.GetProperty("U_ForwardOlderDays")),
+ ResponderEnabled = Convert.ToInt32((object)accountObject.GetProperty("U_Respond")) > 0,
+ QuotaUsed = Convert.ToInt64((object)accountObject.GetProperty("U_MailBoxSize")),
+ MaxMessageSizeMegaByte = Convert.ToInt32((object)accountObject.GetProperty("U_MaxMessageSize")) / 1024,
+ MegaByteSendLimit = Convert.ToInt32((object)accountObject.GetProperty("U_MegabyteSendLimit")),
+ NumberSendLimit = Convert.ToInt32((object)accountObject.GetProperty("U_NumberSendLimit")),
+ DeleteOlder = Convert.ToBoolean((object)accountObject.GetProperty("U_DeleteOlder")),
+ DeleteOlderDays = Convert.ToInt32((object)accountObject.GetProperty("U_DeleteOlderDays")),
+ ForwardOlder = Convert.ToBoolean((object)accountObject.GetProperty("U_ForwardOlder")),
+ ForwardOlderDays = Convert.ToInt32((object)accountObject.GetProperty("U_ForwardOlderDays")),
ForwardOlderTo = accountObject.GetProperty("U_ForwardOlderTo"),
- IceWarpAccountState = Convert.ToInt32((object) accountObject.GetProperty("U_AccountDisabled")),
- IceWarpAccountType = Convert.ToInt32((object) accountObject.GetProperty("U_AccountType")),
- IceWarpRespondType = Convert.ToInt32((object) accountObject.GetProperty("U_Respond"))
+ IceWarpAccountState = Convert.ToInt32((object)accountObject.GetProperty("U_AccountDisabled")),
+ IceWarpAccountType = Convert.ToInt32((object)accountObject.GetProperty("U_AccountType")),
+ IceWarpRespondType = Convert.ToInt32((object)accountObject.GetProperty("U_Respond"))
};
if (mailAccount.ForwardingEnabled)
{
- mailAccount.ForwardingAddresses = new string[] {accountObject.GetProperty("U_ForwardTo") + accountObject.GetProperty("U_RemoteAddress")};
+ mailAccount.ForwardingAddresses = new string[] { accountObject.GetProperty("U_ForwardTo") + accountObject.GetProperty("U_RemoteAddress") };
mailAccount.DeleteOnForward = Convert.ToInt32(accountObject.GetProperty("U_UseRemoteAddress")) == 1;
mailAccount.RetainLocalCopy = !mailAccount.DeleteOnForward;
}
@@ -889,7 +920,7 @@ namespace WebsitePanel.Providers.Mail
mailAccount.RespondTo = respondTo;
}
- mailAccount.RespondPeriodInDays = Convert.ToInt32((object) accountObject.GetProperty("U_RespondPeriod"));
+ mailAccount.RespondPeriodInDays = Convert.ToInt32((object)accountObject.GetProperty("U_RespondPeriod"));
var responderContent = ParseResponderContent(accountObject.GetProperty("U_ResponderContent"));
mailAccount.ResponderMessage = responderContent.Content;
mailAccount.ResponderSubject = responderContent.Subject;
@@ -907,7 +938,11 @@ namespace WebsitePanel.Providers.Mail
public MailAccount GetAccount(string mailboxName)
{
var accountObject = GetAccountObject(mailboxName);
- return CreateMailAccountFromAccountObject(accountObject);
+ var account = CreateMailAccountFromAccountObject(accountObject);
+
+ DisposeObject(accountObject);
+
+ return account;
}
public void CreateAccount(MailAccount mailbox)
@@ -924,10 +959,12 @@ namespace WebsitePanel.Providers.Mail
if (accountObject.New(mailbox.Name))
{
+ accountObject.SetProperty("U_Password", mailbox.Password);
accountObject.Save();
+ UpdateAccount(mailbox);
}
- UpdateAccount(mailbox);
+ DisposeObject(accountObject);
}
public void UpdateAccount(MailAccount mailbox)
@@ -937,10 +974,15 @@ namespace WebsitePanel.Providers.Mail
accountObject.SetProperty("U_Name", mailbox.FullName);
accountObject.SetProperty("U_AccountDisabled", mailbox.IceWarpAccountState);
accountObject.SetProperty("U_DomainAdmin", mailbox.IsDomainAdmin);
- accountObject.SetProperty("U_Password", mailbox.Password);
- accountObject.SetProperty("U_MaxBoxSize", mailbox.MaxMailboxSize*1024);
+
+ if (mailbox.ChangePassword)
+ {
+ accountObject.SetProperty("U_Password", mailbox.Password);
+ }
+
+ accountObject.SetProperty("U_MaxBoxSize", mailbox.MaxMailboxSize * 1024);
accountObject.SetProperty("U_MaxBox", mailbox.MaxMailboxSize > 0 ? "1" : "0");
- accountObject.SetProperty("U_MaxMessageSize", mailbox.MaxMessageSizeMegaByte*1024);
+ accountObject.SetProperty("U_MaxMessageSize", mailbox.MaxMessageSizeMegaByte * 1024);
accountObject.SetProperty("U_MegabyteSendLimit", mailbox.MegaByteSendLimit);
accountObject.SetProperty("U_NumberSendLimit", mailbox.NumberSendLimit);
accountObject.SetProperty("U_AccountType", mailbox.IceWarpAccountType);
@@ -1000,6 +1042,8 @@ namespace WebsitePanel.Providers.Mail
}
SaveAccount(accountObject);
+
+ DisposeObject(accountObject);
}
public void DeleteAccount(string mailboxName)
@@ -1014,6 +1058,8 @@ namespace WebsitePanel.Providers.Mail
{
Log.WriteError("Cannot delete account: " + GetErrorMessage(accountObject.LastErr), null);
}
+
+ DisposeObject(accountObject);
}
#endregion
@@ -1024,7 +1070,11 @@ namespace WebsitePanel.Providers.Mail
{
var accountObject = GetAccountObject();
- return accountObject.Open(mailAliasName);
+ var result = accountObject.Open(mailAliasName);
+
+ DisposeObject(accountObject);
+
+ return result;
}
protected IEnumerable GetAliasListFromAccountObject(dynamic accountObject)
@@ -1056,12 +1106,14 @@ namespace WebsitePanel.Providers.Mail
{
var forwardTo = GetForwardToAddressFromAccountObject(accountObject);
var aliases = GetAliasListFromAccountObject(accountObject) as IEnumerable;
- aliasList.AddRange(aliases.Where(a => a + "@" + domainName != forwardTo).Select(alias => new MailAlias {Name = alias + "@" + domainName, ForwardTo = forwardTo}));
+ aliasList.AddRange(aliases.Where(a => a + "@" + domainName != forwardTo).Select(alias => new MailAlias { Name = alias + "@" + domainName, ForwardTo = forwardTo }));
}
accountObject.FindDone();
}
+ DisposeObject(accountObject);
+
return aliasList.ToArray();
}
@@ -1071,7 +1123,11 @@ namespace WebsitePanel.Providers.Mail
var forwardTo = GetForwardToAddressFromAccountObject(accountObject);
- return new MailAlias {ForwardTo = forwardTo, Name = mailAliasName};
+ var result = new MailAlias { ForwardTo = forwardTo, Name = mailAliasName };
+
+ DisposeObject(accountObject);
+
+ return result;
}
public void CreateMailAlias(MailAlias mailAlias)
@@ -1081,23 +1137,25 @@ namespace WebsitePanel.Providers.Mail
{
mailAlias.ForwardingEnabled = true;
mailAlias.DeleteOnForward = true;
- mailAlias.ForwardingAddresses = new[] {mailAlias.ForwardTo};
+ mailAlias.ForwardingAddresses = new[] { mailAlias.ForwardTo };
mailAlias.Password = GetRandomPassword();
CreateAccount(mailAlias);
}
- // else open account and add alias to list
+ // else open account and add alias to list
else
{
- var accountOject = GetAccountObject(mailAlias.ForwardTo);
- var aliases = ((IEnumerable) GetAliasListFromAccountObject(accountOject)).ToList();
+ var accountObject = GetAccountObject(mailAlias.ForwardTo);
+ var aliases = ((IEnumerable)GetAliasListFromAccountObject(accountObject)).ToList();
aliases.Add(GetEmailUser(mailAlias.Name));
- accountOject.SetProperty("U_EmailAlias", string.Join(";", aliases));
+ accountObject.SetProperty("U_EmailAlias", string.Join(";", aliases));
- SaveAccount(accountOject, "account when creating mail alias");
+ SaveAccount(accountObject, "account when creating mail alias");
+
+ DisposeObject(accountObject);
}
}
- private string GetRandowChars(string chars, int length)
+ private static string GetRandowChars(string chars, int length)
{
var random = new Random();
return new string(Enumerable.Repeat(chars, length).Select(s => s[random.Next(s.Length)]).ToArray());
@@ -1111,8 +1169,8 @@ namespace WebsitePanel.Providers.Mail
var nonAlphaNum = apiObject.GetProperty("C_Accounts_Policies_Pass_NonAlphaNum");
var alpha = apiObject.GetProperty("C_Accounts_Policies_Pass_Alpha");
- return System.Web.Security.Membership.GeneratePassword(minLength, nonAlphaNum) +
- GetRandowChars("0123456789", digits)+
+ return System.Web.Security.Membership.GeneratePassword(minLength, nonAlphaNum) +
+ GetRandowChars("0123456789", digits) +
GetRandowChars("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ", alpha);
}
@@ -1137,11 +1195,13 @@ namespace WebsitePanel.Providers.Mail
accountObject.SetProperty("U_EmailAlias", string.Join(";", otherAliases));
SaveAccount(accountObject, "account during alias delete");
}
- // If no other aliases, this should be an account with a remote address and then we should delete the account
+ // If no other aliases, this should be an account with a remote address and then we should delete the account
else
{
DeleteAccount(mailAliasName);
}
+
+ DisposeObject(accountObject);
}
#endregion
@@ -1152,7 +1212,11 @@ namespace WebsitePanel.Providers.Mail
{
var accountObject = GetAccountObject();
- return accountObject.Open(groupName) && Convert.ToInt32(accountObject.GetProperty("U_Type")) == 7;
+ var result = accountObject.Open(groupName) && (IceWarpAccountType)Enum.Parse(typeof(IceWarpAccountType), ((object)accountObject.GetProperty("U_Type")).ToString()) == IceWarpAccountType.UserGroup;
+
+ DisposeObject(accountObject);
+
+ return result;
}
public MailGroup[] GetGroups(string domainName)
@@ -1165,7 +1229,7 @@ namespace WebsitePanel.Providers.Mail
var mailGroup = new MailGroup
{
Name = accountObject.EmailAddress,
- Enabled = Convert.ToInt32((object) accountObject.GetProperty("U_AccountDisabled")) == 0,
+ Enabled = Convert.ToInt32((object)accountObject.GetProperty("U_AccountDisabled")) == 0,
GroupName = accountObject.GetProperty("G_Name"),
Members = ((IEnumerable)SplitFileContents(accountObject, "G_ListFile_Contents")).ToArray()
};
@@ -1176,7 +1240,11 @@ namespace WebsitePanel.Providers.Mail
public MailGroup GetGroup(string groupName)
{
var accountObject = GetAccountObject(groupName);
- return CreateMailGroupFromAccountObject(accountObject);
+ var result = CreateMailGroupFromAccountObject(accountObject);
+
+ DisposeObject(accountObject);
+
+ return result;
}
public void CreateGroup(MailGroup @group)
@@ -1185,7 +1253,7 @@ namespace WebsitePanel.Providers.Mail
if (accountObject.New(group.Name))
{
- accountObject.SetProperty("U_Type", 7);
+ accountObject.SetProperty("U_Type", IceWarpAccountType.UserGroup);
accountObject.SetProperty("G_GroupwareMailDelivery", false);
SaveAccount(accountObject, "group account");
}
@@ -1195,6 +1263,8 @@ namespace WebsitePanel.Providers.Mail
}
UpdateGroup(group);
+
+ DisposeObject(accountObject);
}
public void UpdateGroup(MailGroup @group)
@@ -1206,6 +1276,8 @@ namespace WebsitePanel.Providers.Mail
accountObject.SetProperty("G_ListFile_Contents", string.Join("\n", group.Members));
SaveAccount(accountObject, "group");
+
+ DisposeObject(accountObject);
}
public void DeleteGroup(string groupName)
@@ -1220,6 +1292,8 @@ namespace WebsitePanel.Providers.Mail
{
Log.WriteError("Cannot delete group: " + GetErrorMessage(accountObject.LastErr), null);
}
+
+ DisposeObject(accountObject);
}
#endregion
@@ -1230,7 +1304,11 @@ namespace WebsitePanel.Providers.Mail
{
var accountObject = GetAccountObject();
- return accountObject.Open(maillistName) && (IceWarpAccountType) Enum.Parse(typeof (IceWarpAccountType), ((object) accountObject.GetProperty("U_Type")).ToString()) == IceWarpAccountType.MailingList;
+ var result = accountObject.Open(maillistName) && (IceWarpAccountType)Enum.Parse(typeof(IceWarpAccountType), ((object)accountObject.GetProperty("U_Type")).ToString()) == IceWarpAccountType.MailingList;
+
+ DisposeObject(accountObject);
+
+ return result;
}
public MailList[] GetLists(string domainName)
@@ -1240,8 +1318,8 @@ namespace WebsitePanel.Providers.Mail
protected IEnumerable SplitStringProperty(dynamic accountObject, string propertyName, char separator)
{
- var value = (object) accountObject.GetProperty(propertyName);
- return value == null ? new String[] {} : value.ToString().Split(new[] {separator}, StringSplitOptions.RemoveEmptyEntries);
+ var value = (object)accountObject.GetProperty(propertyName);
+ return value == null ? new String[] { } : value.ToString().Split(new[] { separator }, StringSplitOptions.RemoveEmptyEntries);
}
protected IEnumerable SplitFileContents(dynamic accountObject, string propertyName)
@@ -1262,43 +1340,43 @@ namespace WebsitePanel.Providers.Mail
Name = accountObject.EmailAddress,
Description = accountObject.GetProperty("M_Name"),
ModeratorAddress = accountObject.GetProperty("M_OwnerAddress"),
- MembersSource = (IceWarpListMembersSource) Enum.Parse(typeof (IceWarpListMembersSource), ((object) accountObject.GetProperty("M_SendAllLists")).ToString()),
- Members = ((IEnumerable)SplitFileContents(accountObject, "M_ListFile_Contents")).Select(m => m.TrimEnd(new[] {';', '0', '1', '2'})).ToArray(),
- SetReceipientsToToHeader = Convert.ToBoolean((object) accountObject.GetProperty("M_SeparateTo")),
+ MembersSource = (IceWarpListMembersSource)Enum.Parse(typeof(IceWarpListMembersSource), ((object)accountObject.GetProperty("M_SendAllLists")).ToString()),
+ Members = ((IEnumerable)SplitFileContents(accountObject, "M_ListFile_Contents")).Select(m => m.TrimEnd(new[] { ';', '0', '1', '2' })).ToArray(),
+ SetReceipientsToToHeader = Convert.ToBoolean((object)accountObject.GetProperty("M_SeparateTo")),
SubjectPrefix = accountObject.GetProperty("M_AddToSubject"),
- Originator = (IceWarpListOriginator) Enum.Parse(typeof (IceWarpListOriginator), ((object) accountObject.GetProperty("M_ListSender")).ToString()),
- PostingMode = Convert.ToBoolean((object) accountObject.GetProperty("M_MembersOnly")) ? PostingMode.MembersCanPost : PostingMode.AnyoneCanPost,
- PasswordProtection = (PasswordProtection) Enum.Parse(typeof (PasswordProtection), ((object) accountObject.GetProperty("M_Moderated")).ToString()),
+ Originator = (IceWarpListOriginator)Enum.Parse(typeof(IceWarpListOriginator), ((object)accountObject.GetProperty("M_ListSender")).ToString()),
+ PostingMode = Convert.ToBoolean((object)accountObject.GetProperty("M_MembersOnly")) ? PostingMode.MembersCanPost : PostingMode.AnyoneCanPost,
+ PasswordProtection = (PasswordProtection)Enum.Parse(typeof(PasswordProtection), ((object)accountObject.GetProperty("M_Moderated")).ToString()),
Password = accountObject.GetProperty("M_ModeratedPassword"),
- DefaultRights = (IceWarpListDefaultRights) Enum.Parse(typeof (IceWarpListDefaultRights), ((object) accountObject.GetProperty("M_DefaultRights")).ToString()),
- MaxMessageSizeEnabled = Convert.ToBoolean((object) accountObject.GetProperty("M_MaxList")),
- MaxMessageSize = Convert.ToInt32((object) accountObject.GetProperty("M_MaxListSize")),
- MaxMembers = Convert.ToInt32((object) accountObject.GetProperty("M_MaxMembers")),
- SendToSender = Convert.ToBoolean((object) accountObject.GetProperty("M_SendToSender")),
- DigestMode = Convert.ToBoolean((object) accountObject.GetProperty("M_DigestConfirmed")),
- MaxMessagesPerMinute = Convert.ToInt32((object) accountObject.GetProperty("M_ListBatch")),
- SendSubscribe = Convert.ToBoolean((object) accountObject.GetProperty("M_NotifyJoin")),
- SendUnsubscribe = Convert.ToBoolean((object) accountObject.GetProperty("M_NotifyLeave")),
+ DefaultRights = (IceWarpListDefaultRights)Enum.Parse(typeof(IceWarpListDefaultRights), ((object)accountObject.GetProperty("M_DefaultRights")).ToString()),
+ MaxMessageSizeEnabled = Convert.ToBoolean((object)accountObject.GetProperty("M_MaxList")),
+ MaxMessageSize = Convert.ToInt32((object)accountObject.GetProperty("M_MaxListSize")),
+ MaxMembers = Convert.ToInt32((object)accountObject.GetProperty("M_MaxMembers")),
+ SendToSender = Convert.ToBoolean((object)accountObject.GetProperty("M_SendToSender")),
+ DigestMode = Convert.ToBoolean((object)accountObject.GetProperty("M_DigestConfirmed")),
+ MaxMessagesPerMinute = Convert.ToInt32((object)accountObject.GetProperty("M_ListBatch")),
+ SendSubscribe = Convert.ToBoolean((object)accountObject.GetProperty("M_NotifyJoin")),
+ SendUnsubscribe = Convert.ToBoolean((object)accountObject.GetProperty("M_NotifyLeave")),
// From list server account
- ConfirmSubscription = (IceWarpListConfirmSubscription) Enum.Parse(typeof (IceWarpListConfirmSubscription), ((object) listServerAccountObject.GetProperty("L_DigestConfirmed")).ToString()),
- CommandsInSubject = Convert.ToBoolean((object) listServerAccountObject.GetProperty("L_ListSubject")),
- DisableSubscribecommand = !Convert.ToBoolean((object) listServerAccountObject.GetProperty("M_JoinR")),
- AllowUnsubscribe = Convert.ToBoolean((object) listServerAccountObject.GetProperty("M_LeaveR")),
- DisableListcommand = !Convert.ToBoolean((object) listServerAccountObject.GetProperty("M_ListsR")),
- DisableWhichCommand = !Convert.ToBoolean((object) listServerAccountObject.GetProperty("M_WhichR")),
- DisableReviewCommand = !Convert.ToBoolean((object) listServerAccountObject.GetProperty("M_ReviewR")),
- DisableVacationCommand = !Convert.ToBoolean((object) listServerAccountObject.GetProperty("M_VacationR")),
- Moderated = Convert.ToBoolean((object) listServerAccountObject.GetProperty("L_Moderated")),
+ ConfirmSubscription = (IceWarpListConfirmSubscription)Enum.Parse(typeof(IceWarpListConfirmSubscription), ((object)listServerAccountObject.GetProperty("L_DigestConfirmed")).ToString()),
+ CommandsInSubject = Convert.ToBoolean((object)listServerAccountObject.GetProperty("L_ListSubject")),
+ DisableSubscribecommand = !Convert.ToBoolean((object)listServerAccountObject.GetProperty("M_JoinR")),
+ AllowUnsubscribe = Convert.ToBoolean((object)listServerAccountObject.GetProperty("M_LeaveR")),
+ DisableListcommand = !Convert.ToBoolean((object)listServerAccountObject.GetProperty("M_ListsR")),
+ DisableWhichCommand = !Convert.ToBoolean((object)listServerAccountObject.GetProperty("M_WhichR")),
+ DisableReviewCommand = !Convert.ToBoolean((object)listServerAccountObject.GetProperty("M_ReviewR")),
+ DisableVacationCommand = !Convert.ToBoolean((object)listServerAccountObject.GetProperty("M_VacationR")),
+ Moderated = Convert.ToBoolean((object)listServerAccountObject.GetProperty("L_Moderated")),
CommandPassword = listServerAccountObject.GetProperty("L_ModeratedPassword"),
- SuppressCommandResponses = Convert.ToBoolean((object) listServerAccountObject.GetProperty("L_MaxList"))
+ SuppressCommandResponses = Convert.ToBoolean((object)listServerAccountObject.GetProperty("L_MaxList"))
};
// This is how I get values for from and replyto header values. TODO: There must be a better way, but I don't see the pattern right now...
- var ss = Convert.ToInt32((object) accountObject.GetProperty("M_SetSender"));
- var sv = Convert.ToInt32((object) accountObject.GetProperty("M_SetValue"));
- var vm = Convert.ToBoolean((object) accountObject.GetProperty("M_ValueMode"));
+ var ss = Convert.ToInt32((object)accountObject.GetProperty("M_SetSender"));
+ var sv = Convert.ToInt32((object)accountObject.GetProperty("M_SetValue"));
+ var vm = Convert.ToBoolean((object)accountObject.GetProperty("M_ValueMode"));
var value = accountObject.GetProperty("M_HeaderValue");
switch (ss)
@@ -1363,13 +1441,19 @@ namespace WebsitePanel.Providers.Mail
break;
}
+ DisposeObject(listServerAccountObject);
+
return mailList;
}
public MailList GetList(string maillistName)
{
var accountObject = GetAccountObject(maillistName);
- return CreateMailListFromAccountObject(accountObject);
+ var result = CreateMailListFromAccountObject(accountObject);
+
+ DisposeObject(accountObject);
+
+ return result;
}
public void CreateList(MailList maillist)
@@ -1395,6 +1479,8 @@ namespace WebsitePanel.Providers.Mail
SaveAccount(accountObject, "mailing list");
UpdateList(maillist);
+
+ DisposeObject(accountObject);
}
protected dynamic FindMatchingListServerAccount(string mailingListName, bool createListServerAccountIfNeeded)
@@ -1555,7 +1641,7 @@ namespace WebsitePanel.Providers.Mail
listServerAccountObject.SetProperty("L_ListSender", maillist.Originator);
listServerAccountObject.SetProperty("L_MaxList", maillist.SuppressCommandResponses);
- SaveAccount(accountObject, "listserver account associated with mailing list");
+ SaveAccount(listServerAccountObject, "listserver account associated with mailing list");
}
public void DeleteList(string maillistName)
@@ -1602,8 +1688,16 @@ namespace WebsitePanel.Providers.Mail
{
Log.WriteError("Cannot delete mail list: " + GetErrorMessage(accountObject.LastErr), null);
}
+
+ DisposeObject(accountObject);
+ DisposeObject(listServerAccountObject);
}
#endregion
+
+ public void Dispose()
+ {
+ Marshal.FinalReleaseComObject(_currentApiObject);
+ }
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/Helpers/MemoryHelper.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/Helpers/MemoryHelper.cs
index 035da473..688a7d42 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/Helpers/MemoryHelper.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/Helpers/MemoryHelper.cs
@@ -52,7 +52,7 @@ namespace WebsitePanel.Providers.Virtualization
cmd.Parameters.Add("DynamicMemoryEnabled", false);
}
- powerShell.Execute(cmd, true);
+ powerShell.Execute(cmd, true, true);
}
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/Helpers/VirtualMachineHelper.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/Helpers/VirtualMachineHelper.cs
index 7cebe04b..f084bfa6 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/Helpers/VirtualMachineHelper.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/Helpers/VirtualMachineHelper.cs
@@ -74,6 +74,7 @@ namespace WebsitePanel.Providers.Virtualization
{
Command cmd = new Command("Stop-VM");
+ cmd.Parameters.Add("Name", vmName);
if (force) cmd.Parameters.Add("Force");
if (!string.IsNullOrEmpty(server)) cmd.Parameters.Add("ComputerName", server);
//if (!string.IsNullOrEmpty(reason)) cmd.Parameters.Add("Reason", reason);
diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/HyperV2012R2.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/HyperV2012R2.cs
index f177136b..e36bf665 100644
--- a/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/HyperV2012R2.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Providers.Virtualization.HyperV-2012R2/HyperV2012R2.cs
@@ -102,7 +102,7 @@ namespace WebsitePanel.Providers.Virtualization
public ReplicaMode ReplicaMode
{
- get { return (ReplicaMode) ProviderSettings.GetInt("ReplicaMode"); }
+ get { return (ReplicaMode) Enum.Parse(typeof(ReplicaMode) , ProviderSettings["ReplicaMode"]); }
}
protected string ReplicaServerPath
{
@@ -239,7 +239,7 @@ namespace WebsitePanel.Providers.Virtualization
Name = current.GetString("Name"),
State = current.GetEnum("State"),
Uptime = Convert.ToInt64(current.GetProperty("UpTime").TotalMilliseconds),
- ReplicationState = result[0].GetEnum("ReplicationState")
+ ReplicationState = current.GetEnum("ReplicationState")
};
vmachines.Add(vm);
}
@@ -780,10 +780,10 @@ namespace WebsitePanel.Providers.Virtualization
Command cmd = new Command("Get-VMSwitch");
// Not needed as the PowerShellManager adds the computer name
- //if (!string.IsNullOrEmpty(computerName)) cmd.Parameters.Add("ComputerName", computerName);
+ if (!string.IsNullOrEmpty(computerName)) cmd.Parameters.Add("ComputerName", computerName);
if (!string.IsNullOrEmpty(type)) cmd.Parameters.Add("SwitchType", type);
- Collection result = PowerShell.Execute(cmd, true, true);
+ Collection result = PowerShell.Execute(cmd, false, true);
foreach (PSObject current in result)
{
@@ -2037,19 +2037,18 @@ namespace WebsitePanel.Providers.Virtualization
var excludes = vm.Disks
.Select(d => d.Path)
- .Where(p => !p.Equals(replication.VhdToReplicate, StringComparison.OrdinalIgnoreCase))
+ .Where(p => replication.VhdToReplicate.All(vp => !p.Equals(vp, StringComparison.OrdinalIgnoreCase)))
.ToArray();
if (excludes.Any())
cmd.Parameters.Add("ExcludedVhdPath", excludes);
// recovery points
+ cmd.Parameters.Add("RecoveryHistory", replication.AdditionalRecoveryPoints);
if (replication.AdditionalRecoveryPoints > 0)
{
if (replication.AdditionalRecoveryPoints > 24)
throw new Exception("AdditionalRecoveryPoints can not be greater than 24");
- cmd.Parameters.Add("RecoveryHistory", replication.AdditionalRecoveryPoints);
-
if (replication.VSSSnapshotFrequencyHour > 0)
{
if (replication.VSSSnapshotFrequencyHour > 12)
@@ -2059,10 +2058,7 @@ namespace WebsitePanel.Providers.Virtualization
}
}
- PowerShell.Execute(cmd, true);
-
- // Initial Replication
- StartInitialReplication(vmId);
+ PowerShell.Execute(cmd, true, true);
}
public void SetVmReplication(string vmId, string replicaServer, VmReplication replication)
@@ -2080,21 +2076,13 @@ namespace WebsitePanel.Providers.Virtualization
cmd.Parameters.Add("CertificateThumbprint", replication.Thumbprint);
cmd.Parameters.Add("ReplicationFrequencySec", (int)replication.ReplicaFrequency);
- var excludes = vm.Disks
- .Select(d => d.Path)
- .Where(p => !p.Equals(replication.VhdToReplicate, StringComparison.OrdinalIgnoreCase))
- .ToArray();
- if (excludes.Any())
- cmd.Parameters.Add("ExcludedVhdPath", excludes);
-
// recovery points
+ cmd.Parameters.Add("RecoveryHistory", replication.AdditionalRecoveryPoints);
if (replication.AdditionalRecoveryPoints > 0)
{
if (replication.AdditionalRecoveryPoints > 24)
throw new Exception("AdditionalRecoveryPoints can not be greater than 24");
- cmd.Parameters.Add("RecoveryHistory", replication.AdditionalRecoveryPoints);
-
if (replication.VSSSnapshotFrequencyHour > 0)
{
if (replication.VSSSnapshotFrequencyHour > 12)
@@ -2102,9 +2090,13 @@ namespace WebsitePanel.Providers.Virtualization
cmd.Parameters.Add("VSSSnapshotFrequencyHour", replication.VSSSnapshotFrequencyHour);
}
+ else
+ {
+ cmd.Parameters.Add("DisableVSSSnapshotReplication");
+ }
}
- PowerShell.Execute(cmd, true);
+ PowerShell.Execute(cmd, true, true);
}
public void TestReplicationServer(string vmId, string replicaServer, string localThumbprint)
@@ -2163,36 +2155,21 @@ namespace WebsitePanel.Providers.Virtualization
excludes.Add(item.Path.ToString());
replica.VhdToReplicate = vm.Disks
.Select(d => d.Path)
- .FirstOrDefault(p => excludes.All(ep => !p.Equals(ep, StringComparison.OrdinalIgnoreCase)));
+ .Where(p => excludes.All(ep => !p.Equals(ep, StringComparison.OrdinalIgnoreCase)))
+ .ToArray();
}
return replica;
}
- public bool DisableVmReplication(string vmId, string replicaServer)
+ public void DisableVmReplication(string vmId)
{
- if (ReplicaMode != ReplicaMode.ReplicationEnabled)
+ if (ReplicaMode == ReplicaMode.None)
throw new Exception("Server does not allow replication by settings");
var vm = GetVirtualMachine(vmId);
ReplicaHelper.RemoveVmReplication(PowerShell, vm.Name, ServerNameSettings);
-
- // move it to EnterpriseServer?
- // If we have access - delete garbage from replica server
- try
- {
- ReplicaHelper.RemoveVmReplication(PowerShell, vm.Name, replicaServer);
- // Delete replica vm
- VirtualMachineHelper.Stop(PowerShell, vm.Name, true, replicaServer);
- VirtualMachineHelper.Delete(PowerShell, vm.Name, replicaServer);
- }
- catch
- {
- return false;
- }
-
- return true;
}
@@ -2212,13 +2189,13 @@ namespace WebsitePanel.Providers.Virtualization
if (result != null && result.Count > 0)
{
replica = new ReplicationDetailInfo();
- replica.AverageLatency = result[0].GetProperty("AverageReplicationLatency");
+ replica.AverageLatency = result[0].GetProperty("AverageReplicationLatency") ?? new TimeSpan();
replica.AverageSize = result[0].GetMb("AverageReplicationSize");
replica.Errors = result[0].GetInt("ReplicationErrors");
replica.FromTime = result[0].GetProperty("MonitoringStartTime");
replica.Health = result[0].GetEnum("ReplicationHealth");
- replica.HealthDetails = result[0].GetString("ReplicationHealthDetails");
- replica.LastSynhronizedAt = result[0].GetProperty("LastReplicationTime");
+ replica.HealthDetails = string.Join(" ", result[0].GetProperty("ReplicationHealthDetails"));
+ replica.LastSynhronizedAt = result[0].GetProperty("LastReplicationTime") ?? new DateTime();
replica.MaximumSize = result[0].GetMb("MaximumReplicationSize");
replica.Mode = result[0].GetEnum("ReplicationMode");
replica.PendingSize = result[0].GetMb("PendingReplicationSize");
@@ -2226,6 +2203,7 @@ namespace WebsitePanel.Providers.Virtualization
replica.ReplicaServerName = result[0].GetString("CurrentReplicaServerName");
replica.State = result[0].GetEnum("ReplicationState");
replica.SuccessfulReplications = result[0].GetInt("SuccessfulReplicationCount");
+ replica.MissedReplicationCount = result[0].GetInt("MissedReplicationCount");
replica.ToTime = result[0].GetProperty("MonitoringEndTime");
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Server.Client/OrganizationProxy.cs b/WebsitePanel/Sources/WebsitePanel.Server.Client/OrganizationProxy.cs
index fa24e922..95bdfa84 100644
--- a/WebsitePanel/Sources/WebsitePanel.Server.Client/OrganizationProxy.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Server.Client/OrganizationProxy.cs
@@ -1,39 +1,7 @@
-// Copyright (c) 2015, Outercurve Foundation.
-// All rights reserved.
-//
-// Redistribution and use in source and binary forms, with or without modification,
-// are permitted provided that the following conditions are met:
-//
-// - Redistributions of source code must retain the above copyright notice, this
-// list of conditions and the following disclaimer.
-//
-// - Redistributions in binary form must reproduce the above copyright notice,
-// this list of conditions and the following disclaimer in the documentation
-// and/or other materials provided with the distribution.
-//
-// - Neither the name of the Outercurve Foundation nor the names of its
-// contributors may be used to endorse or promote products derived from this
-// software without specific prior written permission.
-//
-// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
-// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
-// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
-// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
-// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
-// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
-// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
-// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
-// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-using WebsitePanel.Providers.ResultObjects;
-using WebsitePanel.Providers.OS;
-using WebsitePanel.Providers.Common;
-
//------------------------------------------------------------------------------
//
// This code was generated by a tool.
-// Runtime Version:2.0.50727.5466
+// Runtime Version:2.0.50727.7905
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
@@ -41,329 +9,321 @@ using WebsitePanel.Providers.Common;
//------------------------------------------------------------------------------
//
-// This source code was auto-generated by wsdl, Version=2.0.50727.42.
+// This source code was auto-generated by wsdl, Version=2.0.50727.3038.
//
-namespace WebsitePanel.Providers.HostedSolution
-{
+
+using WebsitePanel.Providers.Common;
+using WebsitePanel.Providers.OS;
+using WebsitePanel.Providers.ResultObjects;
+
+namespace WebsitePanel.Providers.HostedSolution {
using System.Xml.Serialization;
using System.Web.Services;
using System.ComponentModel;
using System.Web.Services.Protocols;
using System;
using System.Diagnostics;
-
-
+
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- [System.Web.Services.WebServiceBindingAttribute(Name = "OrganizationsSoap", Namespace = "http://tempuri.org/")]
+ [System.Web.Services.WebServiceBindingAttribute(Name="OrganizationsSoap", Namespace="http://tempuri.org/")]
[System.Xml.Serialization.XmlIncludeAttribute(typeof(ResultObject))]
[System.Xml.Serialization.XmlIncludeAttribute(typeof(ServiceProviderItem))]
- public partial class Organizations : Microsoft.Web.Services3.WebServicesClientProtocol
- {
-
+ public partial class Organizations : Microsoft.Web.Services3.WebServicesClientProtocol {
+
public ServiceProviderSettingsSoapHeader ServiceProviderSettingsSoapHeaderValue;
-
+
private System.Threading.SendOrPostCallback OrganizationExistsOperationCompleted;
-
+
private System.Threading.SendOrPostCallback CreateOrganizationOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DeleteOrganizationOperationCompleted;
-
+
private System.Threading.SendOrPostCallback CreateUserOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DisableUserOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DeleteUserOperationCompleted;
-
+
private System.Threading.SendOrPostCallback GetUserGeneralSettingsOperationCompleted;
-
+
private System.Threading.SendOrPostCallback CreateSecurityGroupOperationCompleted;
-
+
private System.Threading.SendOrPostCallback GetSecurityGroupGeneralSettingsOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DeleteSecurityGroupOperationCompleted;
-
+
private System.Threading.SendOrPostCallback SetSecurityGroupGeneralSettingsOperationCompleted;
-
+
private System.Threading.SendOrPostCallback AddObjectToSecurityGroupOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DeleteObjectFromSecurityGroupOperationCompleted;
-
+
private System.Threading.SendOrPostCallback SetUserGeneralSettingsOperationCompleted;
-
+
private System.Threading.SendOrPostCallback SetUserPasswordOperationCompleted;
-
+
private System.Threading.SendOrPostCallback SetUserPrincipalNameOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DeleteOrganizationDomainOperationCompleted;
-
+
private System.Threading.SendOrPostCallback CreateOrganizationDomainOperationCompleted;
-
+
private System.Threading.SendOrPostCallback GetPasswordPolicyOperationCompleted;
-
+
private System.Threading.SendOrPostCallback GetSamAccountNameByUserPrincipalNameOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DoesSamAccountNameExistOperationCompleted;
-
+
private System.Threading.SendOrPostCallback GetDriveMapsOperationCompleted;
-
+
private System.Threading.SendOrPostCallback CreateMappedDriveOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DeleteMappedDriveOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DeleteMappedDriveByPathOperationCompleted;
-
+
private System.Threading.SendOrPostCallback DeleteMappedDrivesGPOOperationCompleted;
-
+
private System.Threading.SendOrPostCallback SetDriveMapsTargetingFilterOperationCompleted;
-
+
private System.Threading.SendOrPostCallback ChangeDriveMapFolderPathOperationCompleted;
-
+
+ private System.Threading.SendOrPostCallback GetOrganizationUsersWithExpiredPasswordOperationCompleted;
+
+ private System.Threading.SendOrPostCallback ApplyPasswordSettingsOperationCompleted;
+
+ private System.Threading.SendOrPostCallback CheckPhoneNumberIsInUseOperationCompleted;
+
///
- public Organizations()
- {
- this.Url = "http://localhost:9004/Organizations.asmx";
+ public Organizations() {
+ this.Url = "http://localhost:9003/Organizations.asmx";
}
-
+
///
public event OrganizationExistsCompletedEventHandler OrganizationExistsCompleted;
-
+
///
public event CreateOrganizationCompletedEventHandler CreateOrganizationCompleted;
-
+
///
public event DeleteOrganizationCompletedEventHandler DeleteOrganizationCompleted;
-
+
///
public event CreateUserCompletedEventHandler CreateUserCompleted;
-
+
///
public event DisableUserCompletedEventHandler DisableUserCompleted;
-
+
///
public event DeleteUserCompletedEventHandler DeleteUserCompleted;
-
+
///
public event GetUserGeneralSettingsCompletedEventHandler GetUserGeneralSettingsCompleted;
-
+
///
public event CreateSecurityGroupCompletedEventHandler CreateSecurityGroupCompleted;
-
+
///
public event GetSecurityGroupGeneralSettingsCompletedEventHandler GetSecurityGroupGeneralSettingsCompleted;
-
+
///
public event DeleteSecurityGroupCompletedEventHandler DeleteSecurityGroupCompleted;
-
+
///
public event SetSecurityGroupGeneralSettingsCompletedEventHandler SetSecurityGroupGeneralSettingsCompleted;
-
+
///
public event AddObjectToSecurityGroupCompletedEventHandler AddObjectToSecurityGroupCompleted;
-
+
///
public event DeleteObjectFromSecurityGroupCompletedEventHandler DeleteObjectFromSecurityGroupCompleted;
-
+
///
public event SetUserGeneralSettingsCompletedEventHandler SetUserGeneralSettingsCompleted;
-
+
///
public event SetUserPasswordCompletedEventHandler SetUserPasswordCompleted;
-
+
///
public event SetUserPrincipalNameCompletedEventHandler SetUserPrincipalNameCompleted;
-
+
///
public event DeleteOrganizationDomainCompletedEventHandler DeleteOrganizationDomainCompleted;
-
+
///
public event CreateOrganizationDomainCompletedEventHandler CreateOrganizationDomainCompleted;
-
+
///
public event GetPasswordPolicyCompletedEventHandler GetPasswordPolicyCompleted;
-
+
///
public event GetSamAccountNameByUserPrincipalNameCompletedEventHandler GetSamAccountNameByUserPrincipalNameCompleted;
-
+
///
public event DoesSamAccountNameExistCompletedEventHandler DoesSamAccountNameExistCompleted;
-
+
///
public event GetDriveMapsCompletedEventHandler GetDriveMapsCompleted;
-
+
///
public event CreateMappedDriveCompletedEventHandler CreateMappedDriveCompleted;
-
+
///
public event DeleteMappedDriveCompletedEventHandler DeleteMappedDriveCompleted;
-
+
///
public event DeleteMappedDriveByPathCompletedEventHandler DeleteMappedDriveByPathCompleted;
-
+
///
public event DeleteMappedDrivesGPOCompletedEventHandler DeleteMappedDrivesGPOCompleted;
-
+
///
public event SetDriveMapsTargetingFilterCompletedEventHandler SetDriveMapsTargetingFilterCompleted;
-
+
///
public event ChangeDriveMapFolderPathCompletedEventHandler ChangeDriveMapFolderPathCompleted;
-
+
+ ///
+ public event GetOrganizationUsersWithExpiredPasswordCompletedEventHandler GetOrganizationUsersWithExpiredPasswordCompleted;
+
+ ///
+ public event ApplyPasswordSettingsCompletedEventHandler ApplyPasswordSettingsCompleted;
+
+ ///
+ public event CheckPhoneNumberIsInUseCompletedEventHandler CheckPhoneNumberIsInUseCompleted;
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/OrganizationExists", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public bool OrganizationExists(string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/OrganizationExists", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public bool OrganizationExists(string organizationId) {
object[] results = this.Invoke("OrganizationExists", new object[] {
organizationId});
return ((bool)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginOrganizationExists(string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginOrganizationExists(string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("OrganizationExists", new object[] {
organizationId}, callback, asyncState);
}
-
+
///
- public bool EndOrganizationExists(System.IAsyncResult asyncResult)
- {
+ public bool EndOrganizationExists(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((bool)(results[0]));
}
-
+
///
- public void OrganizationExistsAsync(string organizationId)
- {
+ public void OrganizationExistsAsync(string organizationId) {
this.OrganizationExistsAsync(organizationId, null);
}
-
+
///
- public void OrganizationExistsAsync(string organizationId, object userState)
- {
- if ((this.OrganizationExistsOperationCompleted == null))
- {
+ public void OrganizationExistsAsync(string organizationId, object userState) {
+ if ((this.OrganizationExistsOperationCompleted == null)) {
this.OrganizationExistsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnOrganizationExistsOperationCompleted);
}
this.InvokeAsync("OrganizationExists", new object[] {
organizationId}, this.OrganizationExistsOperationCompleted, userState);
}
-
- private void OnOrganizationExistsOperationCompleted(object arg)
- {
- if ((this.OrganizationExistsCompleted != null))
- {
+
+ private void OnOrganizationExistsOperationCompleted(object arg) {
+ if ((this.OrganizationExistsCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.OrganizationExistsCompleted(this, new OrganizationExistsCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateOrganization", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public Organization CreateOrganization(string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateOrganization", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public Organization CreateOrganization(string organizationId) {
object[] results = this.Invoke("CreateOrganization", new object[] {
organizationId});
return ((Organization)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginCreateOrganization(string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginCreateOrganization(string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("CreateOrganization", new object[] {
organizationId}, callback, asyncState);
}
-
+
///
- public Organization EndCreateOrganization(System.IAsyncResult asyncResult)
- {
+ public Organization EndCreateOrganization(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((Organization)(results[0]));
}
-
+
///
- public void CreateOrganizationAsync(string organizationId)
- {
+ public void CreateOrganizationAsync(string organizationId) {
this.CreateOrganizationAsync(organizationId, null);
}
-
+
///
- public void CreateOrganizationAsync(string organizationId, object userState)
- {
- if ((this.CreateOrganizationOperationCompleted == null))
- {
+ public void CreateOrganizationAsync(string organizationId, object userState) {
+ if ((this.CreateOrganizationOperationCompleted == null)) {
this.CreateOrganizationOperationCompleted = new System.Threading.SendOrPostCallback(this.OnCreateOrganizationOperationCompleted);
}
this.InvokeAsync("CreateOrganization", new object[] {
organizationId}, this.CreateOrganizationOperationCompleted, userState);
}
-
- private void OnCreateOrganizationOperationCompleted(object arg)
- {
- if ((this.CreateOrganizationCompleted != null))
- {
+
+ private void OnCreateOrganizationOperationCompleted(object arg) {
+ if ((this.CreateOrganizationCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.CreateOrganizationCompleted(this, new CreateOrganizationCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteOrganization", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DeleteOrganization(string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteOrganization", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeleteOrganization(string organizationId) {
this.Invoke("DeleteOrganization", new object[] {
organizationId});
}
-
+
///
- public System.IAsyncResult BeginDeleteOrganization(string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDeleteOrganization(string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DeleteOrganization", new object[] {
organizationId}, callback, asyncState);
}
-
+
///
- public void EndDeleteOrganization(System.IAsyncResult asyncResult)
- {
+ public void EndDeleteOrganization(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DeleteOrganizationAsync(string organizationId)
- {
+ public void DeleteOrganizationAsync(string organizationId) {
this.DeleteOrganizationAsync(organizationId, null);
}
-
+
///
- public void DeleteOrganizationAsync(string organizationId, object userState)
- {
- if ((this.DeleteOrganizationOperationCompleted == null))
- {
+ public void DeleteOrganizationAsync(string organizationId, object userState) {
+ if ((this.DeleteOrganizationOperationCompleted == null)) {
this.DeleteOrganizationOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteOrganizationOperationCompleted);
}
this.InvokeAsync("DeleteOrganization", new object[] {
organizationId}, this.DeleteOrganizationOperationCompleted, userState);
}
-
- private void OnDeleteOrganizationOperationCompleted(object arg)
- {
- if ((this.DeleteOrganizationCompleted != null))
- {
+
+ private void OnDeleteOrganizationOperationCompleted(object arg) {
+ if ((this.DeleteOrganizationCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DeleteOrganizationCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateUser", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public int CreateUser(string organizationId, string loginName, string displayName, string upn, string password, bool enabled)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateUser", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public int CreateUser(string organizationId, string loginName, string displayName, string upn, string password, bool enabled) {
object[] results = this.Invoke("CreateUser", new object[] {
organizationId,
loginName,
@@ -373,10 +333,9 @@ namespace WebsitePanel.Providers.HostedSolution
enabled});
return ((int)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginCreateUser(string organizationId, string loginName, string displayName, string upn, string password, bool enabled, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginCreateUser(string organizationId, string loginName, string displayName, string upn, string password, bool enabled, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("CreateUser", new object[] {
organizationId,
loginName,
@@ -385,25 +344,21 @@ namespace WebsitePanel.Providers.HostedSolution
password,
enabled}, callback, asyncState);
}
-
+
///
- public int EndCreateUser(System.IAsyncResult asyncResult)
- {
+ public int EndCreateUser(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((int)(results[0]));
}
-
+
///
- public void CreateUserAsync(string organizationId, string loginName, string displayName, string upn, string password, bool enabled)
- {
+ public void CreateUserAsync(string organizationId, string loginName, string displayName, string upn, string password, bool enabled) {
this.CreateUserAsync(organizationId, loginName, displayName, upn, password, enabled, null);
}
-
+
///
- public void CreateUserAsync(string organizationId, string loginName, string displayName, string upn, string password, bool enabled, object userState)
- {
- if ((this.CreateUserOperationCompleted == null))
- {
+ public void CreateUserAsync(string organizationId, string loginName, string displayName, string upn, string password, bool enabled, object userState) {
+ if ((this.CreateUserOperationCompleted == null)) {
this.CreateUserOperationCompleted = new System.Threading.SendOrPostCallback(this.OnCreateUserOperationCompleted);
}
this.InvokeAsync("CreateUser", new object[] {
@@ -414,367 +369,311 @@ namespace WebsitePanel.Providers.HostedSolution
password,
enabled}, this.CreateUserOperationCompleted, userState);
}
-
- private void OnCreateUserOperationCompleted(object arg)
- {
- if ((this.CreateUserCompleted != null))
- {
+
+ private void OnCreateUserOperationCompleted(object arg) {
+ if ((this.CreateUserCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.CreateUserCompleted(this, new CreateUserCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DisableUser", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DisableUser(string loginName, string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DisableUser", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DisableUser(string loginName, string organizationId) {
this.Invoke("DisableUser", new object[] {
loginName,
organizationId});
}
-
+
///
- public System.IAsyncResult BeginDisableUser(string loginName, string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDisableUser(string loginName, string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DisableUser", new object[] {
loginName,
organizationId}, callback, asyncState);
}
-
+
///
- public void EndDisableUser(System.IAsyncResult asyncResult)
- {
+ public void EndDisableUser(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DisableUserAsync(string loginName, string organizationId)
- {
+ public void DisableUserAsync(string loginName, string organizationId) {
this.DisableUserAsync(loginName, organizationId, null);
}
-
+
///
- public void DisableUserAsync(string loginName, string organizationId, object userState)
- {
- if ((this.DisableUserOperationCompleted == null))
- {
+ public void DisableUserAsync(string loginName, string organizationId, object userState) {
+ if ((this.DisableUserOperationCompleted == null)) {
this.DisableUserOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDisableUserOperationCompleted);
}
this.InvokeAsync("DisableUser", new object[] {
loginName,
organizationId}, this.DisableUserOperationCompleted, userState);
}
-
- private void OnDisableUserOperationCompleted(object arg)
- {
- if ((this.DisableUserCompleted != null))
- {
+
+ private void OnDisableUserOperationCompleted(object arg) {
+ if ((this.DisableUserCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DisableUserCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteUser", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DeleteUser(string loginName, string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteUser", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeleteUser(string loginName, string organizationId) {
this.Invoke("DeleteUser", new object[] {
loginName,
organizationId});
}
-
+
///
- public System.IAsyncResult BeginDeleteUser(string loginName, string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDeleteUser(string loginName, string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DeleteUser", new object[] {
loginName,
organizationId}, callback, asyncState);
}
-
+
///
- public void EndDeleteUser(System.IAsyncResult asyncResult)
- {
+ public void EndDeleteUser(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DeleteUserAsync(string loginName, string organizationId)
- {
+ public void DeleteUserAsync(string loginName, string organizationId) {
this.DeleteUserAsync(loginName, organizationId, null);
}
-
+
///
- public void DeleteUserAsync(string loginName, string organizationId, object userState)
- {
- if ((this.DeleteUserOperationCompleted == null))
- {
+ public void DeleteUserAsync(string loginName, string organizationId, object userState) {
+ if ((this.DeleteUserOperationCompleted == null)) {
this.DeleteUserOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteUserOperationCompleted);
}
this.InvokeAsync("DeleteUser", new object[] {
loginName,
organizationId}, this.DeleteUserOperationCompleted, userState);
}
-
- private void OnDeleteUserOperationCompleted(object arg)
- {
- if ((this.DeleteUserCompleted != null))
- {
+
+ private void OnDeleteUserOperationCompleted(object arg) {
+ if ((this.DeleteUserCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DeleteUserCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetUserGeneralSettings", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public OrganizationUser GetUserGeneralSettings(string loginName, string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetUserGeneralSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public OrganizationUser GetUserGeneralSettings(string loginName, string organizationId) {
object[] results = this.Invoke("GetUserGeneralSettings", new object[] {
loginName,
organizationId});
return ((OrganizationUser)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginGetUserGeneralSettings(string loginName, string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginGetUserGeneralSettings(string loginName, string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("GetUserGeneralSettings", new object[] {
loginName,
organizationId}, callback, asyncState);
}
-
+
///
- public OrganizationUser EndGetUserGeneralSettings(System.IAsyncResult asyncResult)
- {
+ public OrganizationUser EndGetUserGeneralSettings(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((OrganizationUser)(results[0]));
}
-
+
///
- public void GetUserGeneralSettingsAsync(string loginName, string organizationId)
- {
+ public void GetUserGeneralSettingsAsync(string loginName, string organizationId) {
this.GetUserGeneralSettingsAsync(loginName, organizationId, null);
}
-
+
///
- public void GetUserGeneralSettingsAsync(string loginName, string organizationId, object userState)
- {
- if ((this.GetUserGeneralSettingsOperationCompleted == null))
- {
+ public void GetUserGeneralSettingsAsync(string loginName, string organizationId, object userState) {
+ if ((this.GetUserGeneralSettingsOperationCompleted == null)) {
this.GetUserGeneralSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetUserGeneralSettingsOperationCompleted);
}
this.InvokeAsync("GetUserGeneralSettings", new object[] {
loginName,
organizationId}, this.GetUserGeneralSettingsOperationCompleted, userState);
}
-
- private void OnGetUserGeneralSettingsOperationCompleted(object arg)
- {
- if ((this.GetUserGeneralSettingsCompleted != null))
- {
+
+ private void OnGetUserGeneralSettingsOperationCompleted(object arg) {
+ if ((this.GetUserGeneralSettingsCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.GetUserGeneralSettingsCompleted(this, new GetUserGeneralSettingsCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateSecurityGroup", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public int CreateSecurityGroup(string organizationId, string groupName)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateSecurityGroup", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public int CreateSecurityGroup(string organizationId, string groupName) {
object[] results = this.Invoke("CreateSecurityGroup", new object[] {
organizationId,
groupName});
return ((int)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginCreateSecurityGroup(string organizationId, string groupName, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginCreateSecurityGroup(string organizationId, string groupName, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("CreateSecurityGroup", new object[] {
organizationId,
groupName}, callback, asyncState);
}
-
+
///
- public int EndCreateSecurityGroup(System.IAsyncResult asyncResult)
- {
+ public int EndCreateSecurityGroup(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((int)(results[0]));
}
-
+
///
- public void CreateSecurityGroupAsync(string organizationId, string groupName)
- {
+ public void CreateSecurityGroupAsync(string organizationId, string groupName) {
this.CreateSecurityGroupAsync(organizationId, groupName, null);
}
-
+
///
- public void CreateSecurityGroupAsync(string organizationId, string groupName, object userState)
- {
- if ((this.CreateSecurityGroupOperationCompleted == null))
- {
+ public void CreateSecurityGroupAsync(string organizationId, string groupName, object userState) {
+ if ((this.CreateSecurityGroupOperationCompleted == null)) {
this.CreateSecurityGroupOperationCompleted = new System.Threading.SendOrPostCallback(this.OnCreateSecurityGroupOperationCompleted);
}
this.InvokeAsync("CreateSecurityGroup", new object[] {
organizationId,
groupName}, this.CreateSecurityGroupOperationCompleted, userState);
}
-
- private void OnCreateSecurityGroupOperationCompleted(object arg)
- {
- if ((this.CreateSecurityGroupCompleted != null))
- {
+
+ private void OnCreateSecurityGroupOperationCompleted(object arg) {
+ if ((this.CreateSecurityGroupCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.CreateSecurityGroupCompleted(this, new CreateSecurityGroupCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetSecurityGroupGeneralSettings", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public OrganizationSecurityGroup GetSecurityGroupGeneralSettings(string groupName, string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetSecurityGroupGeneralSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public OrganizationSecurityGroup GetSecurityGroupGeneralSettings(string groupName, string organizationId) {
object[] results = this.Invoke("GetSecurityGroupGeneralSettings", new object[] {
groupName,
organizationId});
return ((OrganizationSecurityGroup)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginGetSecurityGroupGeneralSettings(string groupName, string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginGetSecurityGroupGeneralSettings(string groupName, string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("GetSecurityGroupGeneralSettings", new object[] {
groupName,
organizationId}, callback, asyncState);
}
-
+
///
- public OrganizationSecurityGroup EndGetSecurityGroupGeneralSettings(System.IAsyncResult asyncResult)
- {
+ public OrganizationSecurityGroup EndGetSecurityGroupGeneralSettings(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((OrganizationSecurityGroup)(results[0]));
}
-
+
///
- public void GetSecurityGroupGeneralSettingsAsync(string groupName, string organizationId)
- {
+ public void GetSecurityGroupGeneralSettingsAsync(string groupName, string organizationId) {
this.GetSecurityGroupGeneralSettingsAsync(groupName, organizationId, null);
}
-
+
///
- public void GetSecurityGroupGeneralSettingsAsync(string groupName, string organizationId, object userState)
- {
- if ((this.GetSecurityGroupGeneralSettingsOperationCompleted == null))
- {
+ public void GetSecurityGroupGeneralSettingsAsync(string groupName, string organizationId, object userState) {
+ if ((this.GetSecurityGroupGeneralSettingsOperationCompleted == null)) {
this.GetSecurityGroupGeneralSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetSecurityGroupGeneralSettingsOperationCompleted);
}
this.InvokeAsync("GetSecurityGroupGeneralSettings", new object[] {
groupName,
organizationId}, this.GetSecurityGroupGeneralSettingsOperationCompleted, userState);
}
-
- private void OnGetSecurityGroupGeneralSettingsOperationCompleted(object arg)
- {
- if ((this.GetSecurityGroupGeneralSettingsCompleted != null))
- {
+
+ private void OnGetSecurityGroupGeneralSettingsOperationCompleted(object arg) {
+ if ((this.GetSecurityGroupGeneralSettingsCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.GetSecurityGroupGeneralSettingsCompleted(this, new GetSecurityGroupGeneralSettingsCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteSecurityGroup", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DeleteSecurityGroup(string groupName, string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteSecurityGroup", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeleteSecurityGroup(string groupName, string organizationId) {
this.Invoke("DeleteSecurityGroup", new object[] {
groupName,
organizationId});
}
-
+
///
- public System.IAsyncResult BeginDeleteSecurityGroup(string groupName, string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDeleteSecurityGroup(string groupName, string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DeleteSecurityGroup", new object[] {
groupName,
organizationId}, callback, asyncState);
}
-
+
///
- public void EndDeleteSecurityGroup(System.IAsyncResult asyncResult)
- {
+ public void EndDeleteSecurityGroup(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DeleteSecurityGroupAsync(string groupName, string organizationId)
- {
+ public void DeleteSecurityGroupAsync(string groupName, string organizationId) {
this.DeleteSecurityGroupAsync(groupName, organizationId, null);
}
-
+
///
- public void DeleteSecurityGroupAsync(string groupName, string organizationId, object userState)
- {
- if ((this.DeleteSecurityGroupOperationCompleted == null))
- {
+ public void DeleteSecurityGroupAsync(string groupName, string organizationId, object userState) {
+ if ((this.DeleteSecurityGroupOperationCompleted == null)) {
this.DeleteSecurityGroupOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteSecurityGroupOperationCompleted);
}
this.InvokeAsync("DeleteSecurityGroup", new object[] {
groupName,
organizationId}, this.DeleteSecurityGroupOperationCompleted, userState);
}
-
- private void OnDeleteSecurityGroupOperationCompleted(object arg)
- {
- if ((this.DeleteSecurityGroupCompleted != null))
- {
+
+ private void OnDeleteSecurityGroupOperationCompleted(object arg) {
+ if ((this.DeleteSecurityGroupCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DeleteSecurityGroupCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetSecurityGroupGeneralSettings", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void SetSecurityGroupGeneralSettings(string organizationId, string groupName, string[] memberAccounts, string notes)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetSecurityGroupGeneralSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void SetSecurityGroupGeneralSettings(string organizationId, string groupName, string[] memberAccounts, string notes) {
this.Invoke("SetSecurityGroupGeneralSettings", new object[] {
organizationId,
groupName,
memberAccounts,
notes});
}
-
+
///
- public System.IAsyncResult BeginSetSecurityGroupGeneralSettings(string organizationId, string groupName, string[] memberAccounts, string notes, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginSetSecurityGroupGeneralSettings(string organizationId, string groupName, string[] memberAccounts, string notes, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("SetSecurityGroupGeneralSettings", new object[] {
organizationId,
groupName,
memberAccounts,
notes}, callback, asyncState);
}
-
+
///
- public void EndSetSecurityGroupGeneralSettings(System.IAsyncResult asyncResult)
- {
+ public void EndSetSecurityGroupGeneralSettings(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void SetSecurityGroupGeneralSettingsAsync(string organizationId, string groupName, string[] memberAccounts, string notes)
- {
+ public void SetSecurityGroupGeneralSettingsAsync(string organizationId, string groupName, string[] memberAccounts, string notes) {
this.SetSecurityGroupGeneralSettingsAsync(organizationId, groupName, memberAccounts, notes, null);
}
-
+
///
- public void SetSecurityGroupGeneralSettingsAsync(string organizationId, string groupName, string[] memberAccounts, string notes, object userState)
- {
- if ((this.SetSecurityGroupGeneralSettingsOperationCompleted == null))
- {
+ public void SetSecurityGroupGeneralSettingsAsync(string organizationId, string groupName, string[] memberAccounts, string notes, object userState) {
+ if ((this.SetSecurityGroupGeneralSettingsOperationCompleted == null)) {
this.SetSecurityGroupGeneralSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSetSecurityGroupGeneralSettingsOperationCompleted);
}
this.InvokeAsync("SetSecurityGroupGeneralSettings", new object[] {
@@ -783,53 +682,45 @@ namespace WebsitePanel.Providers.HostedSolution
memberAccounts,
notes}, this.SetSecurityGroupGeneralSettingsOperationCompleted, userState);
}
-
- private void OnSetSecurityGroupGeneralSettingsOperationCompleted(object arg)
- {
- if ((this.SetSecurityGroupGeneralSettingsCompleted != null))
- {
+
+ private void OnSetSecurityGroupGeneralSettingsOperationCompleted(object arg) {
+ if ((this.SetSecurityGroupGeneralSettingsCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.SetSecurityGroupGeneralSettingsCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/AddObjectToSecurityGroup", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void AddObjectToSecurityGroup(string organizationId, string accountName, string groupName)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/AddObjectToSecurityGroup", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void AddObjectToSecurityGroup(string organizationId, string accountName, string groupName) {
this.Invoke("AddObjectToSecurityGroup", new object[] {
organizationId,
accountName,
groupName});
}
-
+
///
- public System.IAsyncResult BeginAddObjectToSecurityGroup(string organizationId, string accountName, string groupName, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginAddObjectToSecurityGroup(string organizationId, string accountName, string groupName, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("AddObjectToSecurityGroup", new object[] {
organizationId,
accountName,
groupName}, callback, asyncState);
}
-
+
///
- public void EndAddObjectToSecurityGroup(System.IAsyncResult asyncResult)
- {
+ public void EndAddObjectToSecurityGroup(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void AddObjectToSecurityGroupAsync(string organizationId, string accountName, string groupName)
- {
+ public void AddObjectToSecurityGroupAsync(string organizationId, string accountName, string groupName) {
this.AddObjectToSecurityGroupAsync(organizationId, accountName, groupName, null);
}
-
+
///
- public void AddObjectToSecurityGroupAsync(string organizationId, string accountName, string groupName, object userState)
- {
- if ((this.AddObjectToSecurityGroupOperationCompleted == null))
- {
+ public void AddObjectToSecurityGroupAsync(string organizationId, string accountName, string groupName, object userState) {
+ if ((this.AddObjectToSecurityGroupOperationCompleted == null)) {
this.AddObjectToSecurityGroupOperationCompleted = new System.Threading.SendOrPostCallback(this.OnAddObjectToSecurityGroupOperationCompleted);
}
this.InvokeAsync("AddObjectToSecurityGroup", new object[] {
@@ -837,53 +728,45 @@ namespace WebsitePanel.Providers.HostedSolution
accountName,
groupName}, this.AddObjectToSecurityGroupOperationCompleted, userState);
}
-
- private void OnAddObjectToSecurityGroupOperationCompleted(object arg)
- {
- if ((this.AddObjectToSecurityGroupCompleted != null))
- {
+
+ private void OnAddObjectToSecurityGroupOperationCompleted(object arg) {
+ if ((this.AddObjectToSecurityGroupCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.AddObjectToSecurityGroupCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteObjectFromSecurityGroup", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DeleteObjectFromSecurityGroup(string organizationId, string accountName, string groupName)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteObjectFromSecurityGroup", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeleteObjectFromSecurityGroup(string organizationId, string accountName, string groupName) {
this.Invoke("DeleteObjectFromSecurityGroup", new object[] {
organizationId,
accountName,
groupName});
}
-
+
///
- public System.IAsyncResult BeginDeleteObjectFromSecurityGroup(string organizationId, string accountName, string groupName, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDeleteObjectFromSecurityGroup(string organizationId, string accountName, string groupName, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DeleteObjectFromSecurityGroup", new object[] {
organizationId,
accountName,
groupName}, callback, asyncState);
}
-
+
///
- public void EndDeleteObjectFromSecurityGroup(System.IAsyncResult asyncResult)
- {
+ public void EndDeleteObjectFromSecurityGroup(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DeleteObjectFromSecurityGroupAsync(string organizationId, string accountName, string groupName)
- {
+ public void DeleteObjectFromSecurityGroupAsync(string organizationId, string accountName, string groupName) {
this.DeleteObjectFromSecurityGroupAsync(organizationId, accountName, groupName, null);
}
-
+
///
- public void DeleteObjectFromSecurityGroupAsync(string organizationId, string accountName, string groupName, object userState)
- {
- if ((this.DeleteObjectFromSecurityGroupOperationCompleted == null))
- {
+ public void DeleteObjectFromSecurityGroupAsync(string organizationId, string accountName, string groupName, object userState) {
+ if ((this.DeleteObjectFromSecurityGroupOperationCompleted == null)) {
this.DeleteObjectFromSecurityGroupOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteObjectFromSecurityGroupOperationCompleted);
}
this.InvokeAsync("DeleteObjectFromSecurityGroup", new object[] {
@@ -891,50 +774,47 @@ namespace WebsitePanel.Providers.HostedSolution
accountName,
groupName}, this.DeleteObjectFromSecurityGroupOperationCompleted, userState);
}
-
- private void OnDeleteObjectFromSecurityGroupOperationCompleted(object arg)
- {
- if ((this.DeleteObjectFromSecurityGroupCompleted != null))
- {
+
+ private void OnDeleteObjectFromSecurityGroupOperationCompleted(object arg) {
+ if ((this.DeleteObjectFromSecurityGroupCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DeleteObjectFromSecurityGroupCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetUserGeneralSettings", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetUserGeneralSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
public void SetUserGeneralSettings(
- string organizationId,
- string accountName,
- string displayName,
- string password,
- bool hideFromAddressBook,
- bool disabled,
- bool locked,
- string firstName,
- string initials,
- string lastName,
- string address,
- string city,
- string state,
- string zip,
- string country,
- string jobTitle,
- string company,
- string department,
- string office,
- string managerAccountName,
- string businessPhone,
- string fax,
- string homePhone,
- string mobilePhone,
- string pager,
- string webPage,
- string notes,
- string externalEmail,
- bool userMustChangePassword)
- {
+ string organizationId,
+ string accountName,
+ string displayName,
+ string password,
+ bool hideFromAddressBook,
+ bool disabled,
+ bool locked,
+ string firstName,
+ string initials,
+ string lastName,
+ string address,
+ string city,
+ string state,
+ string zip,
+ string country,
+ string jobTitle,
+ string company,
+ string department,
+ string office,
+ string managerAccountName,
+ string businessPhone,
+ string fax,
+ string homePhone,
+ string mobilePhone,
+ string pager,
+ string webPage,
+ string notes,
+ string externalEmail,
+ bool userMustChangePassword) {
this.Invoke("SetUserGeneralSettings", new object[] {
organizationId,
accountName,
@@ -966,41 +846,40 @@ namespace WebsitePanel.Providers.HostedSolution
externalEmail,
userMustChangePassword});
}
-
+
///
public System.IAsyncResult BeginSetUserGeneralSettings(
- string organizationId,
- string accountName,
- string displayName,
- string password,
- bool hideFromAddressBook,
- bool disabled,
- bool locked,
- string firstName,
- string initials,
- string lastName,
- string address,
- string city,
- string state,
- string zip,
- string country,
- string jobTitle,
- string company,
- string department,
- string office,
- string managerAccountName,
- string businessPhone,
- string fax,
- string homePhone,
- string mobilePhone,
- string pager,
- string webPage,
- string notes,
- string externalEmail,
- bool userMustChangePassword,
- System.AsyncCallback callback,
- object asyncState)
- {
+ string organizationId,
+ string accountName,
+ string displayName,
+ string password,
+ bool hideFromAddressBook,
+ bool disabled,
+ bool locked,
+ string firstName,
+ string initials,
+ string lastName,
+ string address,
+ string city,
+ string state,
+ string zip,
+ string country,
+ string jobTitle,
+ string company,
+ string department,
+ string office,
+ string managerAccountName,
+ string businessPhone,
+ string fax,
+ string homePhone,
+ string mobilePhone,
+ string pager,
+ string webPage,
+ string notes,
+ string externalEmail,
+ bool userMustChangePassword,
+ System.AsyncCallback callback,
+ object asyncState) {
return this.BeginInvoke("SetUserGeneralSettings", new object[] {
organizationId,
accountName,
@@ -1032,83 +911,79 @@ namespace WebsitePanel.Providers.HostedSolution
externalEmail,
userMustChangePassword}, callback, asyncState);
}
-
+
///
- public void EndSetUserGeneralSettings(System.IAsyncResult asyncResult)
- {
+ public void EndSetUserGeneralSettings(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
public void SetUserGeneralSettingsAsync(
- string organizationId,
- string accountName,
- string displayName,
- string password,
- bool hideFromAddressBook,
- bool disabled,
- bool locked,
- string firstName,
- string initials,
- string lastName,
- string address,
- string city,
- string state,
- string zip,
- string country,
- string jobTitle,
- string company,
- string department,
- string office,
- string managerAccountName,
- string businessPhone,
- string fax,
- string homePhone,
- string mobilePhone,
- string pager,
- string webPage,
- string notes,
- string externalEmail,
- bool userMustChangePassword)
- {
+ string organizationId,
+ string accountName,
+ string displayName,
+ string password,
+ bool hideFromAddressBook,
+ bool disabled,
+ bool locked,
+ string firstName,
+ string initials,
+ string lastName,
+ string address,
+ string city,
+ string state,
+ string zip,
+ string country,
+ string jobTitle,
+ string company,
+ string department,
+ string office,
+ string managerAccountName,
+ string businessPhone,
+ string fax,
+ string homePhone,
+ string mobilePhone,
+ string pager,
+ string webPage,
+ string notes,
+ string externalEmail,
+ bool userMustChangePassword) {
this.SetUserGeneralSettingsAsync(organizationId, accountName, displayName, password, hideFromAddressBook, disabled, locked, firstName, initials, lastName, address, city, state, zip, country, jobTitle, company, department, office, managerAccountName, businessPhone, fax, homePhone, mobilePhone, pager, webPage, notes, externalEmail, userMustChangePassword, null);
}
-
+
///
public void SetUserGeneralSettingsAsync(
- string organizationId,
- string accountName,
- string displayName,
- string password,
- bool hideFromAddressBook,
- bool disabled,
- bool locked,
- string firstName,
- string initials,
- string lastName,
- string address,
- string city,
- string state,
- string zip,
- string country,
- string jobTitle,
- string company,
- string department,
- string office,
- string managerAccountName,
- string businessPhone,
- string fax,
- string homePhone,
- string mobilePhone,
- string pager,
- string webPage,
- string notes,
- string externalEmail,
- bool userMustChangePassword,
- object userState)
- {
- if ((this.SetUserGeneralSettingsOperationCompleted == null))
- {
+ string organizationId,
+ string accountName,
+ string displayName,
+ string password,
+ bool hideFromAddressBook,
+ bool disabled,
+ bool locked,
+ string firstName,
+ string initials,
+ string lastName,
+ string address,
+ string city,
+ string state,
+ string zip,
+ string country,
+ string jobTitle,
+ string company,
+ string department,
+ string office,
+ string managerAccountName,
+ string businessPhone,
+ string fax,
+ string homePhone,
+ string mobilePhone,
+ string pager,
+ string webPage,
+ string notes,
+ string externalEmail,
+ bool userMustChangePassword,
+ object userState) {
+ if ((this.SetUserGeneralSettingsOperationCompleted == null)) {
this.SetUserGeneralSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSetUserGeneralSettingsOperationCompleted);
}
this.InvokeAsync("SetUserGeneralSettings", new object[] {
@@ -1142,53 +1017,45 @@ namespace WebsitePanel.Providers.HostedSolution
externalEmail,
userMustChangePassword}, this.SetUserGeneralSettingsOperationCompleted, userState);
}
-
- private void OnSetUserGeneralSettingsOperationCompleted(object arg)
- {
- if ((this.SetUserGeneralSettingsCompleted != null))
- {
+
+ private void OnSetUserGeneralSettingsOperationCompleted(object arg) {
+ if ((this.SetUserGeneralSettingsCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.SetUserGeneralSettingsCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetUserPassword", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void SetUserPassword(string organizationId, string accountName, string password)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetUserPassword", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void SetUserPassword(string organizationId, string accountName, string password) {
this.Invoke("SetUserPassword", new object[] {
organizationId,
accountName,
password});
}
-
+
///
- public System.IAsyncResult BeginSetUserPassword(string organizationId, string accountName, string password, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginSetUserPassword(string organizationId, string accountName, string password, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("SetUserPassword", new object[] {
organizationId,
accountName,
password}, callback, asyncState);
}
-
+
///
- public void EndSetUserPassword(System.IAsyncResult asyncResult)
- {
+ public void EndSetUserPassword(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void SetUserPasswordAsync(string organizationId, string accountName, string password)
- {
+ public void SetUserPasswordAsync(string organizationId, string accountName, string password) {
this.SetUserPasswordAsync(organizationId, accountName, password, null);
}
-
+
///
- public void SetUserPasswordAsync(string organizationId, string accountName, string password, object userState)
- {
- if ((this.SetUserPasswordOperationCompleted == null))
- {
+ public void SetUserPasswordAsync(string organizationId, string accountName, string password, object userState) {
+ if ((this.SetUserPasswordOperationCompleted == null)) {
this.SetUserPasswordOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSetUserPasswordOperationCompleted);
}
this.InvokeAsync("SetUserPassword", new object[] {
@@ -1196,53 +1063,45 @@ namespace WebsitePanel.Providers.HostedSolution
accountName,
password}, this.SetUserPasswordOperationCompleted, userState);
}
-
- private void OnSetUserPasswordOperationCompleted(object arg)
- {
- if ((this.SetUserPasswordCompleted != null))
- {
+
+ private void OnSetUserPasswordOperationCompleted(object arg) {
+ if ((this.SetUserPasswordCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.SetUserPasswordCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetUserPrincipalName", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void SetUserPrincipalName(string organizationId, string accountName, string userPrincipalName)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetUserPrincipalName", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void SetUserPrincipalName(string organizationId, string accountName, string userPrincipalName) {
this.Invoke("SetUserPrincipalName", new object[] {
organizationId,
accountName,
userPrincipalName});
}
-
+
///
- public System.IAsyncResult BeginSetUserPrincipalName(string organizationId, string accountName, string userPrincipalName, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginSetUserPrincipalName(string organizationId, string accountName, string userPrincipalName, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("SetUserPrincipalName", new object[] {
organizationId,
accountName,
userPrincipalName}, callback, asyncState);
}
-
+
///
- public void EndSetUserPrincipalName(System.IAsyncResult asyncResult)
- {
+ public void EndSetUserPrincipalName(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void SetUserPrincipalNameAsync(string organizationId, string accountName, string userPrincipalName)
- {
+ public void SetUserPrincipalNameAsync(string organizationId, string accountName, string userPrincipalName) {
this.SetUserPrincipalNameAsync(organizationId, accountName, userPrincipalName, null);
}
-
+
///
- public void SetUserPrincipalNameAsync(string organizationId, string accountName, string userPrincipalName, object userState)
- {
- if ((this.SetUserPrincipalNameOperationCompleted == null))
- {
+ public void SetUserPrincipalNameAsync(string organizationId, string accountName, string userPrincipalName, object userState) {
+ if ((this.SetUserPrincipalNameOperationCompleted == null)) {
this.SetUserPrincipalNameOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSetUserPrincipalNameOperationCompleted);
}
this.InvokeAsync("SetUserPrincipalName", new object[] {
@@ -1250,323 +1109,272 @@ namespace WebsitePanel.Providers.HostedSolution
accountName,
userPrincipalName}, this.SetUserPrincipalNameOperationCompleted, userState);
}
-
- private void OnSetUserPrincipalNameOperationCompleted(object arg)
- {
- if ((this.SetUserPrincipalNameCompleted != null))
- {
+
+ private void OnSetUserPrincipalNameOperationCompleted(object arg) {
+ if ((this.SetUserPrincipalNameCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.SetUserPrincipalNameCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteOrganizationDomain", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DeleteOrganizationDomain(string organizationDistinguishedName, string domain)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteOrganizationDomain", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeleteOrganizationDomain(string organizationDistinguishedName, string domain) {
this.Invoke("DeleteOrganizationDomain", new object[] {
organizationDistinguishedName,
domain});
}
-
+
///
- public System.IAsyncResult BeginDeleteOrganizationDomain(string organizationDistinguishedName, string domain, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDeleteOrganizationDomain(string organizationDistinguishedName, string domain, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DeleteOrganizationDomain", new object[] {
organizationDistinguishedName,
domain}, callback, asyncState);
}
-
+
///
- public void EndDeleteOrganizationDomain(System.IAsyncResult asyncResult)
- {
+ public void EndDeleteOrganizationDomain(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DeleteOrganizationDomainAsync(string organizationDistinguishedName, string domain)
- {
+ public void DeleteOrganizationDomainAsync(string organizationDistinguishedName, string domain) {
this.DeleteOrganizationDomainAsync(organizationDistinguishedName, domain, null);
}
-
+
///
- public void DeleteOrganizationDomainAsync(string organizationDistinguishedName, string domain, object userState)
- {
- if ((this.DeleteOrganizationDomainOperationCompleted == null))
- {
+ public void DeleteOrganizationDomainAsync(string organizationDistinguishedName, string domain, object userState) {
+ if ((this.DeleteOrganizationDomainOperationCompleted == null)) {
this.DeleteOrganizationDomainOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteOrganizationDomainOperationCompleted);
}
this.InvokeAsync("DeleteOrganizationDomain", new object[] {
organizationDistinguishedName,
domain}, this.DeleteOrganizationDomainOperationCompleted, userState);
}
-
- private void OnDeleteOrganizationDomainOperationCompleted(object arg)
- {
- if ((this.DeleteOrganizationDomainCompleted != null))
- {
+
+ private void OnDeleteOrganizationDomainOperationCompleted(object arg) {
+ if ((this.DeleteOrganizationDomainCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DeleteOrganizationDomainCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateOrganizationDomain", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void CreateOrganizationDomain(string organizationDistinguishedName, string domain)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateOrganizationDomain", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void CreateOrganizationDomain(string organizationDistinguishedName, string domain) {
this.Invoke("CreateOrganizationDomain", new object[] {
organizationDistinguishedName,
domain});
}
-
+
///
- public System.IAsyncResult BeginCreateOrganizationDomain(string organizationDistinguishedName, string domain, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginCreateOrganizationDomain(string organizationDistinguishedName, string domain, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("CreateOrganizationDomain", new object[] {
organizationDistinguishedName,
domain}, callback, asyncState);
}
-
+
///
- public void EndCreateOrganizationDomain(System.IAsyncResult asyncResult)
- {
+ public void EndCreateOrganizationDomain(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void CreateOrganizationDomainAsync(string organizationDistinguishedName, string domain)
- {
+ public void CreateOrganizationDomainAsync(string organizationDistinguishedName, string domain) {
this.CreateOrganizationDomainAsync(organizationDistinguishedName, domain, null);
}
-
+
///
- public void CreateOrganizationDomainAsync(string organizationDistinguishedName, string domain, object userState)
- {
- if ((this.CreateOrganizationDomainOperationCompleted == null))
- {
+ public void CreateOrganizationDomainAsync(string organizationDistinguishedName, string domain, object userState) {
+ if ((this.CreateOrganizationDomainOperationCompleted == null)) {
this.CreateOrganizationDomainOperationCompleted = new System.Threading.SendOrPostCallback(this.OnCreateOrganizationDomainOperationCompleted);
}
this.InvokeAsync("CreateOrganizationDomain", new object[] {
organizationDistinguishedName,
domain}, this.CreateOrganizationDomainOperationCompleted, userState);
}
-
- private void OnCreateOrganizationDomainOperationCompleted(object arg)
- {
- if ((this.CreateOrganizationDomainCompleted != null))
- {
+
+ private void OnCreateOrganizationDomainOperationCompleted(object arg) {
+ if ((this.CreateOrganizationDomainCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.CreateOrganizationDomainCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetPasswordPolicy", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public PasswordPolicyResult GetPasswordPolicy()
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetPasswordPolicy", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public PasswordPolicyResult GetPasswordPolicy() {
object[] results = this.Invoke("GetPasswordPolicy", new object[0]);
return ((PasswordPolicyResult)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginGetPasswordPolicy(System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginGetPasswordPolicy(System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("GetPasswordPolicy", new object[0], callback, asyncState);
}
-
+
///
- public PasswordPolicyResult EndGetPasswordPolicy(System.IAsyncResult asyncResult)
- {
+ public PasswordPolicyResult EndGetPasswordPolicy(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((PasswordPolicyResult)(results[0]));
}
-
+
///
- public void GetPasswordPolicyAsync()
- {
+ public void GetPasswordPolicyAsync() {
this.GetPasswordPolicyAsync(null);
}
-
+
///
- public void GetPasswordPolicyAsync(object userState)
- {
- if ((this.GetPasswordPolicyOperationCompleted == null))
- {
+ public void GetPasswordPolicyAsync(object userState) {
+ if ((this.GetPasswordPolicyOperationCompleted == null)) {
this.GetPasswordPolicyOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetPasswordPolicyOperationCompleted);
}
this.InvokeAsync("GetPasswordPolicy", new object[0], this.GetPasswordPolicyOperationCompleted, userState);
}
-
- private void OnGetPasswordPolicyOperationCompleted(object arg)
- {
- if ((this.GetPasswordPolicyCompleted != null))
- {
+
+ private void OnGetPasswordPolicyOperationCompleted(object arg) {
+ if ((this.GetPasswordPolicyCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.GetPasswordPolicyCompleted(this, new GetPasswordPolicyCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetSamAccountNameByUserPrincipalName", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public string GetSamAccountNameByUserPrincipalName(string organizationId, string userPrincipalName)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetSamAccountNameByUserPrincipalName", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public string GetSamAccountNameByUserPrincipalName(string organizationId, string userPrincipalName) {
object[] results = this.Invoke("GetSamAccountNameByUserPrincipalName", new object[] {
organizationId,
userPrincipalName});
return ((string)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginGetSamAccountNameByUserPrincipalName(string organizationId, string userPrincipalName, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginGetSamAccountNameByUserPrincipalName(string organizationId, string userPrincipalName, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("GetSamAccountNameByUserPrincipalName", new object[] {
organizationId,
userPrincipalName}, callback, asyncState);
}
-
+
///
- public string EndGetSamAccountNameByUserPrincipalName(System.IAsyncResult asyncResult)
- {
+ public string EndGetSamAccountNameByUserPrincipalName(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((string)(results[0]));
}
-
+
///
- public void GetSamAccountNameByUserPrincipalNameAsync(string organizationId, string userPrincipalName)
- {
+ public void GetSamAccountNameByUserPrincipalNameAsync(string organizationId, string userPrincipalName) {
this.GetSamAccountNameByUserPrincipalNameAsync(organizationId, userPrincipalName, null);
}
-
+
///
- public void GetSamAccountNameByUserPrincipalNameAsync(string organizationId, string userPrincipalName, object userState)
- {
- if ((this.GetSamAccountNameByUserPrincipalNameOperationCompleted == null))
- {
+ public void GetSamAccountNameByUserPrincipalNameAsync(string organizationId, string userPrincipalName, object userState) {
+ if ((this.GetSamAccountNameByUserPrincipalNameOperationCompleted == null)) {
this.GetSamAccountNameByUserPrincipalNameOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetSamAccountNameByUserPrincipalNameOperationCompleted);
}
this.InvokeAsync("GetSamAccountNameByUserPrincipalName", new object[] {
organizationId,
userPrincipalName}, this.GetSamAccountNameByUserPrincipalNameOperationCompleted, userState);
}
-
- private void OnGetSamAccountNameByUserPrincipalNameOperationCompleted(object arg)
- {
- if ((this.GetSamAccountNameByUserPrincipalNameCompleted != null))
- {
+
+ private void OnGetSamAccountNameByUserPrincipalNameOperationCompleted(object arg) {
+ if ((this.GetSamAccountNameByUserPrincipalNameCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.GetSamAccountNameByUserPrincipalNameCompleted(this, new GetSamAccountNameByUserPrincipalNameCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DoesSamAccountNameExist", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public bool DoesSamAccountNameExist(string accountName)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DoesSamAccountNameExist", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public bool DoesSamAccountNameExist(string accountName) {
object[] results = this.Invoke("DoesSamAccountNameExist", new object[] {
accountName});
return ((bool)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginDoesSamAccountNameExist(string accountName, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDoesSamAccountNameExist(string accountName, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DoesSamAccountNameExist", new object[] {
accountName}, callback, asyncState);
}
-
+
///
- public bool EndDoesSamAccountNameExist(System.IAsyncResult asyncResult)
- {
+ public bool EndDoesSamAccountNameExist(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((bool)(results[0]));
}
-
+
///
- public void DoesSamAccountNameExistAsync(string accountName)
- {
+ public void DoesSamAccountNameExistAsync(string accountName) {
this.DoesSamAccountNameExistAsync(accountName, null);
}
-
+
///
- public void DoesSamAccountNameExistAsync(string accountName, object userState)
- {
- if ((this.DoesSamAccountNameExistOperationCompleted == null))
- {
+ public void DoesSamAccountNameExistAsync(string accountName, object userState) {
+ if ((this.DoesSamAccountNameExistOperationCompleted == null)) {
this.DoesSamAccountNameExistOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDoesSamAccountNameExistOperationCompleted);
}
this.InvokeAsync("DoesSamAccountNameExist", new object[] {
accountName}, this.DoesSamAccountNameExistOperationCompleted, userState);
}
-
- private void OnDoesSamAccountNameExistOperationCompleted(object arg)
- {
- if ((this.DoesSamAccountNameExistCompleted != null))
- {
+
+ private void OnDoesSamAccountNameExistOperationCompleted(object arg) {
+ if ((this.DoesSamAccountNameExistCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DoesSamAccountNameExistCompleted(this, new DoesSamAccountNameExistCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetDriveMaps", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public MappedDrive[] GetDriveMaps(string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetDriveMaps", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public MappedDrive[] GetDriveMaps(string organizationId) {
object[] results = this.Invoke("GetDriveMaps", new object[] {
organizationId});
return ((MappedDrive[])(results[0]));
}
-
+
///
- public System.IAsyncResult BeginGetDriveMaps(string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginGetDriveMaps(string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("GetDriveMaps", new object[] {
organizationId}, callback, asyncState);
}
-
+
///
- public MappedDrive[] EndGetDriveMaps(System.IAsyncResult asyncResult)
- {
+ public MappedDrive[] EndGetDriveMaps(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((MappedDrive[])(results[0]));
}
-
+
///
- public void GetDriveMapsAsync(string organizationId)
- {
+ public void GetDriveMapsAsync(string organizationId) {
this.GetDriveMapsAsync(organizationId, null);
}
-
+
///
- public void GetDriveMapsAsync(string organizationId, object userState)
- {
- if ((this.GetDriveMapsOperationCompleted == null))
- {
+ public void GetDriveMapsAsync(string organizationId, object userState) {
+ if ((this.GetDriveMapsOperationCompleted == null)) {
this.GetDriveMapsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetDriveMapsOperationCompleted);
}
this.InvokeAsync("GetDriveMaps", new object[] {
organizationId}, this.GetDriveMapsOperationCompleted, userState);
}
-
- private void OnGetDriveMapsOperationCompleted(object arg)
- {
- if ((this.GetDriveMapsCompleted != null))
- {
+
+ private void OnGetDriveMapsOperationCompleted(object arg) {
+ if ((this.GetDriveMapsCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.GetDriveMapsCompleted(this, new GetDriveMapsCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateMappedDrive", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public int CreateMappedDrive(string organizationId, string drive, string labelAs, string path)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CreateMappedDrive", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public int CreateMappedDrive(string organizationId, string drive, string labelAs, string path) {
object[] results = this.Invoke("CreateMappedDrive", new object[] {
organizationId,
drive,
@@ -1574,35 +1382,30 @@ namespace WebsitePanel.Providers.HostedSolution
path});
return ((int)(results[0]));
}
-
+
///
- public System.IAsyncResult BeginCreateMappedDrive(string organizationId, string drive, string labelAs, string path, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginCreateMappedDrive(string organizationId, string drive, string labelAs, string path, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("CreateMappedDrive", new object[] {
organizationId,
drive,
labelAs,
path}, callback, asyncState);
}
-
+
///
- public int EndCreateMappedDrive(System.IAsyncResult asyncResult)
- {
+ public int EndCreateMappedDrive(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((int)(results[0]));
}
-
+
///
- public void CreateMappedDriveAsync(string organizationId, string drive, string labelAs, string path)
- {
+ public void CreateMappedDriveAsync(string organizationId, string drive, string labelAs, string path) {
this.CreateMappedDriveAsync(organizationId, drive, labelAs, path, null);
}
-
+
///
- public void CreateMappedDriveAsync(string organizationId, string drive, string labelAs, string path, object userState)
- {
- if ((this.CreateMappedDriveOperationCompleted == null))
- {
+ public void CreateMappedDriveAsync(string organizationId, string drive, string labelAs, string path, object userState) {
+ if ((this.CreateMappedDriveOperationCompleted == null)) {
this.CreateMappedDriveOperationCompleted = new System.Threading.SendOrPostCallback(this.OnCreateMappedDriveOperationCompleted);
}
this.InvokeAsync("CreateMappedDrive", new object[] {
@@ -1611,203 +1414,171 @@ namespace WebsitePanel.Providers.HostedSolution
labelAs,
path}, this.CreateMappedDriveOperationCompleted, userState);
}
-
- private void OnCreateMappedDriveOperationCompleted(object arg)
- {
- if ((this.CreateMappedDriveCompleted != null))
- {
+
+ private void OnCreateMappedDriveOperationCompleted(object arg) {
+ if ((this.CreateMappedDriveCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.CreateMappedDriveCompleted(this, new CreateMappedDriveCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteMappedDrive", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DeleteMappedDrive(string organizationId, string drive)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteMappedDrive", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeleteMappedDrive(string organizationId, string drive) {
this.Invoke("DeleteMappedDrive", new object[] {
organizationId,
drive});
}
-
+
///
- public System.IAsyncResult BeginDeleteMappedDrive(string organizationId, string drive, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDeleteMappedDrive(string organizationId, string drive, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DeleteMappedDrive", new object[] {
organizationId,
drive}, callback, asyncState);
}
-
+
///
- public void EndDeleteMappedDrive(System.IAsyncResult asyncResult)
- {
+ public void EndDeleteMappedDrive(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DeleteMappedDriveAsync(string organizationId, string drive)
- {
+ public void DeleteMappedDriveAsync(string organizationId, string drive) {
this.DeleteMappedDriveAsync(organizationId, drive, null);
}
-
+
///
- public void DeleteMappedDriveAsync(string organizationId, string drive, object userState)
- {
- if ((this.DeleteMappedDriveOperationCompleted == null))
- {
+ public void DeleteMappedDriveAsync(string organizationId, string drive, object userState) {
+ if ((this.DeleteMappedDriveOperationCompleted == null)) {
this.DeleteMappedDriveOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteMappedDriveOperationCompleted);
}
this.InvokeAsync("DeleteMappedDrive", new object[] {
organizationId,
drive}, this.DeleteMappedDriveOperationCompleted, userState);
}
-
- private void OnDeleteMappedDriveOperationCompleted(object arg)
- {
- if ((this.DeleteMappedDriveCompleted != null))
- {
+
+ private void OnDeleteMappedDriveOperationCompleted(object arg) {
+ if ((this.DeleteMappedDriveCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DeleteMappedDriveCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteMappedDriveByPath", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DeleteMappedDriveByPath(string organizationId, string path)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteMappedDriveByPath", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeleteMappedDriveByPath(string organizationId, string path) {
this.Invoke("DeleteMappedDriveByPath", new object[] {
organizationId,
path});
}
-
+
///
- public System.IAsyncResult BeginDeleteMappedDriveByPath(string organizationId, string path, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDeleteMappedDriveByPath(string organizationId, string path, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DeleteMappedDriveByPath", new object[] {
organizationId,
path}, callback, asyncState);
}
-
+
///
- public void EndDeleteMappedDriveByPath(System.IAsyncResult asyncResult)
- {
+ public void EndDeleteMappedDriveByPath(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DeleteMappedDriveByPathAsync(string organizationId, string path)
- {
+ public void DeleteMappedDriveByPathAsync(string organizationId, string path) {
this.DeleteMappedDriveByPathAsync(organizationId, path, null);
}
-
+
///
- public void DeleteMappedDriveByPathAsync(string organizationId, string path, object userState)
- {
- if ((this.DeleteMappedDriveByPathOperationCompleted == null))
- {
+ public void DeleteMappedDriveByPathAsync(string organizationId, string path, object userState) {
+ if ((this.DeleteMappedDriveByPathOperationCompleted == null)) {
this.DeleteMappedDriveByPathOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteMappedDriveByPathOperationCompleted);
}
this.InvokeAsync("DeleteMappedDriveByPath", new object[] {
organizationId,
path}, this.DeleteMappedDriveByPathOperationCompleted, userState);
}
-
- private void OnDeleteMappedDriveByPathOperationCompleted(object arg)
- {
- if ((this.DeleteMappedDriveByPathCompleted != null))
- {
+
+ private void OnDeleteMappedDriveByPathOperationCompleted(object arg) {
+ if ((this.DeleteMappedDriveByPathCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DeleteMappedDriveByPathCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteMappedDrivesGPO", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void DeleteMappedDrivesGPO(string organizationId)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/DeleteMappedDrivesGPO", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void DeleteMappedDrivesGPO(string organizationId) {
this.Invoke("DeleteMappedDrivesGPO", new object[] {
organizationId});
}
-
+
///
- public System.IAsyncResult BeginDeleteMappedDrivesGPO(string organizationId, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginDeleteMappedDrivesGPO(string organizationId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DeleteMappedDrivesGPO", new object[] {
organizationId}, callback, asyncState);
}
-
+
///
- public void EndDeleteMappedDrivesGPO(System.IAsyncResult asyncResult)
- {
+ public void EndDeleteMappedDrivesGPO(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void DeleteMappedDrivesGPOAsync(string organizationId)
- {
+ public void DeleteMappedDrivesGPOAsync(string organizationId) {
this.DeleteMappedDrivesGPOAsync(organizationId, null);
}
-
+
///
- public void DeleteMappedDrivesGPOAsync(string organizationId, object userState)
- {
- if ((this.DeleteMappedDrivesGPOOperationCompleted == null))
- {
+ public void DeleteMappedDrivesGPOAsync(string organizationId, object userState) {
+ if ((this.DeleteMappedDrivesGPOOperationCompleted == null)) {
this.DeleteMappedDrivesGPOOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteMappedDrivesGPOOperationCompleted);
}
this.InvokeAsync("DeleteMappedDrivesGPO", new object[] {
organizationId}, this.DeleteMappedDrivesGPOOperationCompleted, userState);
}
-
- private void OnDeleteMappedDrivesGPOOperationCompleted(object arg)
- {
- if ((this.DeleteMappedDrivesGPOCompleted != null))
- {
+
+ private void OnDeleteMappedDrivesGPOOperationCompleted(object arg) {
+ if ((this.DeleteMappedDrivesGPOCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.DeleteMappedDrivesGPOCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetDriveMapsTargetingFilter", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void SetDriveMapsTargetingFilter(string organizationId, ExchangeAccount[] accounts, string folderName)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/SetDriveMapsTargetingFilter", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void SetDriveMapsTargetingFilter(string organizationId, ExchangeAccount[] accounts, string folderName) {
this.Invoke("SetDriveMapsTargetingFilter", new object[] {
organizationId,
accounts,
folderName});
}
-
+
///
- public System.IAsyncResult BeginSetDriveMapsTargetingFilter(string organizationId, ExchangeAccount[] accounts, string folderName, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginSetDriveMapsTargetingFilter(string organizationId, ExchangeAccount[] accounts, string folderName, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("SetDriveMapsTargetingFilter", new object[] {
organizationId,
accounts,
folderName}, callback, asyncState);
}
-
+
///
- public void EndSetDriveMapsTargetingFilter(System.IAsyncResult asyncResult)
- {
+ public void EndSetDriveMapsTargetingFilter(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void SetDriveMapsTargetingFilterAsync(string organizationId, ExchangeAccount[] accounts, string folderName)
- {
+ public void SetDriveMapsTargetingFilterAsync(string organizationId, ExchangeAccount[] accounts, string folderName) {
this.SetDriveMapsTargetingFilterAsync(organizationId, accounts, folderName, null);
}
-
+
///
- public void SetDriveMapsTargetingFilterAsync(string organizationId, ExchangeAccount[] accounts, string folderName, object userState)
- {
- if ((this.SetDriveMapsTargetingFilterOperationCompleted == null))
- {
+ public void SetDriveMapsTargetingFilterAsync(string organizationId, ExchangeAccount[] accounts, string folderName, object userState) {
+ if ((this.SetDriveMapsTargetingFilterOperationCompleted == null)) {
this.SetDriveMapsTargetingFilterOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSetDriveMapsTargetingFilterOperationCompleted);
}
this.InvokeAsync("SetDriveMapsTargetingFilter", new object[] {
@@ -1815,53 +1586,45 @@ namespace WebsitePanel.Providers.HostedSolution
accounts,
folderName}, this.SetDriveMapsTargetingFilterOperationCompleted, userState);
}
-
- private void OnSetDriveMapsTargetingFilterOperationCompleted(object arg)
- {
- if ((this.SetDriveMapsTargetingFilterCompleted != null))
- {
+
+ private void OnSetDriveMapsTargetingFilterOperationCompleted(object arg) {
+ if ((this.SetDriveMapsTargetingFilterCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.SetDriveMapsTargetingFilterCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
- [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/ChangeDriveMapFolderPath", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public void ChangeDriveMapFolderPath(string organizationId, string oldFolder, string newFolder)
- {
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/ChangeDriveMapFolderPath", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void ChangeDriveMapFolderPath(string organizationId, string oldFolder, string newFolder) {
this.Invoke("ChangeDriveMapFolderPath", new object[] {
organizationId,
oldFolder,
newFolder});
}
-
+
///
- public System.IAsyncResult BeginChangeDriveMapFolderPath(string organizationId, string oldFolder, string newFolder, System.AsyncCallback callback, object asyncState)
- {
+ public System.IAsyncResult BeginChangeDriveMapFolderPath(string organizationId, string oldFolder, string newFolder, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("ChangeDriveMapFolderPath", new object[] {
organizationId,
oldFolder,
newFolder}, callback, asyncState);
}
-
+
///
- public void EndChangeDriveMapFolderPath(System.IAsyncResult asyncResult)
- {
+ public void EndChangeDriveMapFolderPath(System.IAsyncResult asyncResult) {
this.EndInvoke(asyncResult);
}
-
+
///
- public void ChangeDriveMapFolderPathAsync(string organizationId, string oldFolder, string newFolder)
- {
+ public void ChangeDriveMapFolderPathAsync(string organizationId, string oldFolder, string newFolder) {
this.ChangeDriveMapFolderPathAsync(organizationId, oldFolder, newFolder, null);
}
-
+
///
- public void ChangeDriveMapFolderPathAsync(string organizationId, string oldFolder, string newFolder, object userState)
- {
- if ((this.ChangeDriveMapFolderPathOperationCompleted == null))
- {
+ public void ChangeDriveMapFolderPathAsync(string organizationId, string oldFolder, string newFolder, object userState) {
+ if ((this.ChangeDriveMapFolderPathOperationCompleted == null)) {
this.ChangeDriveMapFolderPathOperationCompleted = new System.Threading.SendOrPostCallback(this.OnChangeDriveMapFolderPathOperationCompleted);
}
this.InvokeAsync("ChangeDriveMapFolderPath", new object[] {
@@ -1869,418 +1632,560 @@ namespace WebsitePanel.Providers.HostedSolution
oldFolder,
newFolder}, this.ChangeDriveMapFolderPathOperationCompleted, userState);
}
-
- private void OnChangeDriveMapFolderPathOperationCompleted(object arg)
- {
- if ((this.ChangeDriveMapFolderPathCompleted != null))
- {
+
+ private void OnChangeDriveMapFolderPathOperationCompleted(object arg) {
+ if ((this.ChangeDriveMapFolderPathCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.ChangeDriveMapFolderPathCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
-
+
///
- public new void CancelAsync(object userState)
- {
+ [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetOrganizationUsersWithExpiredPassword", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public OrganizationUser[] GetOrganizationUsersWithExpiredPassword(string organizationId, int daysBeforeExpiration) {
+ object[] results = this.Invoke("GetOrganizationUsersWithExpiredPassword", new object[] {
+ organizationId,
+ daysBeforeExpiration});
+ return ((OrganizationUser[])(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginGetOrganizationUsersWithExpiredPassword(string organizationId, int daysBeforeExpiration, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("GetOrganizationUsersWithExpiredPassword", new object[] {
+ organizationId,
+ daysBeforeExpiration}, callback, asyncState);
+ }
+
+ ///
+ public OrganizationUser[] EndGetOrganizationUsersWithExpiredPassword(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((OrganizationUser[])(results[0]));
+ }
+
+ ///
+ public void GetOrganizationUsersWithExpiredPasswordAsync(string organizationId, int daysBeforeExpiration) {
+ this.GetOrganizationUsersWithExpiredPasswordAsync(organizationId, daysBeforeExpiration, null);
+ }
+
+ ///
+ public void GetOrganizationUsersWithExpiredPasswordAsync(string organizationId, int daysBeforeExpiration, object userState) {
+ if ((this.GetOrganizationUsersWithExpiredPasswordOperationCompleted == null)) {
+ this.GetOrganizationUsersWithExpiredPasswordOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetOrganizationUsersWithExpiredPasswordOperationCompleted);
+ }
+ this.InvokeAsync("GetOrganizationUsersWithExpiredPassword", new object[] {
+ organizationId,
+ daysBeforeExpiration}, this.GetOrganizationUsersWithExpiredPasswordOperationCompleted, userState);
+ }
+
+ private void OnGetOrganizationUsersWithExpiredPasswordOperationCompleted(object arg) {
+ if ((this.GetOrganizationUsersWithExpiredPasswordCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.GetOrganizationUsersWithExpiredPasswordCompleted(this, new GetOrganizationUsersWithExpiredPasswordCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/ApplyPasswordSettings", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public void ApplyPasswordSettings(string organizationId, OrganizationPasswordSettings passwordSettings) {
+ this.Invoke("ApplyPasswordSettings", new object[] {
+ organizationId,
+ passwordSettings});
+ }
+
+ ///
+ public System.IAsyncResult BeginApplyPasswordSettings(string organizationId, OrganizationPasswordSettings passwordSettings, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("ApplyPasswordSettings", new object[] {
+ organizationId,
+ passwordSettings}, callback, asyncState);
+ }
+
+ ///
+ public void EndApplyPasswordSettings(System.IAsyncResult asyncResult) {
+ this.EndInvoke(asyncResult);
+ }
+
+ ///
+ public void ApplyPasswordSettingsAsync(string organizationId, OrganizationPasswordSettings passwordSettings) {
+ this.ApplyPasswordSettingsAsync(organizationId, passwordSettings, null);
+ }
+
+ ///
+ public void ApplyPasswordSettingsAsync(string organizationId, OrganizationPasswordSettings passwordSettings, object userState) {
+ if ((this.ApplyPasswordSettingsOperationCompleted == null)) {
+ this.ApplyPasswordSettingsOperationCompleted = new System.Threading.SendOrPostCallback(this.OnApplyPasswordSettingsOperationCompleted);
+ }
+ this.InvokeAsync("ApplyPasswordSettings", new object[] {
+ organizationId,
+ passwordSettings}, this.ApplyPasswordSettingsOperationCompleted, userState);
+ }
+
+ private void OnApplyPasswordSettingsOperationCompleted(object arg) {
+ if ((this.ApplyPasswordSettingsCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.ApplyPasswordSettingsCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
+ [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/CheckPhoneNumberIsInUse", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
+ public bool CheckPhoneNumberIsInUse(string phoneNumber, string userSamAccountName) {
+ object[] results = this.Invoke("CheckPhoneNumberIsInUse", new object[] {
+ phoneNumber,
+ userSamAccountName});
+ return ((bool)(results[0]));
+ }
+
+ ///
+ public System.IAsyncResult BeginCheckPhoneNumberIsInUse(string phoneNumber, string userSamAccountName, System.AsyncCallback callback, object asyncState) {
+ return this.BeginInvoke("CheckPhoneNumberIsInUse", new object[] {
+ phoneNumber,
+ userSamAccountName}, callback, asyncState);
+ }
+
+ ///
+ public bool EndCheckPhoneNumberIsInUse(System.IAsyncResult asyncResult) {
+ object[] results = this.EndInvoke(asyncResult);
+ return ((bool)(results[0]));
+ }
+
+ ///
+ public void CheckPhoneNumberIsInUseAsync(string phoneNumber, string userSamAccountName) {
+ this.CheckPhoneNumberIsInUseAsync(phoneNumber, userSamAccountName, null);
+ }
+
+ ///
+ public void CheckPhoneNumberIsInUseAsync(string phoneNumber, string userSamAccountName, object userState) {
+ if ((this.CheckPhoneNumberIsInUseOperationCompleted == null)) {
+ this.CheckPhoneNumberIsInUseOperationCompleted = new System.Threading.SendOrPostCallback(this.OnCheckPhoneNumberIsInUseOperationCompleted);
+ }
+ this.InvokeAsync("CheckPhoneNumberIsInUse", new object[] {
+ phoneNumber,
+ userSamAccountName}, this.CheckPhoneNumberIsInUseOperationCompleted, userState);
+ }
+
+ private void OnCheckPhoneNumberIsInUseOperationCompleted(object arg) {
+ if ((this.CheckPhoneNumberIsInUseCompleted != null)) {
+ System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
+ this.CheckPhoneNumberIsInUseCompleted(this, new CheckPhoneNumberIsInUseCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ }
+ }
+
+ ///
+ public new void CancelAsync(object userState) {
base.CancelAsync(userState);
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void OrganizationExistsCompletedEventHandler(object sender, OrganizationExistsCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class OrganizationExistsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class OrganizationExistsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal OrganizationExistsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal OrganizationExistsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public bool Result
- {
- get
- {
+ public bool Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((bool)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CreateOrganizationCompletedEventHandler(object sender, CreateOrganizationCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class CreateOrganizationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class CreateOrganizationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal CreateOrganizationCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal CreateOrganizationCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public Organization Result
- {
- get
- {
+ public Organization Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((Organization)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteOrganizationCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CreateUserCompletedEventHandler(object sender, CreateUserCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class CreateUserCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class CreateUserCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal CreateUserCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal CreateUserCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public int Result
- {
- get
- {
+ public int Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((int)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DisableUserCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteUserCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetUserGeneralSettingsCompletedEventHandler(object sender, GetUserGeneralSettingsCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class GetUserGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class GetUserGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal GetUserGeneralSettingsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal GetUserGeneralSettingsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public OrganizationUser Result
- {
- get
- {
+ public OrganizationUser Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((OrganizationUser)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CreateSecurityGroupCompletedEventHandler(object sender, CreateSecurityGroupCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class CreateSecurityGroupCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class CreateSecurityGroupCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal CreateSecurityGroupCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal CreateSecurityGroupCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public int Result
- {
- get
- {
+ public int Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((int)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetSecurityGroupGeneralSettingsCompletedEventHandler(object sender, GetSecurityGroupGeneralSettingsCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class GetSecurityGroupGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class GetSecurityGroupGeneralSettingsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal GetSecurityGroupGeneralSettingsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal GetSecurityGroupGeneralSettingsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public OrganizationSecurityGroup Result
- {
- get
- {
+ public OrganizationSecurityGroup Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((OrganizationSecurityGroup)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteSecurityGroupCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetSecurityGroupGeneralSettingsCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void AddObjectToSecurityGroupCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteObjectFromSecurityGroupCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetUserGeneralSettingsCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetUserPasswordCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetUserPrincipalNameCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteOrganizationDomainCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CreateOrganizationDomainCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetPasswordPolicyCompletedEventHandler(object sender, GetPasswordPolicyCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class GetPasswordPolicyCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class GetPasswordPolicyCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal GetPasswordPolicyCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal GetPasswordPolicyCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public PasswordPolicyResult Result
- {
- get
- {
+ public PasswordPolicyResult Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((PasswordPolicyResult)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetSamAccountNameByUserPrincipalNameCompletedEventHandler(object sender, GetSamAccountNameByUserPrincipalNameCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class GetSamAccountNameByUserPrincipalNameCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class GetSamAccountNameByUserPrincipalNameCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal GetSamAccountNameByUserPrincipalNameCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal GetSamAccountNameByUserPrincipalNameCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public string Result
- {
- get
- {
+ public string Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((string)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DoesSamAccountNameExistCompletedEventHandler(object sender, DoesSamAccountNameExistCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class DoesSamAccountNameExistCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class DoesSamAccountNameExistCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal DoesSamAccountNameExistCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal DoesSamAccountNameExistCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public bool Result
- {
- get
- {
+ public bool Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((bool)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void GetDriveMapsCompletedEventHandler(object sender, GetDriveMapsCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class GetDriveMapsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class GetDriveMapsCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal GetDriveMapsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal GetDriveMapsCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public MappedDrive[] Result
- {
- get
- {
+ public MappedDrive[] Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((MappedDrive[])(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void CreateMappedDriveCompletedEventHandler(object sender, CreateMappedDriveCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class CreateMappedDriveCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
- {
-
+ public partial class CreateMappedDriveCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
private object[] results;
-
- internal CreateMappedDriveCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState)
- {
+
+ internal CreateMappedDriveCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
this.results = results;
}
-
+
///
- public int Result
- {
- get
- {
+ public int Result {
+ get {
this.RaiseExceptionIfNecessary();
return ((int)(this.results[0]));
}
}
}
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteMappedDriveCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteMappedDriveByPathCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteMappedDrivesGPOCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SetDriveMapsTargetingFilterCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
-
+
///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void ChangeDriveMapFolderPathCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void GetOrganizationUsersWithExpiredPasswordCompletedEventHandler(object sender, GetOrganizationUsersWithExpiredPasswordCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class GetOrganizationUsersWithExpiredPasswordCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal GetOrganizationUsersWithExpiredPasswordCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public OrganizationUser[] Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((OrganizationUser[])(this.results[0]));
+ }
+ }
+ }
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void ApplyPasswordSettingsCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ public delegate void CheckPhoneNumberIsInUseCompletedEventHandler(object sender, CheckPhoneNumberIsInUseCompletedEventArgs e);
+
+ ///
+ [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
+ [System.Diagnostics.DebuggerStepThroughAttribute()]
+ [System.ComponentModel.DesignerCategoryAttribute("code")]
+ public partial class CheckPhoneNumberIsInUseCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
+
+ private object[] results;
+
+ internal CheckPhoneNumberIsInUseCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
+ base(exception, cancelled, userState) {
+ this.results = results;
+ }
+
+ ///
+ public bool Result {
+ get {
+ this.RaiseExceptionIfNecessary();
+ return ((bool)(this.results[0]));
+ }
+ }
+ }
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Server.Client/VirtualizationServerProxy2012.cs b/WebsitePanel/Sources/WebsitePanel.Server.Client/VirtualizationServerProxy2012.cs
index d9f917c9..dfe2ea37 100644
--- a/WebsitePanel/Sources/WebsitePanel.Server.Client/VirtualizationServerProxy2012.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Server.Client/VirtualizationServerProxy2012.cs
@@ -2749,45 +2749,40 @@ namespace WebsitePanel.Providers.Virtualization2012 {
///
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/DisableVmReplication", RequestNamespace="http://smbsaas/websitepanel/server/", ResponseNamespace="http://smbsaas/websitepanel/server/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
- public bool DisableVmReplication(string vmId, string replicaServer) {
- object[] results = this.Invoke("DisableVmReplication", new object[] {
- vmId,
- replicaServer});
- return ((bool)(results[0]));
+ public void DisableVmReplication(string vmId) {
+ this.Invoke("DisableVmReplication", new object[] {
+ vmId});
}
///
- public System.IAsyncResult BeginDisableVmReplication(string vmId, string replicaServer, System.AsyncCallback callback, object asyncState) {
+ public System.IAsyncResult BeginDisableVmReplication(string vmId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("DisableVmReplication", new object[] {
- vmId,
- replicaServer}, callback, asyncState);
+ vmId}, callback, asyncState);
}
///
- public bool EndDisableVmReplication(System.IAsyncResult asyncResult) {
- object[] results = this.EndInvoke(asyncResult);
- return ((bool)(results[0]));
+ public void EndDisableVmReplication(System.IAsyncResult asyncResult) {
+ this.EndInvoke(asyncResult);
}
///
- public void DisableVmReplicationAsync(string vmId, string replicaServer) {
- this.DisableVmReplicationAsync(vmId, replicaServer, null);
+ public void DisableVmReplicationAsync(string vmId) {
+ this.DisableVmReplicationAsync(vmId, null);
}
///
- public void DisableVmReplicationAsync(string vmId, string replicaServer, object userState) {
+ public void DisableVmReplicationAsync(string vmId, object userState) {
if ((this.DisableVmReplicationOperationCompleted == null)) {
this.DisableVmReplicationOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDisableVmReplicationOperationCompleted);
}
this.InvokeAsync("DisableVmReplication", new object[] {
- vmId,
- replicaServer}, this.DisableVmReplicationOperationCompleted, userState);
+ vmId}, this.DisableVmReplicationOperationCompleted, userState);
}
private void OnDisableVmReplicationOperationCompleted(object arg) {
if ((this.DisableVmReplicationCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
- this.DisableVmReplicationCompleted(this, new DisableVmReplicationCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
+ this.DisableVmReplicationCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
@@ -4179,29 +4174,7 @@ namespace WebsitePanel.Providers.Virtualization2012 {
///
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
- public delegate void DisableVmReplicationCompletedEventHandler(object sender, DisableVmReplicationCompletedEventArgs e);
-
- ///
- [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
- [System.Diagnostics.DebuggerStepThroughAttribute()]
- [System.ComponentModel.DesignerCategoryAttribute("code")]
- public partial class DisableVmReplicationCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
-
- private object[] results;
-
- internal DisableVmReplicationCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
- base(exception, cancelled, userState) {
- this.results = results;
- }
-
- ///
- public bool Result {
- get {
- this.RaiseExceptionIfNecessary();
- return ((bool)(this.results[0]));
- }
- }
- }
+ public delegate void DisableVmReplicationCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
///
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
diff --git a/WebsitePanel/Sources/WebsitePanel.Server/Organizations.asmx.cs b/WebsitePanel/Sources/WebsitePanel.Server/Organizations.asmx.cs
index 2b2abc5f..66be5114 100644
--- a/WebsitePanel/Sources/WebsitePanel.Server/Organizations.asmx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Server/Organizations.asmx.cs
@@ -27,6 +27,7 @@
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
using System;
+using System.Collections.Generic;
using System.ComponentModel;
using System.Web.Services;
using System.Web.Services.Protocols;
@@ -254,5 +255,23 @@ namespace WebsitePanel.Server
{
Organization.ChangeDriveMapFolderPath(organizationId, oldFolder, newFolder);
}
+
+ [WebMethod, SoapHeader("settings")]
+ public List GetOrganizationUsersWithExpiredPassword(string organizationId, int daysBeforeExpiration)
+ {
+ return Organization.GetOrganizationUsersWithExpiredPassword(organizationId, daysBeforeExpiration);
+ }
+
+ [WebMethod, SoapHeader("settings")]
+ public void ApplyPasswordSettings(string organizationId, OrganizationPasswordSettings passwordSettings)
+ {
+ Organization.ApplyPasswordSettings(organizationId, passwordSettings);
+ }
+
+ [WebMethod, SoapHeader("settings")]
+ public bool CheckPhoneNumberIsInUse(string phoneNumber, string userSamAccountName = null)
+ {
+ return Organization.CheckPhoneNumberIsInUse(phoneNumber, userSamAccountName);
+ }
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.Server/VirtualizationServer2012.asmx.cs b/WebsitePanel/Sources/WebsitePanel.Server/VirtualizationServer2012.asmx.cs
index c2276774..fcc0f0f6 100644
--- a/WebsitePanel/Sources/WebsitePanel.Server/VirtualizationServer2012.asmx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.Server/VirtualizationServer2012.asmx.cs
@@ -1023,14 +1023,13 @@ namespace WebsitePanel.Server
}
[WebMethod, SoapHeader("settings")]
- public bool DisableVmReplication(string vmId, string replicaServer)
+ public void DisableVmReplication(string vmId)
{
try
{
Log.WriteStart("'{0}' DisableVmReplication", ProviderSettings.ProviderName);
- var result = VirtualizationProvider.DisableVmReplication(vmId, replicaServer);
+ VirtualizationProvider.DisableVmReplication(vmId);
Log.WriteEnd("'{0}' DisableVmReplication", ProviderSettings.ProviderName);
- return result;
}
catch (Exception ex)
{
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/Entities/SessionKeysCollection.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/Entities/SessionKeysCollection.cs
index 1a45b059..1cbfa2e9 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/Entities/SessionKeysCollection.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/Entities/SessionKeysCollection.cs
@@ -65,6 +65,16 @@ namespace WebsitePanel.WebDav.Core.Config.Entities
}
}
+ public string PasswordResetSmsKey
+ {
+ get
+ {
+ SessionKeysElement sessionKey =
+ _sessionKeys.FirstOrDefault(x => x.Key == SessionKeysElement.PassswordResetSmsKey);
+ return sessionKey != null ? sessionKey.Value : null;
+ }
+ }
+
public string ResourseRenderCount
{
get
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/Entities/TwilioParameters.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/Entities/TwilioParameters.cs
new file mode 100644
index 00000000..9ce1ffbe
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/Entities/TwilioParameters.cs
@@ -0,0 +1,16 @@
+namespace WebsitePanel.WebDav.Core.Config.Entities
+{
+ public class TwilioParameters: AbstractConfigCollection
+ {
+ public string AccountSid { get; private set; }
+ public string AuthorizationToken { get; private set; }
+ public string PhoneFrom { get; private set; }
+
+ public TwilioParameters()
+ {
+ AccountSid = ConfigSection.Twilio.AccountSid;
+ AuthorizationToken = ConfigSection.Twilio.AuthorizationToken;
+ PhoneFrom = ConfigSection.Twilio.PhoneFrom;
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/IWebDavAppConfig.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/IWebDavAppConfig.cs
index 86ce78de..0c72e9c5 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/IWebDavAppConfig.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/IWebDavAppConfig.cs
@@ -8,6 +8,7 @@ namespace WebsitePanel.WebDav.Core.Config
string ApplicationName { get; }
ElementsRendering ElementsRendering { get; }
WebsitePanelConstantUserParameters WebsitePanelConstantUserParameters { get; }
+ TwilioParameters TwilioParameters { get; }
SessionKeysCollection SessionKeys { get; }
FileIconsDictionary FileIcons { get; }
HttpErrorsCollection HttpErrors { get; }
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/SessionKeysElement.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/SessionKeysElement.cs
index 76a0e7e8..efeea291 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/SessionKeysElement.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/SessionKeysElement.cs
@@ -12,6 +12,7 @@ namespace WebsitePanel.WebDav.Core.Config.WebConfigSections
public const string WebDavManagerKey = "WebDavManagerSessionKey";
public const string UserGroupsKey = "UserGroupsKey";
public const string WebDavRootFolderPermissionsKey = "WebDavRootFolderPermissionsKey";
+ public const string PassswordResetSmsKey = "PassswordResetSmsKey";
public const string ResourseRenderCountKey = "ResourseRenderCountSessionKey";
public const string ItemIdSessionKey = "ItemId";
public const string OwaEditFoldersSessionKey = "OwaEditFoldersSession";
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/TwilioElement.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/TwilioElement.cs
new file mode 100644
index 00000000..c53856b6
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/TwilioElement.cs
@@ -0,0 +1,32 @@
+using System.Configuration;
+
+namespace WebsitePanel.WebDav.Core.Config.WebConfigSections
+{
+ public class TwilioElement : ConfigurationElement
+ {
+ private const string AccountSidPropName = "accountSid";
+ private const string AuthorizationTokenPropName = "authorizationToken";
+ private const string PhoneFromPropName = "phoneFrom";
+
+ [ConfigurationProperty(AccountSidPropName, IsKey = true, IsRequired = true)]
+ public string AccountSid
+ {
+ get { return this[AccountSidPropName].ToString(); }
+ set { this[AccountSidPropName] = value; }
+ }
+
+ [ConfigurationProperty(AuthorizationTokenPropName, IsKey = true, IsRequired = true)]
+ public string AuthorizationToken
+ {
+ get { return this[AuthorizationTokenPropName].ToString(); }
+ set { this[AuthorizationTokenPropName] = value; }
+ }
+
+ [ConfigurationProperty(PhoneFromPropName, IsKey = true, IsRequired = true)]
+ public string PhoneFrom
+ {
+ get { return this[PhoneFromPropName].ToString(); }
+ set { this[PhoneFromPropName] = value; }
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/WebDavExplorerConfigurationSettingsSection.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/WebDavExplorerConfigurationSettingsSection.cs
index d471a912..8edbb92f 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/WebDavExplorerConfigurationSettingsSection.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebConfigSections/WebDavExplorerConfigurationSettingsSection.cs
@@ -20,6 +20,7 @@ namespace WebsitePanel.WebDavPortal.WebConfigSections
private const string OfficeOnlineKey = "officeOnline";
private const string FilesToIgnoreKey = "filesToIgnore";
private const string TypeOpenerKey = "typeOpener";
+ private const string TwilioKey = "twilio";
public const string SectionName = "webDavExplorerConfigurationSettings";
@@ -65,6 +66,13 @@ namespace WebsitePanel.WebDavPortal.WebConfigSections
set { this[WebsitePanelConstantUserKey] = value; }
}
+ [ConfigurationProperty(TwilioKey, IsRequired = true)]
+ public TwilioElement Twilio
+ {
+ get { return (TwilioElement)this[TwilioKey]; }
+ set { this[TwilioKey] = value; }
+ }
+
[ConfigurationProperty(ElementsRenderingKey, IsRequired = true)]
public ElementsRenderingElement ElementsRendering
{
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebDavAppConfigManager.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebDavAppConfigManager.cs
index 696c1d54..03de83f7 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebDavAppConfigManager.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Config/WebDavAppConfigManager.cs
@@ -21,6 +21,7 @@ namespace WebsitePanel.WebDav.Core.Config
OwaSupportedBrowsers = new OwaSupportedBrowsersCollection();
FilesToIgnore = new FilesToIgnoreCollection();
FileOpener = new OpenerCollection();
+ TwilioParameters = new TwilioParameters();
}
public static WebDavAppConfigManager Instance
@@ -55,6 +56,7 @@ namespace WebsitePanel.WebDav.Core.Config
public ElementsRendering ElementsRendering { get; private set; }
public WebsitePanelConstantUserParameters WebsitePanelConstantUserParameters { get; private set; }
+ public TwilioParameters TwilioParameters { get; private set; }
public SessionKeysCollection SessionKeys { get; private set; }
public FileIconsDictionary FileIcons { get; private set; }
public HttpErrorsCollection HttpErrors { get; private set; }
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Security/IAuthenticationService.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Security/IAuthenticationService.cs
index 0cddd68c..2c526578 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Security/IAuthenticationService.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Security/IAuthenticationService.cs
@@ -14,5 +14,6 @@ namespace WebsitePanel.WebDav.Core.Interfaces.Security
WspPrincipal LogIn(string login, string password);
void CreateAuthenticationTicket(WspPrincipal principal);
void LogOut();
+ bool ValidateAuthenticationData(string login, string password);
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Security/ISmsAuthenticationService.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Security/ISmsAuthenticationService.cs
new file mode 100644
index 00000000..8eb0b563
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Security/ISmsAuthenticationService.cs
@@ -0,0 +1,11 @@
+using System;
+
+namespace WebsitePanel.WebDav.Core.Interfaces.Security
+{
+ public interface ISmsAuthenticationService
+ {
+ bool VerifyResponse(Guid token, string response);
+ string SendRequestMessage(string phoneTo);
+ string GenerateResponse();
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Services/ISmsDistributionService.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Services/ISmsDistributionService.cs
new file mode 100644
index 00000000..b83910f7
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Interfaces/Services/ISmsDistributionService.cs
@@ -0,0 +1,9 @@
+namespace WebsitePanel.WebDav.Core.Interfaces.Services
+{
+ public interface ISmsDistributionService
+ {
+ bool SendMessage(string phoneFrom, string phone, string message);
+
+ bool SendMessage(string phone, string message);
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Managers/WebDavManager.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Managers/WebDavManager.cs
index ceb0beb8..893f11ec 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Managers/WebDavManager.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Managers/WebDavManager.cs
@@ -47,7 +47,7 @@ namespace WebsitePanel.WebDav.Core.Managers
if (string.IsNullOrWhiteSpace(pathPart))
{
- children = GetWebDavRootItems().Select(x => new WebDavResource
+ children = ConnectToWebDavServer().Select(x => new WebDavResource
{
Href = new Uri(x.Url),
ItemType = ItemType.Folder,
@@ -82,9 +82,10 @@ namespace WebsitePanel.WebDav.Core.Managers
SystemFile[] items;
+
if (string.IsNullOrWhiteSpace(pathPart))
{
- var rootItems = GetWebDavRootItems().Select(x => x.Name).ToList();
+ var rootItems = ConnectToWebDavServer().Select(x => x.Name).ToList();
rootItems.Insert(0, string.Empty);
items = WspContext.Services.EnterpriseStorage.SearchFiles(itemId, rootItems.ToArray(), searchValue, uesrPrincipalName, recursive);
@@ -284,11 +285,25 @@ namespace WebsitePanel.WebDav.Core.Managers
}
}
- private IList GetWebDavRootItems()
+ private IList ConnectToWebDavServer()
{
+ var rootFolders = new List();
var user = WspContext.User;
- var rootFolders = WspContext.Services.EnterpriseStorage.GetUserRootFolders(user.ItemId, user.AccountId,user.UserName, user.DisplayName);
+ var userGroups = WSP.Services.Organizations.GetSecurityGroupsByMember(user.ItemId, user.AccountId);
+
+ foreach (var folder in WSP.Services.EnterpriseStorage.GetEnterpriseFolders(WspContext.User.ItemId))
+ {
+ foreach (var rule in folder.Rules)
+ {
+ if ((rule.Users.Any(x=> string.Compare(x, user.AccountName, StringComparison.InvariantCultureIgnoreCase) == 0))
+ || (userGroups.Any(x => rule.Roles.Any(r => string.Compare(r, x.AccountName, StringComparison.InvariantCultureIgnoreCase) == 0))))
+ {
+ rootFolders.Add(folder);
+ break;
+ }
+ }
+ }
return rootFolders;
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/FormsAuthenticationService.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/FormsAuthenticationService.cs
index f802b9b8..921eb47f 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/FormsAuthenticationService.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/FormsAuthenticationService.cs
@@ -26,14 +26,7 @@ namespace WebsitePanel.WebDav.Core.Security.Authentication
public WspPrincipal LogIn(string login, string password)
{
- if (string.IsNullOrEmpty(login) || string.IsNullOrEmpty(password))
- {
- return null;
- }
-
- var user = UserPrincipal.FindByIdentity(_principalContext, IdentityType.UserPrincipalName, login);
-
- if (user == null || _principalContext.ValidateCredentials(login, password) == false)
+ if (ValidateAuthenticationData(login, password) == false)
{
return null;
}
@@ -47,6 +40,7 @@ namespace WebsitePanel.WebDav.Core.Security.Authentication
principal.ItemId = exchangeAccount.ItemId;
principal.OrganizationId = organization.OrganizationId;
principal.DisplayName = exchangeAccount.DisplayName;
+ principal.AccountName = exchangeAccount.AccountName;
principal.EncryptedPassword = _cryptography.Encrypt(password);
if (HttpContext.Current != null)
@@ -83,5 +77,22 @@ namespace WebsitePanel.WebDav.Core.Security.Authentication
{
FormsAuthentication.SignOut();
}
+
+ public bool ValidateAuthenticationData(string login, string password)
+ {
+ if (string.IsNullOrEmpty(login) || string.IsNullOrEmpty(password))
+ {
+ return false;
+ }
+
+ var user = UserPrincipal.FindByIdentity(_principalContext, IdentityType.UserPrincipalName, login);
+
+ if (user == null || _principalContext.ValidateCredentials(login, password) == false)
+ {
+ return false;
+ }
+
+ return true;
+ }
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/Principals/WspPrincipal.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/Principals/WspPrincipal.cs
index e70bb304..fa8f5d6f 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/Principals/WspPrincipal.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/Principals/WspPrincipal.cs
@@ -14,6 +14,7 @@ namespace WebsitePanel.WebDav.Core.Security.Authentication.Principals
public string Login { get; set; }
public string DisplayName { get; set; }
+ public string AccountName { get; set; }
public string UserName
{
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/SmsAuthenticationService.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/SmsAuthenticationService.cs
new file mode 100644
index 00000000..10cba6a1
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Security/Authentication/SmsAuthenticationService.cs
@@ -0,0 +1,46 @@
+using System;
+using System.Globalization;
+using WebsitePanel.WebDav.Core.Config;
+using WebsitePanel.WebDav.Core.Interfaces.Security;
+using WebsitePanel.WebDav.Core.Interfaces.Services;
+
+namespace WebsitePanel.WebDav.Core.Security.Authentication
+{
+ public class SmsAuthenticationService : ISmsAuthenticationService
+ {
+ private ISmsDistributionService _smsService;
+
+ public SmsAuthenticationService(ISmsDistributionService smsService)
+ {
+ _smsService = smsService;
+ }
+
+ public bool VerifyResponse( Guid token, string response)
+ {
+ var accessToken = WspContext.Services.Organizations.GetPasswordresetAccessToken(token);
+
+ if (accessToken == null)
+ {
+ return false;
+ }
+
+ return string.Compare(accessToken.SmsResponse, response, StringComparison.InvariantCultureIgnoreCase) == 0;
+ }
+
+ public string SendRequestMessage(string phoneTo)
+ {
+ var response = GenerateResponse();
+
+ var result = _smsService.SendMessage(WebDavAppConfigManager.Instance.TwilioParameters.PhoneFrom, phoneTo, response);
+
+ return result ? response : string.Empty;
+ }
+
+ public string GenerateResponse()
+ {
+ var random = new Random(Guid.NewGuid().GetHashCode());
+
+ return random.Next(10000, 99999).ToString(CultureInfo.InvariantCulture);
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Services/TwillioSmsDistributionService.cs b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Services/TwillioSmsDistributionService.cs
new file mode 100644
index 00000000..8e0d7ad7
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/Services/TwillioSmsDistributionService.cs
@@ -0,0 +1,31 @@
+using Twilio;
+using WebsitePanel.WebDav.Core.Config;
+using WebsitePanel.WebDav.Core.Interfaces.Services;
+
+namespace WebsitePanel.WebDav.Core.Services
+{
+ public class TwillioSmsDistributionService : ISmsDistributionService
+ {
+ private readonly TwilioRestClient _twilioRestClient;
+
+ public TwillioSmsDistributionService()
+ {
+ _twilioRestClient = new TwilioRestClient(WebDavAppConfigManager.Instance.TwilioParameters.AccountSid, WebDavAppConfigManager.Instance.TwilioParameters.AuthorizationToken);
+ }
+
+
+ public bool SendMessage(string phoneFrom, string phone, string message)
+ {
+ var result = _twilioRestClient.SendSmsMessage(phoneFrom, phone, message);
+
+ return string.IsNullOrEmpty(result.Status) == false;
+ }
+
+ public bool SendMessage(string phone, string message)
+ {
+ var result = _twilioRestClient.SendSmsMessage(WebDavAppConfigManager.Instance.TwilioParameters.PhoneFrom, phone, message);
+
+ return string.IsNullOrEmpty(result.Status) == false;
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/WebsitePanel.WebDav.Core.csproj b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/WebsitePanel.WebDav.Core.csproj
index 67043bd5..1398a59d 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/WebsitePanel.WebDav.Core.csproj
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/WebsitePanel.WebDav.Core.csproj
@@ -46,6 +46,9 @@
False
..\..\Bin\Microsoft.Web.Services3.dll
+
+ ..\packages\RestSharp.105.0.1\lib\net4\RestSharp.dll
+
@@ -87,6 +90,10 @@
+
+ ..\packages\Twilio.3.6.29\lib\3.5\Twilio.Api.dll
+ True
+
..\..\Bin\WebsitePanel.EnterpriseServer.Base.dll
@@ -108,6 +115,7 @@
+
@@ -126,6 +134,7 @@
+
@@ -149,6 +158,9 @@
+
+
+
@@ -188,6 +200,7 @@
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/packages.config b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/packages.config
index ad6a1af2..7188fe00 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDav.Core/packages.config
+++ b/WebsitePanel/Sources/WebsitePanel.WebDav.Core/packages.config
@@ -5,4 +5,6 @@
+
+
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/BundleConfig.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/BundleConfig.cs
index d3be4e58..1986068a 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/BundleConfig.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/BundleConfig.cs
@@ -17,7 +17,8 @@ namespace WebsitePanel.WebDavPortal
bundles.Add(jQueryBundle);
bundles.Add(new ScriptBundle("~/bundles/jqueryval").Include(
- "~/Scripts/jquery.validate*"));
+ "~/Scripts/jquery.validate*",
+ "~/Scripts/appScripts/validation/passwordeditor.unobtrusive.js"));
// Use the development version of Modernizr to develop with and learn from. Then, when you're
// ready for production, use the build tool at http://modernizr.com to pick only the tests you need.
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/RouteConfig.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/RouteConfig.cs
index bf48c585..98ab21f4 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/RouteConfig.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/RouteConfig.cs
@@ -12,6 +12,48 @@ namespace WebsitePanel.WebDavPortal
#region Account
+ routes.MapRoute(
+ name: AccountRouteNames.PhoneNumberIsAvailible,
+ url: "account/profile/phone-number-availible",
+ defaults: new { controller = "Account", action = "PhoneNumberIsAvailible" }
+ );
+
+ routes.MapRoute(
+ name: AccountRouteNames.UserProfile,
+ url: "account/profile",
+ defaults: new { controller = "Account", action = "UserProfile" }
+ );
+
+ routes.MapRoute(
+ name: AccountRouteNames.PasswordResetEmail,
+ url: "account/password-reset/step-1",
+ defaults: new { controller = "Account", action = "PasswordResetEmail" }
+ );
+
+ routes.MapRoute(
+ name: AccountRouteNames.PasswordResetSms,
+ url: "account/password-reset/step-2/{token}",
+ defaults: new { controller = "Account", action = "PasswordResetSms" }
+ );
+
+ routes.MapRoute(
+ name: AccountRouteNames.PasswordResetSendSms,
+ url: "account/password-reset/step-final/{token}",
+ defaults: new { controller = "Account", action = "PasswordResetSendSms" }
+ );
+
+ routes.MapRoute(
+ name: AccountRouteNames.PasswordResetFinalStep,
+ url: "account/password-reset/send-new-sms/{token}",
+ defaults: new { controller = "Account", action = "PasswordResetFinalStep" }
+ );
+
+ routes.MapRoute(
+ name: AccountRouteNames.PasswordChange,
+ url: "account/profile/password-change",
+ defaults: new { controller = "Account", action = "PasswordChange" }
+ );
+
routes.MapRoute(
name: AccountRouteNames.Logout,
url: "account/logout",
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/Routes/AccountRouteNames.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/Routes/AccountRouteNames.cs
index 035fde95..cd3da37d 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/Routes/AccountRouteNames.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/App_Start/Routes/AccountRouteNames.cs
@@ -9,5 +9,14 @@ namespace WebsitePanel.WebDavPortal.UI.Routes
{
public const string Logout = "AccountLogout";
public const string Login = "AccountLogin";
+ public const string UserProfile = "UserProfileRoute";
+
+ public const string PasswordChange = "PasswordChangeRoute";
+ public const string PasswordResetEmail = "PasswordResetEmailRoute";
+ public const string PasswordResetSms = "PasswordResetSmsRoute";
+ public const string PasswordResetSendSms = "PasswordResetSendSmsRoute";
+ public const string PasswordResetFinalStep = "PasswordResetFinalStepRoute";
+
+ public const string PhoneNumberIsAvailible = "PhoneNumberIsAvailibleRoute";
}
}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Constants/Formtas.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Constants/Formats.cs
similarity index 81%
rename from WebsitePanel/Sources/WebsitePanel.WebDavPortal/Constants/Formtas.cs
rename to WebsitePanel/Sources/WebsitePanel.WebDavPortal/Constants/Formats.cs
index 9c4127ab..775cd9b3 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Constants/Formtas.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Constants/Formats.cs
@@ -1,6 +1,6 @@
namespace WebsitePanel.WebDavPortal.Constants
{
- public class Formtas
+ public class Formats
{
public const string DateFormatWithTime = "MM/dd/yyyy hh:mm tt";
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Content/Site.css b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Content/Site.css
index 609ab5d0..2173c20a 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Content/Site.css
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Content/Site.css
@@ -230,6 +230,26 @@ tr.selected-file {
color: white;
}
+.forgot-your-password-link {
+ margin-left: 10px;
+}
+
+.navbar-fixed-top #user-profile {
+ font-size: 18px;
+ text-decoration: none;
+}
+
+.navbar-fixed-top #user-profile:hover {
+ text-decoration: none;
+}
+
+.user-profile .password-information {
+ padding-top: 7px;
+}
+
+.user-profile .login-name {
+ padding-top: 7px;
+}
.web-dav-folder-progress {
margin-bottom: 0px;
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/AccountController.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/AccountController.cs
index 6af67e4b..84e1a34f 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/AccountController.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/AccountController.cs
@@ -1,12 +1,19 @@
-using System.Linq;
+using System;
+using System.Linq;
using System.Net;
using System.Web.Mvc;
using System.Web.Routing;
+using AutoMapper;
+using WebsitePanel.Providers.HostedSolution;
using WebsitePanel.WebDav.Core.Config;
using WebsitePanel.WebDav.Core.Security.Authentication;
using WebsitePanel.WebDav.Core.Security.Cryptography;
+using WebsitePanel.WebDav.Core.Wsp.Framework;
+using WebsitePanel.WebDavPortal.CustomAttributes;
using WebsitePanel.WebDavPortal.Models;
+using WebsitePanel.WebDavPortal.Models.Account;
using WebsitePanel.WebDavPortal.Models.Common;
+using WebsitePanel.WebDavPortal.Models.Common.EditorTemplates;
using WebsitePanel.WebDavPortal.Models.Common.Enums;
using WebsitePanel.WebDavPortal.UI.Routes;
using WebsitePanel.WebDav.Core.Interfaces.Security;
@@ -14,19 +21,22 @@ using WebsitePanel.WebDav.Core;
namespace WebsitePanel.WebDavPortal.Controllers
{
- [AllowAnonymous]
- public class AccountController : Controller
+ [LdapAuthorization]
+ public class AccountController : BaseController
{
private readonly ICryptography _cryptography;
private readonly IAuthenticationService _authenticationService;
+ private readonly ISmsAuthenticationService _smsAuthService;
- public AccountController(ICryptography cryptography, IAuthenticationService authenticationService)
+ public AccountController(ICryptography cryptography, IAuthenticationService authenticationService, ISmsAuthenticationService smsAuthService)
{
_cryptography = cryptography;
_authenticationService = authenticationService;
+ _smsAuthService = smsAuthService;
}
[HttpGet]
+ [AllowAnonymous]
public ActionResult Login()
{
if (WspContext.User != null && WspContext.User.Identity.IsAuthenticated)
@@ -34,10 +44,21 @@ namespace WebsitePanel.WebDavPortal.Controllers
return RedirectToRoute(FileSystemRouteNames.ShowContentPath, new { org = WspContext.User.OrganizationId });
}
- return View();
+ var model = new AccountModel();
+
+ var settings = WspContext.Services.Organizations.GetWebDavSystemSettings();
+
+ if (settings != null)
+ {
+ model.PasswordResetEnabled = settings.GetValueOrDefault(EnterpriseServer.SystemSettings.WEBDAV_PASSWORD_RESET_ENABLED_KEY, false);
+
+ }
+
+ return View(model);
}
[HttpPost]
+ [AllowAnonymous]
public ActionResult Login(AccountModel model)
{
var user = _authenticationService.LogIn(model.Login, model.Password);
@@ -63,5 +84,308 @@ namespace WebsitePanel.WebDavPortal.Controllers
return RedirectToRoute(AccountRouteNames.Login);
}
+
+ [HttpGet]
+ public ActionResult UserProfile()
+ {
+ var model = GetUserProfileModel(WspContext.User.ItemId, WspContext.User.AccountId);
+
+ return View(model);
+ }
+
+ [HttpPost]
+ [ValidateAntiForgeryToken]
+ public ActionResult UserProfile(UserProfile model)
+ {
+ if (!ModelState.IsValid)
+ {
+ return View(model);
+ }
+
+ int result = UpdateUserProfile(WspContext.User.ItemId, WspContext.User.AccountId, model);
+
+ AddMessage(MessageType.Success, Resources.UI.UserProfileSuccessfullyUpdated);
+
+ return View(model);
+ }
+
+ public JsonResult PhoneNumberIsAvailible()
+ {
+ var value = Request.QueryString.AllKeys.Any() ? Request.QueryString.Get(0) :string.Empty;
+
+ var result = !WspContext.Services.Organizations.CheckPhoneNumberIsInUse(WspContext.User.ItemId,
+ value, WspContext.User.Login);
+
+ return Json(result, JsonRequestBehavior.AllowGet);
+ }
+
+ [HttpGet]
+ public ActionResult PasswordChange()
+ {
+ var model = new PasswordChangeModel();
+
+ return View(model);
+ }
+
+ [HttpPost]
+ public ActionResult PasswordChange(PasswordChangeModel model)
+ {
+ if (!ModelState.IsValid)
+ {
+ return View(model);
+ }
+
+ if (_authenticationService.ValidateAuthenticationData(WspContext.User.Login, model.OldPassword) == false)
+ {
+ AddMessage(MessageType.Error, Resources.Messages.OldPasswordIsNotCorrect);
+
+ return View(model);
+ }
+
+ WspContext.Services.Organizations.SetUserPassword(
+ WspContext.User.ItemId, WspContext.User.AccountId,
+ model.PasswordEditor.NewPassword);
+
+ var user = _authenticationService.LogIn(WspContext.User.Login, model.PasswordEditor.NewPassword);
+
+ _authenticationService.CreateAuthenticationTicket(user);
+
+ AddMessage(MessageType.Success, Resources.Messages.PasswordSuccessfullyChanged);
+
+ return RedirectToRoute(AccountRouteNames.UserProfile);
+ }
+
+ [HttpGet]
+ [AllowAnonymous]
+ public ActionResult PasswordResetEmail()
+ {
+ var model = new PasswordResetEmailModel();
+
+ return View(model);
+ }
+
+ [HttpPost]
+ [AllowAnonymous]
+ public ActionResult PasswordResetEmail(PasswordResetEmailModel model)
+ {
+ if (!ModelState.IsValid)
+ {
+ return View(model);
+ }
+
+ var exchangeAccount = WspContext.Services.ExchangeServer.GetAccountByAccountNameWithoutItemId(model.Email);
+
+ if (exchangeAccount == null)
+ {
+ AddMessage(MessageType.Error, Resources.Messages.AccountNotFound);
+
+ return View(model);
+ }
+
+ WspContext.Services.Organizations.SendResetUserPasswordEmail(exchangeAccount.ItemId, exchangeAccount.AccountId, Resources.Messages.PasswordResetUserReason, exchangeAccount.PrimaryEmailAddress);
+
+ return View("PasswordResetEmailSent");
+ }
+
+
+ [HttpGet]
+ [AllowAnonymous]
+ public ActionResult PasswordResetSms(Guid token)
+ {
+ var model = new PasswordResetSmsModel();
+
+ var accessToken = WspContext.Services.Organizations.GetPasswordresetAccessToken(token);
+
+ model.IsTokenExist = accessToken != null;
+
+ if (model.IsTokenExist == false)
+ {
+ AddMessage(MessageType.Error, Resources.Messages.IncorrectPasswordResetUrl);
+
+ return View(model);
+ }
+
+ if (accessToken.IsSmsSent == false)
+ {
+ var user = WspContext.Services.Organizations.GetUserGeneralSettings(accessToken.ItemId, accessToken.AccountId);
+
+ if (SendPasswordResetSms(accessToken.AccessTokenGuid, user.MobilePhone))
+ {
+ AddMessage(MessageType.Success, Resources.Messages.SmsWasSent);
+ }
+ else
+ {
+ AddMessage(MessageType.Error, Resources.Messages.SmsWasNotSent);
+ }
+ }
+
+ return View(model);
+ }
+
+ [HttpPost]
+ [AllowAnonymous]
+ public ActionResult PasswordResetSms(Guid token, PasswordResetSmsModel model)
+ {
+ if (!ModelState.IsValid)
+ {
+ return View(model);
+ }
+
+ if (_smsAuthService.VerifyResponse(token, model.Sms))
+ {
+ var tokenEntity = WspContext.Services.Organizations.GetPasswordresetAccessToken(token);
+
+ Session[WebDavAppConfigManager.Instance.SessionKeys.PasswordResetSmsKey] = model.Sms;
+ Session[WebDavAppConfigManager.Instance.SessionKeys.ItemId] = tokenEntity.ItemId;
+
+ return RedirectToRoute(AccountRouteNames.PasswordResetFinalStep);
+ }
+
+ AddMessage(MessageType.Error, Resources.Messages.IncorrectSmsResponse);
+
+ return View(model);
+ }
+
+
+ [HttpGet]
+ [AllowAnonymous]
+ public ActionResult PasswordResetFinalStep(Guid token)
+ {
+ var smsResponse = Session[WebDavAppConfigManager.Instance.SessionKeys.PasswordResetSmsKey] as string;
+
+ if (_smsAuthService.VerifyResponse(token, smsResponse) == false)
+ {
+ return RedirectToRoute(AccountRouteNames.PasswordResetSms);
+ }
+
+ var model = new PasswordEditor();
+
+ return View(model);
+ }
+
+ [HttpPost]
+ [AllowAnonymous]
+ public ActionResult PasswordResetFinalStep(Guid token, PasswordEditor model)
+ {
+ if (!ModelState.IsValid)
+ {
+ return View(model);
+ }
+
+ var smsResponse = Session[WebDavAppConfigManager.Instance.SessionKeys.PasswordResetSmsKey] as string;
+
+ if (_smsAuthService.VerifyResponse(token, smsResponse) == false)
+ {
+ AddMessage(MessageType.Error, Resources.Messages.IncorrectSmsResponse);
+
+ return RedirectToRoute(AccountRouteNames.PasswordResetSms);
+ }
+
+ var tokenEntity = WspContext.Services.Organizations.GetPasswordresetAccessToken(token);
+
+ WspContext.Services.Organizations.SetUserPassword(
+ tokenEntity.ItemId, tokenEntity.AccountId,
+ model.NewPassword);
+
+ WspContext.Services.Organizations.DeletePasswordresetAccessToken(token);
+
+ AddMessage(MessageType.Success, Resources.Messages.PasswordSuccessfullyChanged);
+
+ return RedirectToRoute(AccountRouteNames.Login);
+ }
+
+ [HttpGet]
+ [AllowAnonymous]
+ public ActionResult PasswordResetSendSms(Guid token)
+ {
+ var accessToken = WspContext.Services.Organizations.GetPasswordresetAccessToken(token);
+
+ if (accessToken == null)
+ {
+ return RedirectToRoute(AccountRouteNames.PasswordResetSms);
+ }
+
+ var user = WspContext.Services.Organizations.GetUserGeneralSettings(accessToken.ItemId,
+ accessToken.AccountId);
+
+
+ if (SendPasswordResetSms(accessToken.AccessTokenGuid, user.MobilePhone))
+ {
+ AddMessage(MessageType.Success, Resources.Messages.SmsWasSent);
+ }
+ else
+ {
+ AddMessage(MessageType.Error, Resources.Messages.SmsWasNotSent);
+ }
+
+ return RedirectToRoute(AccountRouteNames.PasswordResetSms);
+ }
+
+ #region Helpers
+
+ private bool SendPasswordResetSms(Guid token, string mobilePhone)
+ {
+ var response = _smsAuthService.SendRequestMessage(mobilePhone);
+
+ if (string.IsNullOrEmpty(response))
+ {
+ return false;
+ }
+ WspContext.Services.Organizations.SetAccessTokenResponse(token, response);
+
+ return true;
+ }
+
+ private UserProfile GetUserProfileModel(int itemId, int accountId)
+ {
+ var user = WspContext.Services.Organizations.GetUserGeneralSettings(itemId, accountId);
+
+ return Mapper.Map(user);
+ }
+
+ private int UpdateUserProfile(int itemId, int accountId, UserProfile model)
+ {
+ var user = WspContext.Services.Organizations.GetUserGeneralSettings(itemId, accountId);
+
+ return WspContext.Services.Organizations.SetUserGeneralSettings(
+ itemId, accountId,
+ model.DisplayName,
+ string.Empty,
+ false,
+ user.Disabled,
+ user.Locked,
+
+ model.FirstName,
+ model.Initials,
+ model.LastName,
+
+ model.Address,
+ model.City,
+ model.State,
+ model.Zip,
+ model.Country,
+
+ user.JobTitle,
+ user.Company,
+ user.Department,
+ user.Office,
+ user.Manager == null ? null : user.Manager.AccountName,
+
+ model.BusinessPhone,
+ model.Fax,
+ model.HomePhone,
+ model.MobilePhone,
+ model.Pager,
+ model.WebPage,
+ model.Notes,
+ model.ExternalEmail,
+ user.SubscriberNumber,
+ user.LevelId,
+ user.IsVIP,
+ user.UserMustChangePassword);
+ }
+
+ #endregion
+
}
}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/BaseController.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/BaseController.cs
new file mode 100644
index 00000000..78a4c690
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/BaseController.cs
@@ -0,0 +1,33 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.Mvc;
+using WebsitePanel.WebDavPortal.Models.Common;
+using WebsitePanel.WebDavPortal.Models.Common.Enums;
+
+namespace WebsitePanel.WebDavPortal.Controllers
+{
+ public class BaseController : Controller
+ {
+ public const string MessagesKey = "messagesKey";
+
+ public void AddMessage(MessageType type, string value)
+ {
+ var messages = TempData[MessagesKey] as List;
+
+ if (messages == null)
+ {
+ messages = new List();
+ }
+
+ messages.Add(new Message
+ {
+ Type = type,
+ Value = value
+ });
+
+ TempData[MessagesKey] = messages;
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/FileSystemController.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/FileSystemController.cs
index bf79329a..74eb08fa 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/FileSystemController.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Controllers/FileSystemController.cs
@@ -42,7 +42,7 @@ namespace WebsitePanel.WebDavPortal.Controllers
{
[ValidateInput(false)]
[LdapAuthorization]
- public class FileSystemController : Controller
+ public class FileSystemController : BaseController
{
private readonly ICryptography _cryptography;
private readonly IWebDavManager _webdavManager;
@@ -276,7 +276,7 @@ namespace WebsitePanel.WebDavPortal.Controllers
if (filePathes == null)
{
- model.AddMessage(MessageType.Error, Resources.UI.NoFilesAreSelected);
+ AddMessage(MessageType.Error, Resources.UI.NoFilesAreSelected);
return Json(model);
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/OrganizationPasswordPolicyAttribute.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/OrganizationPasswordPolicyAttribute.cs
new file mode 100644
index 00000000..6fea16be
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/OrganizationPasswordPolicyAttribute.cs
@@ -0,0 +1,136 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel.DataAnnotations;
+using System.Linq;
+using System.Web;
+using System.Web.Mvc;
+using WebsitePanel.Providers.HostedSolution;
+using WebsitePanel.WebDav.Core;
+using WebsitePanel.WebDav.Core.Config;
+
+namespace WebsitePanel.WebDavPortal.CustomAttributes
+{
+ [AttributeUsage(AttributeTargets.Property, AllowMultiple = false, Inherited = false)]
+ public class OrganizationPasswordPolicyAttribute : ValidationAttribute, IClientValidatable
+ {
+ public int ItemId { get; private set; }
+
+ public OrganizationPasswordPolicyAttribute()
+ {
+ if (WspContext.User != null)
+ {
+ ItemId = WspContext.User.ItemId;
+ }
+ else if (HttpContext.Current != null && HttpContext.Current.Session[WebDavAppConfigManager.Instance.SessionKeys.ItemId] != null)
+ {
+ ItemId = (int)HttpContext.Current.Session[WebDavAppConfigManager.Instance.SessionKeys.ItemId];
+ }
+ }
+
+ protected override ValidationResult IsValid(object value, ValidationContext validationContext)
+ {
+ if (value != null)
+ {
+ var resultMessages = new List();
+
+ var settings = WspContext.Services.Organizations.GetOrganizationPasswordSettings(ItemId);
+
+ if (settings != null)
+ {
+ var valueString = value.ToString();
+
+ if (valueString.Length < settings.MinimumLength)
+ {
+ resultMessages.Add(string.Format(Resources.Messages.PasswordMinLengthFormat,
+ settings.MinimumLength));
+ }
+
+ if (valueString.Length > settings.MaximumLength)
+ {
+ resultMessages.Add(string.Format(Resources.Messages.PasswordMaxLengthFormat,
+ settings.MaximumLength));
+ }
+
+ if (settings.PasswordComplexityEnabled)
+ {
+ var symbolsCount = valueString.Count(Char.IsSymbol);
+ var numbersCount = valueString.Count(Char.IsDigit);
+ var upperLetterCount = valueString.Count(Char.IsUpper);
+
+ if (upperLetterCount < settings.UppercaseLettersCount)
+ {
+ resultMessages.Add(string.Format(Resources.Messages.PasswordUppercaseCountFormat,
+ settings.UppercaseLettersCount));
+ }
+
+ if (numbersCount < settings.NumbersCount)
+ {
+ resultMessages.Add(string.Format(Resources.Messages.PasswordNumbersCountFormat,
+ settings.NumbersCount));
+ }
+
+ if (symbolsCount < settings.SymbolsCount)
+ {
+ resultMessages.Add(string.Format(Resources.Messages.PasswordSymbolsCountFormat,
+ settings.SymbolsCount));
+ }
+ }
+
+ }
+
+ return resultMessages.Any()? new ValidationResult(string.Join(" ", resultMessages)) : ValidationResult.Success;
+ }
+
+ return ValidationResult.Success;
+ }
+
+ public IEnumerable GetClientValidationRules(ModelMetadata metadata, ControllerContext context)
+ {
+ var settings = WspContext.Services.Organizations.GetOrganizationPasswordSettings(ItemId);
+
+ var rule = new ModelClientValidationRule();
+
+ rule.ErrorMessage = string.Format(Resources.Messages.PasswordMinLengthFormat, settings.MinimumLength);
+ rule.ValidationParameters.Add("count", settings.MinimumLength);
+ rule.ValidationType = "minimumlength";
+
+ yield return rule;
+
+ rule = new ModelClientValidationRule();
+
+ rule.ErrorMessage = string.Format(Resources.Messages.PasswordMaxLengthFormat, settings.MaximumLength);
+ rule.ValidationParameters.Add("count", settings.MaximumLength);
+ rule.ValidationType = "maximumlength";
+
+ yield return rule;
+
+ if (settings.PasswordComplexityEnabled)
+ {
+ rule = new ModelClientValidationRule();
+
+ rule.ErrorMessage = string.Format(Resources.Messages.PasswordUppercaseCountFormat, settings.UppercaseLettersCount);
+ rule.ValidationParameters.Add("count", settings.UppercaseLettersCount);
+ rule.ValidationType = "uppercasecount";
+
+ yield return rule;
+
+ rule = new ModelClientValidationRule();
+
+ rule.ErrorMessage = string.Format(Resources.Messages.PasswordNumbersCountFormat, settings.NumbersCount);
+ rule.ValidationParameters.Add("count", settings.NumbersCount);
+ rule.ValidationType = "numberscount";
+
+ yield return rule;
+
+ rule = new ModelClientValidationRule();
+
+ rule.ErrorMessage = string.Format(Resources.Messages.PasswordSymbolsCountFormat, settings.SymbolsCount);
+ rule.ValidationParameters.Add("count", settings.SymbolsCount);
+ rule.ValidationType = "symbolscount";
+
+ yield return rule;
+ }
+ }
+
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/PhoneNumberAttribute.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/PhoneNumberAttribute.cs
new file mode 100644
index 00000000..bd7abaea
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/PhoneNumberAttribute.cs
@@ -0,0 +1,21 @@
+using System.Collections.Generic;
+using System.ComponentModel.DataAnnotations;
+using System.Web.Mvc;
+
+namespace WebsitePanel.WebDavPortal.CustomAttributes
+{
+ public class PhoneNumberAttribute : RegularExpressionAttribute, IClientValidatable
+ {
+ public const string PhonePattern = @"^\+?\d+$";
+
+ public PhoneNumberAttribute()
+ : base(PhonePattern)
+ {
+ }
+
+ public IEnumerable GetClientValidationRules(ModelMetadata metadata, ControllerContext context)
+ {
+ yield return new ModelClientValidationRegexRule(FormatErrorMessage(metadata.GetDisplayName()), Pattern);
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/UniqueAdPhoneNumberAttribute.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/UniqueAdPhoneNumberAttribute.cs
new file mode 100644
index 00000000..fe28bdd7
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/CustomAttributes/UniqueAdPhoneNumberAttribute.cs
@@ -0,0 +1,46 @@
+using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.ComponentModel.DataAnnotations;
+using System.Linq;
+using System.Reflection;
+using System.Web.Mvc;
+using System.Web.Routing;
+using WebsitePanel.WebDav.Core;
+
+namespace WebsitePanel.WebDavPortal.CustomAttributes
+{
+ [AttributeUsage(AttributeTargets.Property, AllowMultiple = false, Inherited = false)]
+ public class UniqueAdPhoneNumberAttribute : RemoteAttribute
+ {
+
+ protected override ValidationResult IsValid(object value, ValidationContext validationContext)
+ {
+ var valueString = value as string;
+
+ if (!string.IsNullOrEmpty(valueString) && WspContext.User != null)
+ {
+ var attributes =
+ validationContext.ObjectType.GetProperty(validationContext.MemberName)
+ .GetCustomAttributes(typeof(DisplayNameAttribute), true);
+
+ string displayName = attributes != null && attributes.Any()
+ ? (attributes[0] as DisplayNameAttribute).DisplayName
+ : validationContext.DisplayName;
+
+
+ var result = !WspContext.Services.Organizations.CheckPhoneNumberIsInUse(WspContext.User.ItemId, valueString, WspContext.User.Login);
+
+ return result ? ValidationResult.Success :
+ new ValidationResult(string.Format(Resources.Messages.AlreadyInUse, displayName));
+ }
+
+ return ValidationResult.Success;
+ }
+
+ public UniqueAdPhoneNumberAttribute(string routeName) : base(routeName) { }
+ public UniqueAdPhoneNumberAttribute(string action, string controller) : base(action, controller) { }
+ public UniqueAdPhoneNumberAttribute(string action, string controller,
+ string area) : base(action, controller, area) { }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/DependencyInjection/PortalDependencies.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/DependencyInjection/PortalDependencies.cs
index c7661530..ad15cd2b 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/DependencyInjection/PortalDependencies.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/DependencyInjection/PortalDependencies.cs
@@ -4,6 +4,7 @@ using WebsitePanel.WebDav.Core.Interfaces.Managers;
using WebsitePanel.WebDav.Core.Interfaces.Managers.Users;
using WebsitePanel.WebDav.Core.Interfaces.Owa;
using WebsitePanel.WebDav.Core.Interfaces.Security;
+using WebsitePanel.WebDav.Core.Interfaces.Services;
using WebsitePanel.WebDav.Core.Interfaces.Storages;
using WebsitePanel.WebDav.Core.Managers;
using WebsitePanel.WebDav.Core.Managers.Users;
@@ -11,6 +12,7 @@ using WebsitePanel.WebDav.Core.Owa;
using WebsitePanel.WebDav.Core.Security.Authentication;
using WebsitePanel.WebDav.Core.Security.Authorization;
using WebsitePanel.WebDav.Core.Security.Cryptography;
+using WebsitePanel.WebDav.Core.Services;
using WebsitePanel.WebDav.Core.Storages;
using WebsitePanel.WebDavPortal.DependencyInjection.Providers;
@@ -31,6 +33,8 @@ namespace WebsitePanel.WebDavPortal.DependencyInjection
kernel.Bind().To();
kernel.Bind().To();
kernel.Bind().To();
+ kernel.Bind().To();
+ kernel.Bind().To();
}
}
}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Global.asax.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Global.asax.cs
index fd14b881..fa9a357c 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Global.asax.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Global.asax.cs
@@ -15,6 +15,7 @@ using WebsitePanel.WebDav.Core.Security.Authentication.Principals;
using WebsitePanel.WebDav.Core.Security.Cryptography;
using WebsitePanel.WebDavPortal.App_Start;
using WebsitePanel.WebDavPortal.Controllers;
+using WebsitePanel.WebDavPortal.CustomAttributes;
using WebsitePanel.WebDavPortal.DependencyInjection;
using WebsitePanel.WebDavPortal.HttpHandlers;
using WebsitePanel.WebDavPortal.Mapping;
@@ -39,6 +40,10 @@ namespace WebsitePanel.WebDavPortal
Mapper.AssertConfigurationIsValid();
log4net.Config.XmlConfigurator.Configure();
+
+ DataAnnotationsModelValidatorProvider.RegisterAdapter(
+ typeof(PhoneNumberAttribute),
+ typeof(RegularExpressionAttributeAdapter));
}
protected void Application_Error(object sender, EventArgs e)
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/AutoMapperPortalConfiguration.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/AutoMapperPortalConfiguration.cs
index 060bb3af..b13fbf4c 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/AutoMapperPortalConfiguration.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/AutoMapperPortalConfiguration.cs
@@ -1,4 +1,5 @@
using AutoMapper;
+using WebsitePanel.WebDavPortal.Mapping.Profiles.Account;
using WebsitePanel.WebDavPortal.Mapping.Profiles.Webdav;
namespace WebsitePanel.WebDavPortal.Mapping
@@ -10,6 +11,7 @@ namespace WebsitePanel.WebDavPortal.Mapping
Mapper.Initialize(
config =>
{
+ config.AddProfile();
config.AddProfile();
});
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/Profiles/Account/UserProfileProfile.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/Profiles/Account/UserProfileProfile.cs
new file mode 100644
index 00000000..b8f2f620
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/Profiles/Account/UserProfileProfile.cs
@@ -0,0 +1,66 @@
+using System;
+using System.IO;
+using AutoMapper;
+using WebsitePanel.Providers.HostedSolution;
+using WebsitePanel.WebDav.Core.Client;
+using WebsitePanel.WebDav.Core.Config;
+using WebsitePanel.WebDav.Core.Extensions;
+using WebsitePanel.WebDavPortal.Constants;
+using WebsitePanel.WebDavPortal.FileOperations;
+using WebsitePanel.WebDavPortal.Models.Account;
+using WebsitePanel.WebDavPortal.Models.FileSystem;
+
+namespace WebsitePanel.WebDavPortal.Mapping.Profiles.Account
+{
+ public class UserProfileProfile : Profile
+ {
+ ///
+ /// Gets the name of the profile.
+ ///
+ ///
+ /// The name of the profile.
+ ///
+ public override string ProfileName
+ {
+ get
+ {
+ return this.GetType().Name;
+ }
+ }
+
+ ///
+ /// Override this method in a derived class and call the CreateMap method to associate that map with this profile.
+ /// Avoid calling the class from this method.
+ ///
+ protected override void Configure()
+ {
+ Mapper.CreateMap()
+ .ForMember(ti => ti.PrimaryEmailAddress, x => x.MapFrom(hi => hi.PrimaryEmailAddress))
+ .ForMember(ti => ti.DisplayName, x => x.MapFrom(hi => hi.DisplayName))
+ .ForMember(ti => ti.DisplayName, x => x.MapFrom(hi => hi.DisplayName))
+ .ForMember(ti => ti.AccountName, x => x.MapFrom(hi => hi.AccountName))
+ .ForMember(ti => ti.FirstName, x => x.MapFrom(hi => hi.FirstName))
+ .ForMember(ti => ti.Initials, x => x.MapFrom(hi => hi.Initials))
+ .ForMember(ti => ti.LastName, x => x.MapFrom(hi => hi.LastName))
+ .ForMember(ti => ti.JobTitle, x => x.MapFrom(hi => hi.JobTitle))
+ .ForMember(ti => ti.Company, x => x.MapFrom(hi => hi.Company))
+ .ForMember(ti => ti.Department, x => x.MapFrom(hi => hi.Department))
+ .ForMember(ti => ti.Office, x => x.MapFrom(hi => hi.Office))
+ .ForMember(ti => ti.BusinessPhone, x => x.MapFrom(hi => hi.BusinessPhone))
+ .ForMember(ti => ti.Fax, x => x.MapFrom(hi => hi.Fax))
+ .ForMember(ti => ti.HomePhone, x => x.MapFrom(hi => hi.HomePhone))
+ .ForMember(ti => ti.MobilePhone, x => x.MapFrom(hi => hi.MobilePhone))
+ .ForMember(ti => ti.Pager, x => x.MapFrom(hi => hi.Pager))
+ .ForMember(ti => ti.WebPage, x => x.MapFrom(hi => hi.WebPage))
+ .ForMember(ti => ti.Address, x => x.MapFrom(hi => hi.Address))
+ .ForMember(ti => ti.City, x => x.MapFrom(hi => hi.City))
+ .ForMember(ti => ti.State, x => x.MapFrom(hi => hi.State))
+ .ForMember(ti => ti.Zip, x => x.MapFrom(hi => hi.Zip))
+ .ForMember(ti => ti.Country, x => x.MapFrom(hi => hi.Country))
+ .ForMember(ti => ti.Notes, x => x.MapFrom(hi => hi.Notes))
+ .ForMember(ti => ti.PasswordExpirationDateTime, x => x.MapFrom(hi => hi.PasswordExpirationDateTime))
+ .ForMember(ti => ti.ExternalEmail, x => x.MapFrom(hi => hi.ExternalEmail));
+ }
+ }
+}
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/Profiles/Webdav/ResourceTableItemProfile.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/Profiles/Webdav/ResourceTableItemProfile.cs
index 92987801..579911bc 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/Profiles/Webdav/ResourceTableItemProfile.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Mapping/Profiles/Webdav/ResourceTableItemProfile.cs
@@ -44,12 +44,16 @@ namespace WebsitePanel.WebDavPortal.Mapping.Profiles.Webdav
.ForMember(ti => ti.IconHref, x => x.MapFrom(hi => hi.ItemType == ItemType.Folder ? WebDavAppConfigManager.Instance.FileIcons.FolderPath.Trim('~') : WebDavAppConfigManager.Instance.FileIcons[Path.GetExtension(hi.DisplayName.Trim('/'))].Trim('~')))
.ForMember(ti => ti.IsTargetBlank, x => x.MapFrom(hi => openerManager.GetIsTargetBlank(hi)))
.ForMember(ti => ti.LastModified, x => x.MapFrom(hi => hi.LastModified))
- .ForMember(ti => ti.LastModifiedFormated, x => x.MapFrom(hi => hi.LastModified == DateTime.MinValue ? "--" : (new WebDavResource(null, hi)).LastModified.ToString(Formtas.DateFormatWithTime)))
+ .ForMember(ti => ti.LastModifiedFormated, x => x.MapFrom(hi => hi.LastModified == DateTime.MinValue ? "--" : (new WebDavResource(null, hi)).LastModified.ToString(Formats.DateFormatWithTime)))
.ForMember(ti => ti.Summary, x => x.MapFrom(hi => hi.Summary))
.ForMember(ti => ti.IsRoot, x => x.MapFrom(hi => hi.IsRootItem))
.ForMember(ti => ti.Size, x => x.MapFrom(hi => hi.ContentLength))
.ForMember(ti => ti.Quota, x => x.MapFrom(hi => hi.AllocatedSpace))
+ .ForMember(ti => ti.Url, x => x.Ignore())
+ .ForMember(ti => ti.FolderUrlAbsoluteString, x => x.Ignore())
+ .ForMember(ti => ti.FolderUrlLocalString, x => x.Ignore())
+ .ForMember(ti => ti.FolderName, x => x.Ignore())
.ForMember(ti => ti.IsFolder, x => x.MapFrom(hi => hi.ItemType == ItemType.Folder));
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordChangeModel.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordChangeModel.cs
new file mode 100644
index 00000000..63a00430
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordChangeModel.cs
@@ -0,0 +1,23 @@
+using System.ComponentModel.DataAnnotations;
+using WebsitePanel.Providers.HostedSolution;
+using WebsitePanel.WebDavPortal.Models.Common;
+using WebsitePanel.WebDavPortal.Models.Common.EditorTemplates;
+
+namespace WebsitePanel.WebDavPortal.Models.Account
+{
+ public class PasswordChangeModel
+ {
+ [Display(ResourceType = typeof (Resources.UI), Name = "OldPassword")]
+ [Required(ErrorMessageResourceType = typeof (Resources.Messages), ErrorMessageResourceName = "Required")]
+ public string OldPassword { get; set; }
+
+ [UIHint("PasswordEditor")]
+ public PasswordEditor PasswordEditor { get; set; }
+
+
+ public PasswordChangeModel()
+ {
+ PasswordEditor = new PasswordEditor();
+ }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordResetEmailModel.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordResetEmailModel.cs
new file mode 100644
index 00000000..36d5b895
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordResetEmailModel.cs
@@ -0,0 +1,14 @@
+using System.ComponentModel.DataAnnotations;
+using WebsitePanel.WebDavPortal.Models.Common;
+using WebsitePanel.WebDavPortal.Resources;
+
+namespace WebsitePanel.WebDavPortal.Models.Account
+{
+ public class PasswordResetEmailModel
+ {
+ [Required]
+ [Display(ResourceType = typeof(Resources.UI), Name = "Email")]
+ [EmailAddress(ErrorMessageResourceType = typeof(Messages), ErrorMessageResourceName = "EmailInvalid",ErrorMessage = null)]
+ public string Email { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordResetSmsModel.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordResetSmsModel.cs
new file mode 100644
index 00000000..45a9de72
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/PasswordResetSmsModel.cs
@@ -0,0 +1,12 @@
+using System.ComponentModel.DataAnnotations;
+using WebsitePanel.WebDavPortal.Models.Common;
+
+namespace WebsitePanel.WebDavPortal.Models.Account
+{
+ public class PasswordResetSmsModel
+ {
+ [Required]
+ public string Sms { get; set; }
+ public bool IsTokenExist { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/UserProfile.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/UserProfile.cs
new file mode 100644
index 00000000..3fe96dca
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Account/UserProfile.cs
@@ -0,0 +1,78 @@
+using System;
+using System.ComponentModel;
+using System.ComponentModel.DataAnnotations;
+using System.Security.AccessControl;
+using WebsitePanel.WebDavPortal.CustomAttributes;
+using WebsitePanel.WebDavPortal.Models.Common;
+using WebsitePanel.WebDavPortal.UI.Routes;
+
+namespace WebsitePanel.WebDavPortal.Models.Account
+{
+ public class UserProfile
+ {
+ [Display(ResourceType = typeof(Resources.UI), Name = "PrimaryEmail")]
+ [Required(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "Required")]
+ [EmailAddress(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "EmailInvalid", ErrorMessage = null)]
+ public string PrimaryEmailAddress { get; set; }
+
+ [Display(ResourceType = typeof(Resources.UI), Name = "DisplayName")]
+ [Required(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "Required")]
+ public string DisplayName { get; set; }
+ public string AccountName { get; set; }
+
+ [Display(ResourceType = typeof(Resources.UI), Name = "FirstName")]
+ [Required(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "Required")]
+ public string FirstName { get; set; }
+ public string Initials { get; set; }
+
+ [Display(ResourceType = typeof(Resources.UI), Name = "LastName")]
+ [Required(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "Required")]
+ public string LastName { get; set; }
+ public string JobTitle { get; set; }
+ public string Company { get; set; }
+ public string Department { get; set; }
+ public string Office { get; set; }
+
+ [PhoneNumber(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "PhoneNumberInvalid")]
+ [UniqueAdPhoneNumber(AccountRouteNames.PhoneNumberIsAvailible, ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "AlreadyInUse")]
+ [Display(ResourceType = typeof(Resources.UI), Name = "BusinessPhone")]
+ public string BusinessPhone { get; set; }
+
+ [PhoneNumber(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "PhoneNumberInvalid")]
+ [UniqueAdPhoneNumber(AccountRouteNames.PhoneNumberIsAvailible, ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "AlreadyInUse")]
+ [Display(ResourceType = typeof(Resources.UI), Name = "Fax")]
+ public string Fax { get; set; }
+
+ [Display(ResourceType = typeof(Resources.UI), Name = "HomePhone")]
+ [PhoneNumber(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "PhoneNumberInvalid")]
+ [UniqueAdPhoneNumber(AccountRouteNames.PhoneNumberIsAvailible, ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "AlreadyInUse")]
+ public string HomePhone { get; set; }
+
+ [Display(ResourceType = typeof(Resources.UI), Name = "MobilePhone")]
+ [Required(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "Required")]
+ [PhoneNumber(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "PhoneNumberInvalid")]
+ [UniqueAdPhoneNumber(AccountRouteNames.PhoneNumberIsAvailible, ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "AlreadyInUse")]
+ public string MobilePhone { get; set; }
+
+ [PhoneNumber(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "PhoneNumberInvalid")]
+ [Display(ResourceType = typeof(Resources.UI), Name = "Pager")]
+ [UniqueAdPhoneNumber(AccountRouteNames.PhoneNumberIsAvailible,ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "AlreadyInUse")]
+ public string Pager { get; set; }
+
+ [Url(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "UrlInvalid", ErrorMessage = null)]
+ public string WebPage { get; set; }
+ public string Address { get; set; }
+ public string City { get; set; }
+ public string State { get; set; }
+ public string Zip { get; set; }
+
+ [EmailAddress(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "EmailInvalid", ErrorMessage = null)]
+ public string ExternalEmail { get; set; }
+
+ [UIHint("CountrySelector")]
+ public string Country { get; set; }
+
+ public string Notes { get; set; }
+ public DateTime PasswordExpirationDateTime { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/AccountModel.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/AccountModel.cs
index ecf7ed80..57351755 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/AccountModel.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/AccountModel.cs
@@ -5,7 +5,7 @@ using WebsitePanel.WebDavPortal.Models.Common;
namespace WebsitePanel.WebDavPortal.Models
{
- public class AccountModel : BaseModel
+ public class AccountModel
{
[Required]
[Display(Name = @"Login")]
@@ -17,5 +17,7 @@ namespace WebsitePanel.WebDavPortal.Models
public string Password { get; set; }
public string LdapError { get; set; }
+
+ public bool PasswordResetEnabled { get; set; }
}
}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/BaseModel.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/AjaxModel.cs
similarity index 76%
rename from WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/BaseModel.cs
rename to WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/AjaxModel.cs
index 7622e201..595f3253 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/BaseModel.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/AjaxModel.cs
@@ -1,12 +1,11 @@
using System.Collections.Generic;
-using System.Web.Mvc;
using WebsitePanel.WebDavPortal.Models.Common.Enums;
namespace WebsitePanel.WebDavPortal.Models.Common
{
- public class BaseModel
+ public class AjaxModel
{
- public BaseModel()
+ public AjaxModel()
{
Messages = new List();
}
@@ -17,9 +16,9 @@ namespace WebsitePanel.WebDavPortal.Models.Common
{
Messages.Add(new Message
{
- Type =type,
+ Type = type,
Value = value
});
- }
+ }
}
}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/EditorTemplates/PasswordEditor.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/EditorTemplates/PasswordEditor.cs
new file mode 100644
index 00000000..f433fd62
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/Common/EditorTemplates/PasswordEditor.cs
@@ -0,0 +1,22 @@
+using System.ComponentModel.DataAnnotations;
+using WebsitePanel.Providers.HostedSolution;
+using WebsitePanel.WebDavPortal.CustomAttributes;
+
+namespace WebsitePanel.WebDavPortal.Models.Common.EditorTemplates
+{
+ public class PasswordEditor
+ {
+
+ [Display(ResourceType = typeof(Resources.UI), Name = "NewPassword")]
+ [Required(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "Required")]
+ [OrganizationPasswordPolicy]
+ public string NewPassword { get; set; }
+
+ [Display(ResourceType = typeof(Resources.UI), Name = "NewPasswordConfirmation")]
+ [Required(ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "Required")]
+ [Compare("NewPassword", ErrorMessageResourceType = typeof(Resources.Messages), ErrorMessageResourceName = "PasswordDoesntMatch")]
+ public string NewPasswordConfirmation { get; set; }
+
+ public OrganizationPasswordSettings Settings { get; set; }
+ }
+}
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/ErrorModel.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/ErrorModel.cs
index bd62b88e..a153af5a 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/ErrorModel.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/ErrorModel.cs
@@ -3,7 +3,7 @@ using WebsitePanel.WebDavPortal.Models.Common;
namespace WebsitePanel.WebDavPortal.Models
{
- public class ErrorModel : BaseModel
+ public class ErrorModel
{
public int HttpStatusCode { get; set; }
public string Message { get; set; }
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/FileSystem/DeleteFilesModel.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/FileSystem/DeleteFilesModel.cs
index 892f88cb..8908f86f 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/FileSystem/DeleteFilesModel.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/FileSystem/DeleteFilesModel.cs
@@ -3,7 +3,7 @@ using WebsitePanel.WebDavPortal.Models.Common;
namespace WebsitePanel.WebDavPortal.Models.FileSystem
{
- public class DeleteFilesModel : BaseModel
+ public class DeleteFilesModel : AjaxModel
{
public DeleteFilesModel()
{
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/ModelForWebDav.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/ModelForWebDav.cs
index c54e50ac..b0de2b7f 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/ModelForWebDav.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/ModelForWebDav.cs
@@ -6,7 +6,7 @@ using WebsitePanel.WebDavPortal.Models.Common;
namespace WebsitePanel.WebDavPortal.Models
{
- public class ModelForWebDav : BaseModel
+ public class ModelForWebDav
{
public IEnumerable Items { get; set; }
public string UrlSuffix { get; set; }
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/OfficeOnlineModel.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/OfficeOnlineModel.cs
index c1b61cac..5f794e08 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/OfficeOnlineModel.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Models/OfficeOnlineModel.cs
@@ -2,7 +2,7 @@
namespace WebsitePanel.WebDavPortal.Models
{
- public class OfficeOnlineModel : BaseModel
+ public class OfficeOnlineModel
{
public string Url { get; set; }
public string FileName { get; set; }
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/Messages.Designer.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/Messages.Designer.cs
new file mode 100644
index 00000000..d456d0af
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/Messages.Designer.cs
@@ -0,0 +1,252 @@
+//------------------------------------------------------------------------------
+//
+// This code was generated by a tool.
+// Runtime Version:4.0.30319.33440
+//
+// Changes to this file may cause incorrect behavior and will be lost if
+// the code is regenerated.
+//
+//------------------------------------------------------------------------------
+
+namespace WebsitePanel.WebDavPortal.Resources {
+ using System;
+
+
+ ///
+ /// A strongly-typed resource class, for looking up localized strings, etc.
+ ///
+ // This class was auto-generated by the StronglyTypedResourceBuilder
+ // class via a tool like ResGen or Visual Studio.
+ // To add or remove a member, edit your .ResX file then rerun ResGen
+ // with the /str option, or rebuild your VS project.
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+ public class Messages {
+
+ private static global::System.Resources.ResourceManager resourceMan;
+
+ private static global::System.Globalization.CultureInfo resourceCulture;
+
+ [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
+ internal Messages() {
+ }
+
+ ///
+ /// Returns the cached ResourceManager instance used by this class.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ public static global::System.Resources.ResourceManager ResourceManager {
+ get {
+ if (object.ReferenceEquals(resourceMan, null)) {
+ global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("WebsitePanel.WebDavPortal.Resources.Messages", typeof(Messages).Assembly);
+ resourceMan = temp;
+ }
+ return resourceMan;
+ }
+ }
+
+ ///
+ /// Overrides the current thread's CurrentUICulture property for all
+ /// resource lookups using this strongly typed resource class.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ public static global::System.Globalization.CultureInfo Culture {
+ get {
+ return resourceCulture;
+ }
+ set {
+ resourceCulture = value;
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Account was not found.
+ ///
+ public static string AccountNotFound {
+ get {
+ return ResourceManager.GetString("AccountNotFound", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to {0} is already in use.
+ ///
+ public static string AlreadyInUse {
+ get {
+ return ResourceManager.GetString("AlreadyInUse", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Email is invalid.
+ ///
+ public static string EmailInvalid {
+ get {
+ return ResourceManager.GetString("EmailInvalid", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Your password could not be reset. The url you followed is either incorrect, has been used or has expired..
+ ///
+ public static string IncorrectPasswordResetUrl {
+ get {
+ return ResourceManager.GetString("IncorrectPasswordResetUrl", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Incorrect text message (SMS) response..
+ ///
+ public static string IncorrectSmsResponse {
+ get {
+ return ResourceManager.GetString("IncorrectSmsResponse", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Old password is not correct.
+ ///
+ public static string OldPasswordIsNotCorrect {
+ get {
+ return ResourceManager.GetString("OldPasswordIsNotCorrect", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to The password and confirmation password do not match..
+ ///
+ public static string PasswordDoesntMatch {
+ get {
+ return ResourceManager.GetString("PasswordDoesntMatch", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Password should be maximum {0} characters.
+ ///
+ public static string PasswordMaxLengthFormat {
+ get {
+ return ResourceManager.GetString("PasswordMaxLengthFormat", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Password should be at least {0} characters.
+ ///
+ public static string PasswordMinLengthFormat {
+ get {
+ return ResourceManager.GetString("PasswordMinLengthFormat", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Password should contain at least {0} numbers.
+ ///
+ public static string PasswordNumbersCountFormat {
+ get {
+ return ResourceManager.GetString("PasswordNumbersCountFormat", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to A message was sent to your email address. Please check your email for further instructions..
+ ///
+ public static string PasswordResetEmailSent {
+ get {
+ return ResourceManager.GetString("PasswordResetEmailSent", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Please enter the verification code we sent to your phone. If you didn't receive a code, you can {0}..
+ ///
+ public static string PasswordResetSmsHintFormat {
+ get {
+ return ResourceManager.GetString("PasswordResetSmsHintFormat", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Webdav portal user request..
+ ///
+ public static string PasswordResetUserReason {
+ get {
+ return ResourceManager.GetString("PasswordResetUserReason", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Your password have been successfully changed.
+ ///
+ public static string PasswordSuccessfullyChanged {
+ get {
+ return ResourceManager.GetString("PasswordSuccessfullyChanged", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Password should contain at least {0} non-alphanumeric symbols.
+ ///
+ public static string PasswordSymbolsCountFormat {
+ get {
+ return ResourceManager.GetString("PasswordSymbolsCountFormat", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Password should contain at least {0} UPPERCASE characters.
+ ///
+ public static string PasswordUppercaseCountFormat {
+ get {
+ return ResourceManager.GetString("PasswordUppercaseCountFormat", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Phone number is invalid.
+ ///
+ public static string PhoneNumberInvalid {
+ get {
+ return ResourceManager.GetString("PhoneNumberInvalid", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to {0} field is required.
+ ///
+ public static string Required {
+ get {
+ return ResourceManager.GetString("Required", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Text message (SMS) was not sent to your mobile phone. Invalid phone number..
+ ///
+ public static string SmsWasNotSent {
+ get {
+ return ResourceManager.GetString("SmsWasNotSent", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Text message (SMS) was sent to your mobile phone..
+ ///
+ public static string SmsWasSent {
+ get {
+ return ResourceManager.GetString("SmsWasSent", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Url is invalid.
+ ///
+ public static string UrlInvalid {
+ get {
+ return ResourceManager.GetString("UrlInvalid", resourceCulture);
+ }
+ }
+ }
+}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/Messages.resx b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/Messages.resx
new file mode 100644
index 00000000..3155ac22
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/Messages.resx
@@ -0,0 +1,183 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ Account was not found
+
+
+ {0} is already in use
+
+
+ Email is invalid
+
+
+ Your password could not be reset. The url you followed is either incorrect, has been used or has expired.
+
+
+ Incorrect text message (SMS) response.
+
+
+ Old password is not correct
+
+
+ The password and confirmation password do not match.
+
+
+ Password should be maximum {0} characters
+
+
+ Password should be at least {0} characters
+
+
+ Password should contain at least {0} numbers
+
+
+ A message was sent to your email address. Please check your email for further instructions.
+
+
+ Please enter the verification code we sent to your phone. If you didn't receive a code, you can {0}.
+
+
+ Webdav portal user request.
+
+
+ Your password have been successfully changed
+
+
+ Password should contain at least {0} non-alphanumeric symbols
+
+
+ Password should contain at least {0} UPPERCASE characters
+
+
+ Phone number is invalid
+
+
+ {0} field is required
+
+
+ Text message (SMS) was not sent to your mobile phone. Invalid phone number.
+
+
+ Text message (SMS) was sent to your mobile phone.
+
+
+ Url is invalid
+
+
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.Designer.cs b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.Designer.cs
index f9a6db66..2be5ffa9 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.Designer.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.Designer.cs
@@ -69,6 +69,42 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Address.
+ ///
+ public static string Address {
+ get {
+ return ResourceManager.GetString("Address", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Address Inforamtion.
+ ///
+ public static string AddressInforamtion {
+ get {
+ return ResourceManager.GetString("AddressInforamtion", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Back.
+ ///
+ public static string Back {
+ get {
+ return ResourceManager.GetString("Back", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Business Phone.
+ ///
+ public static string BusinessPhone {
+ get {
+ return ResourceManager.GetString("BusinessPhone", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Byte.
///
@@ -105,6 +141,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Change password.
+ ///
+ public static string ChangePassword {
+ get {
+ return ResourceManager.GetString("ChangePassword", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to City.
+ ///
+ public static string City {
+ get {
+ return ResourceManager.GetString("City", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Close.
///
@@ -114,6 +168,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Company Information.
+ ///
+ public static string CompanyInformation {
+ get {
+ return ResourceManager.GetString("CompanyInformation", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Confirm.
///
@@ -123,6 +186,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Contact Information.
+ ///
+ public static string ContactInformation {
+ get {
+ return ResourceManager.GetString("ContactInformation", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Country/Region.
+ ///
+ public static string Country {
+ get {
+ return ResourceManager.GetString("Country", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Create.
///
@@ -168,6 +249,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Display Name.
+ ///
+ public static string DisplayName {
+ get {
+ return ResourceManager.GetString("DisplayName", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Email.
+ ///
+ public static string Email {
+ get {
+ return ResourceManager.GetString("Email", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Please enter file name.
///
@@ -204,6 +303,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to External Email.
+ ///
+ public static string ExternalEmail {
+ get {
+ return ResourceManager.GetString("ExternalEmail", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Fax.
+ ///
+ public static string Fax {
+ get {
+ return ResourceManager.GetString("Fax", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to File.
///
@@ -231,6 +348,33 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to First Name.
+ ///
+ public static string FirstName {
+ get {
+ return ResourceManager.GetString("FirstName", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Forgot your password?.
+ ///
+ public static string ForgotYourPassword {
+ get {
+ return ResourceManager.GetString("ForgotYourPassword", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to General Information.
+ ///
+ public static string GeneralInformation {
+ get {
+ return ResourceManager.GetString("GeneralInformation", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Gb.
///
@@ -240,6 +384,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Here.
+ ///
+ public static string Here {
+ get {
+ return ResourceManager.GetString("Here", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Home Phone.
+ ///
+ public static string HomePhone {
+ get {
+ return ResourceManager.GetString("HomePhone", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Info.
///
@@ -249,6 +411,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Initials.
+ ///
+ public static string Initials {
+ get {
+ return ResourceManager.GetString("Initials", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to File already exist.
///
@@ -267,6 +438,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Job Title.
+ ///
+ public static string JobTitle {
+ get {
+ return ResourceManager.GetString("JobTitle", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to KB.
///
@@ -276,6 +456,42 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Last Name.
+ ///
+ public static string LastName {
+ get {
+ return ResourceManager.GetString("LastName", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Login.
+ ///
+ public static string Login {
+ get {
+ return ResourceManager.GetString("Login", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Login name.
+ ///
+ public static string LoginName {
+ get {
+ return ResourceManager.GetString("LoginName", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Log out.
+ ///
+ public static string LogOut {
+ get {
+ return ResourceManager.GetString("LogOut", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to MB.
///
@@ -285,6 +501,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Mobile Phone.
+ ///
+ public static string MobilePhone {
+ get {
+ return ResourceManager.GetString("MobilePhone", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Modified.
///
@@ -303,6 +528,33 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to New password.
+ ///
+ public static string NewPassword {
+ get {
+ return ResourceManager.GetString("NewPassword", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Confirm password.
+ ///
+ public static string NewPasswordConfirmation {
+ get {
+ return ResourceManager.GetString("NewPasswordConfirmation", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Next.
+ ///
+ public static string Next {
+ get {
+ return ResourceManager.GetString("Next", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to No files are selected..
///
@@ -321,6 +573,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Notes.
+ ///
+ public static string Notes {
+ get {
+ return ResourceManager.GetString("Notes", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Old password.
+ ///
+ public static string OldPassword {
+ get {
+ return ResourceManager.GetString("OldPassword", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to or drag and drop files here..
///
@@ -330,6 +600,51 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Pager.
+ ///
+ public static string Pager {
+ get {
+ return ResourceManager.GetString("Pager", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Password.
+ ///
+ public static string Password {
+ get {
+ return ResourceManager.GetString("Password", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Will expire on {0}. If you want to change password then please click {1}..
+ ///
+ public static string PasswordExpirationFormat {
+ get {
+ return ResourceManager.GetString("PasswordExpirationFormat", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Password reset.
+ ///
+ public static string PasswordReset {
+ get {
+ return ResourceManager.GetString("PasswordReset", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Enter your login and password reset email will be sent to your email address. You may need to check your spam folder..
+ ///
+ public static string PasswordResetEmailInfo {
+ get {
+ return ResourceManager.GetString("PasswordResetEmailInfo", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to PB.
///
@@ -357,6 +672,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Primary Email.
+ ///
+ public static string PrimaryEmail {
+ get {
+ return ResourceManager.GetString("PrimaryEmail", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Processing.
///
@@ -375,6 +699,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Profile.
+ ///
+ public static string Profile {
+ get {
+ return ResourceManager.GetString("Profile", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Save Changes.
+ ///
+ public static string SaveChanges {
+ get {
+ return ResourceManager.GetString("SaveChanges", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Search.
///
@@ -402,6 +744,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Select.
+ ///
+ public static string Select {
+ get {
+ return ResourceManager.GetString("Select", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Select files to upload.
///
@@ -411,6 +762,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Send email.
+ ///
+ public static string SendEmail {
+ get {
+ return ResourceManager.GetString("SendEmail", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Size.
///
@@ -420,6 +780,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Sms.
+ ///
+ public static string Sms {
+ get {
+ return ResourceManager.GetString("Sms", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to State/Province.
+ ///
+ public static string State {
+ get {
+ return ResourceManager.GetString("State", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Table.
///
@@ -438,6 +816,15 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to Try again.
+ ///
+ public static string TryAgain {
+ get {
+ return ResourceManager.GetString("TryAgain", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Type.
///
@@ -456,6 +843,24 @@ namespace WebsitePanel.WebDavPortal.Resources {
}
}
+ ///
+ /// Looks up a localized string similar to User profile successfully updated.
+ ///
+ public static string UserProfileSuccessfullyUpdated {
+ get {
+ return ResourceManager.GetString("UserProfileSuccessfullyUpdated", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Web Page.
+ ///
+ public static string WebPage {
+ get {
+ return ResourceManager.GetString("WebPage", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Word document.
///
@@ -473,5 +878,14 @@ namespace WebsitePanel.WebDavPortal.Resources {
return ResourceManager.GetString("Yes", resourceCulture);
}
}
+
+ ///
+ /// Looks up a localized string similar to Zip/Postal Code.
+ ///
+ public static string Zip {
+ get {
+ return ResourceManager.GetString("Zip", resourceCulture);
+ }
+ }
}
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.resx b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.resx
index 56929bcc..4a6fca4c 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.resx
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Resources/UI.resx
@@ -120,6 +120,18 @@
Actions
+
+ Address
+
+
+ Address Inforamtion
+
+
+ Back
+
+
+ Business Phone
+
Byte
@@ -132,12 +144,27 @@
Cancel All
+
+ Change password
+
+
+ City
+
Close
+
+ Company Information
+
Confirm
+
+ Contact Information
+
+
+ Country/Region
+
Create
@@ -153,6 +180,12 @@
Are you sure you want to delete {0} item(s)?
+
+ Display Name
+
+
+ Email
+
Please enter file name
@@ -165,6 +198,12 @@
Excel workbook
+
+ External Email
+
+
+ Fax
+
File
@@ -174,39 +213,99 @@
File Upload
+
+ First Name
+
+
+ Forgot your password?
+
+
+ General Information
+
Gb
+
+ Here
+
+
+ Home Phone
+
Info
+
+ Initials
+
File already exist
{0} items was removed.
+
+ Job Title
+
KB
+
+ Last Name
+
+
+ Login name
+
+
+ Log out
+
MB
+
+ Mobile Phone
+
Modified
Name
+
+ New password
+
+
+ Confirm password
+
+
+ Next
+
No files are selected.
Not a file.
+
+ Notes
+
+
+ Old password
+
or drag and drop files here.
+
+ Pager
+
+
+ Password
+
+
+ Will expire on {0}. If you want to change password then please click {1}.
+
+
+ Password reset
+
PB
@@ -216,12 +315,21 @@
Powerpoint presentation
+
+ Primary Email
+
Processing
Processing...
+
+ Profile
+
+
+ Save Changes
+
Search
@@ -231,12 +339,24 @@
Search Results
+
+ Select
+
Select files to upload
+
+ Send email
+
Size
+
+ Sms
+
+
+ State/Province
+
Table
@@ -249,10 +369,28 @@
Upload
+
+ User profile successfully updated
+
+
+ Web Page
+
Word document
Yes
+
+ Zip/Postal Code
+
+
+ Enter your login and password reset email will be sent to your email address. You may need to check your spam folder.
+
+
+ Try again
+
+
+ Login
+
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/_references.js b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/_references.js
index 7a771e40..2a5be867 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/_references.js
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/_references.js
@@ -1,8 +1,9 @@
-///
-///
+///
///
///
+///
///
+///
///
///
///
@@ -10,5 +11,36 @@
///
///
///
+///
+///
+///
///
///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
+///
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/appScripts/validation/passwordeditor.unobtrusive.js b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/appScripts/validation/passwordeditor.unobtrusive.js
new file mode 100644
index 00000000..799b8f82
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/appScripts/validation/passwordeditor.unobtrusive.js
@@ -0,0 +1,54 @@
+///
+///
+
+
+$.validator.unobtrusive.adapters.addSingleVal("minimumlength", "count");
+
+$.validator.addMethod("minimumlength", function (value, element, count) {
+ if (value.length < count) {
+ return false;
+ }
+
+ return true;
+});
+
+$.validator.unobtrusive.adapters.addSingleVal("maximumlength", "count");
+
+$.validator.addMethod("maximumlength", function (value, element, count) {
+ if (value.length > count) {
+ return false;
+ }
+
+ return true;
+});
+
+$.validator.unobtrusive.adapters.addSingleVal("uppercasecount", "count");
+
+$.validator.addMethod("uppercasecount", function (value, element, count) {
+ if (value.replace(/[^A-Z]/g, "").length < count) {
+ return false;
+ }
+
+ return true;
+});
+
+$.validator.unobtrusive.adapters.addSingleVal("numberscount", "count");
+
+$.validator.addMethod("numberscount", function (value, element, count) {
+ if (value.replace(/[^0-9]/g, "").length < count) {
+ return false;
+ }
+
+ return true;
+});
+
+$.validator.unobtrusive.adapters.addSingleVal("symbolscount", "count");
+
+$.validator.addMethod("symbolscount", function (value, element, count) {
+ if (value.replace(/[a-zA-Z0-9_]/g, "").length < count) {
+
+ return false;
+ }
+
+ return true;
+});
\ No newline at end of file
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/appScripts/wsp.js b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/appScripts/wsp.js
index a45da0f1..96a4a5ff 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/appScripts/wsp.js
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Scripts/appScripts/wsp.js
@@ -10,25 +10,11 @@ $(document).on('click', '.processing-dialog', function (e) {
});
-$(document).ready(function() {
+$(document).ready(function () {
+
//bootstrap jquery validate styles fix
- $.validator.setDefaults({
- highlight: function(element) {
- $(element).closest('.form-group').addClass('has-error');
- },
- unhighlight: function(element) {
- $(element).closest('.form-group').removeClass('has-error');
- },
- errorElement: 'span',
- errorClass: 'help-block',
- errorPlacement: function(error, element) {
- if (element.parent('.input-group').length) {
- error.insertAfter(element.parent());
- } else {
- error.insertAfter(element);
- }
- }
- });
+ BindBootstrapValidationStyles();
+
$.validator.addMethod("synchronousRemote", function(value, element, param) {
if (this.optional(element)) {
@@ -86,6 +72,60 @@ $(document).ready(function() {
}, "Please fix this field.");
});
+function BindBootstrapValidationStyles() {
+ $.validator.setDefaults({
+ highlight: function (element) {
+ $(element).closest('.form-group').addClass('has-error');
+ },
+ unhighlight: function (element) {
+ $(element).closest('.form-group').removeClass('has-error');
+ },
+ errorElement: 'span',
+ errorClass: 'help-block',
+ errorPlacement: function (error, element) {
+ if (element.parent('.input-group').length) {
+ error.insertAfter(element.parent());
+ } else {
+ error.insertAfter(element);
+ }
+ }
+ });
+
+ $('.bs-val-styles').each(function () {
+ var form = $(this);
+ var formData = $.data(form[0]);
+ if (formData && formData.validator) {
+
+ var settings = formData.validator.settings;
+ // Store existing event handlers in local variables
+ var oldErrorPlacement = settings.errorPlacement;
+ var oldSuccess = settings.success;
+
+ settings.errorPlacement = function (label, element) {
+
+ oldErrorPlacement(label, element);
+
+ element.closest('.form-group').addClass('has-error');
+ label.addClass('text-danger');
+ };
+
+ settings.success = function (label, element) {
+ $(element).closest('.form-group').removeClass('has-error');
+
+ oldSuccess(label);
+ }
+ }
+ });
+
+ $('.input-validation-error').each(function () {
+ $(this).closest('.form-group').addClass('has-error');
+ });
+
+ $('.field-validation-error').each(function () {
+ $(this).addClass('text-danger');
+ });
+}
+
$.fn.clearValidation = function () { var v = $(this).validate(); $('[name]', this).each(function () { v.successList.push(this); v.showErrors(); }); v.resetForm(); v.reset(); $(this).find('.form-group').removeClass('has-error'); };
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/Login.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/Login.cshtml
index c7c827b8..23aaf2f0 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/Login.cshtml
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/Login.cshtml
@@ -1,11 +1,15 @@
-@model WebsitePanel.WebDavPortal.Models.AccountModel
+@using WebsitePanel.WebDavPortal.Resources
+@using WebsitePanel.WebDavPortal.UI.Routes
+@model WebsitePanel.WebDavPortal.Models.AccountModel
@{
ViewBag.Title = "Login";
+ //Layout = "~/Views/Shared/_Layout.cshtml";
}
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordChange.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordChange.cshtml
new file mode 100644
index 00000000..1e9afbc5
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordChange.cshtml
@@ -0,0 +1,31 @@
+@using WebsitePanel.WebDavPortal.Resources
+@using WebsitePanel.WebDavPortal.UI.Routes
+@model WebsitePanel.WebDavPortal.Models.Account.PasswordChangeModel
+
+@{
+ Layout = "~/Views/Shared/_Layout.cshtml";
+}
+
+ @using (Html.BeginRouteForm(AccountRouteNames.PasswordChange, FormMethod.Post, new { @class = "form-horizontal user-password-change bs-val-styles col-lg-10 col-lg-offset-3", id = "user-password-change" }))
+ {
+
+
@UI.ChangePassword
+
+
+
+ @Html.EditorFor(x=>x.PasswordEditor)
+
+
+ }
+
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetEmail.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetEmail.cshtml
new file mode 100644
index 00000000..fca5271d
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetEmail.cshtml
@@ -0,0 +1,23 @@
+@using WebsitePanel.WebDavPortal.Resources
+@using WebsitePanel.WebDavPortal.UI.Routes
+@model WebsitePanel.WebDavPortal.Models.Account.PasswordResetEmailModel
+
+@{
+ Layout = "~/Views/Shared/_Layout.cshtml";
+}
+
+
+
+ @using (Html.BeginRouteForm(AccountRouteNames.PasswordResetEmail, FormMethod.Post, new { @class = "user-password-reset-email bs-val-styles col-lg-10 col-lg-offset-3", id = "user-password-reset" }))
+ {
+
+
@UI.PasswordReset
+
+
+ @UI.PasswordResetEmailInfo
+ @Html.TextBoxFor(x => x.Email, new { @class = "form-control", placeholder = UI.Login })
+ @Html.ValidationMessageFor(x => x.Email)
+
+
@UI.SendEmail
+ }
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetEmailSent.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetEmailSent.cshtml
new file mode 100644
index 00000000..f67ded08
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetEmailSent.cshtml
@@ -0,0 +1,18 @@
+@using WebsitePanel.WebDavPortal.Resources
+
+@{
+ Layout = "~/Views/Shared/_Layout.cshtml";
+}
+
+
+
+
+
+
@UI.PasswordReset
+
+
+ @Messages.PasswordResetEmailSent
+
+
+
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetFinalStep.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetFinalStep.cshtml
new file mode 100644
index 00000000..11fbfbfc
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetFinalStep.cshtml
@@ -0,0 +1,27 @@
+@{
+ Layout = "~/Views/Shared/_Layout.cshtml";
+}
+@using WebsitePanel.WebDavPortal.Resources
+@using WebsitePanel.WebDavPortal.UI.Routes
+@model WebsitePanel.WebDavPortal.Models.Common.EditorTemplates.PasswordEditor
+
+
+ @using (Html.BeginRouteForm(AccountRouteNames.PasswordResetFinalStep, FormMethod.Post, new { @class = "form-horizontal user-password-reset-final-step bs-val-styles col-lg-9 col-lg-offset-3", id = "user-password-reset" }))
+ {
+
+
+
@UI.PasswordReset
+
+
+ @Html.EditorFor(x=>x)
+
+
+ }
+
+
+
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetSms.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetSms.cshtml
new file mode 100644
index 00000000..ca9a955f
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/PasswordResetSms.cshtml
@@ -0,0 +1,30 @@
+@using WebsitePanel.WebDavPortal.Resources
+@using WebsitePanel.WebDavPortal.UI.Routes
+@model WebsitePanel.WebDavPortal.Models.Account.PasswordResetSmsModel
+
+@{
+ Layout = "~/Views/Shared/_Layout.cshtml";
+}
+
+@if (Model.IsTokenExist)
+{
+
+ @using (Html.BeginRouteForm(AccountRouteNames.PasswordResetSms, FormMethod.Post, new {@class = "user-password-reset-sms bs-val-styles col-lg-9 col-lg-offset-3", id = "user-password-reset"}))
+ {
+ @Html.HiddenFor(x=>x.IsTokenExist)
+
+
+
@UI.PasswordReset
+
+
+
@UI.Next
+ }
+
+}
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/UserProfile.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/UserProfile.cshtml
new file mode 100644
index 00000000..e1c27a7c
--- /dev/null
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/Account/UserProfile.cshtml
@@ -0,0 +1,225 @@
+@using WebsitePanel.WebDavPortal.Constants
+@using WebsitePanel.WebDavPortal.Resources
+@using WebsitePanel.WebDavPortal.UI.Routes
+@model WebsitePanel.WebDavPortal.Models.Account.UserProfile
+
+@{
+ Layout = "~/Views/Shared/_Layout.cshtml";
+
+ var passwordExpriationText = string.Format(UI.PasswordExpirationFormat, Model.PasswordExpirationDateTime.ToString(Formats.DateFormatWithTime), Html.RouteLink(UI.Here.ToLowerInvariant(), AccountRouteNames.PasswordChange));
+}
+
+
+ @using (Html.BeginRouteForm(AccountRouteNames.UserProfile, FormMethod.Post, new { @class = "form-horizontal user-profile bs-val-styles", id = "user-profile-form" }))
+ {
+ @Html.HiddenFor(x => x.PasswordExpirationDateTime)
+ @Html.HiddenFor(x => x.PrimaryEmailAddress)
+ @Html.AntiForgeryToken()
+
+ if (ViewData.ModelState.Any(x => x.Value.Errors.Any()))
+ {
+
+
×
+ @Html.ValidationSummary(false)
+
+ }
+
+
+
+
+ }
+
+
+ @section scripts{
+
+ }
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/FileSystem/_ShowContentTable.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/FileSystem/_ShowContentTable.cshtml
index a729ca02..8b916ab0 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/FileSystem/_ShowContentTable.cshtml
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/FileSystem/_ShowContentTable.cshtml
@@ -3,7 +3,7 @@
@model WebsitePanel.WebDavPortal.Models.ModelForWebDav
-
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/FileSystem/_ShowContentTopMenu.cshtml b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/FileSystem/_ShowContentTopMenu.cshtml
index b749eee1..6b8da329 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/FileSystem/_ShowContentTopMenu.cshtml
+++ b/WebsitePanel/Sources/WebsitePanel.WebDavPortal/Views/FileSystem/_ShowContentTopMenu.cshtml
@@ -6,7 +6,7 @@
@model WebsitePanel.WebDavPortal.Models.ModelForWebDav
-
+
@if (Model != null)
{
string header = WspContext.User.OrganizationId;
@@ -48,7 +48,7 @@
@if (string.IsNullOrEmpty(Model.SearchValue))
{
-
+
+
+
+
+