This commit is contained in:
Haya Nmeir 2012-09-19 03:51:19 +03:00
commit ec856b89f2
120 changed files with 2867 additions and 841 deletions

View file

@ -323,10 +323,14 @@ namespace WebsitePanel.Setup.Actions
serviceInfo.Comments = string.Empty;
//check IIS version
if (ServerSetup.IISVersion.Major >= 7)
if (ServerSetup.IISVersion.Major == 7)
{
serviceInfo.ProviderId = 101;
}
else if (ServerSetup.IISVersion.Major == 8)
{
serviceInfo.ProviderId = 105;
}
else if (ServerSetup.IISVersion.Major == 6)
{
serviceInfo.ProviderId = 2;

View file

@ -31,6 +31,7 @@ using System.Collections.Generic;
using System.Text;
using System.IO;
using System.Xml;
using WebsitePanel.Setup.Common;
namespace WebsitePanel.Setup.Actions
{
@ -114,6 +115,55 @@ namespace WebsitePanel.Setup.Actions
}
}
public class GenerateSessionValidationKeyAction : Action, IInstallAction
{
public const string LogStartInstallMessage = "Generating session validation key...";
void IInstallAction.Run(SetupVariables vars)
{
try
{
Begin(LogStartInstallMessage);
Log.WriteStart(LogStartInstallMessage);
string path = Path.Combine(vars.InstallationFolder, "web.config");
if (!File.Exists(path))
{
Log.WriteInfo(string.Format("File {0} not found", path));
return;
}
Log.WriteStart("Updating configuration file (session validation key)");
XmlDocument doc = new XmlDocument();
doc.Load(path);
XmlElement sessionKey = doc.SelectSingleNode("configuration/appSettings/add[@key='SessionValidationKey']") as XmlElement;
if (sessionKey == null)
{
Log.WriteInfo("SessionValidationKey setting not found");
return;
}
sessionKey.SetAttribute("value", StringUtils.GenerateRandomString(16));
doc.Save(path);
Log.WriteEnd("Generated session validation key");
InstallLog.AppendLine("- Generated session validation key");
}
catch (Exception ex)
{
if (Utils.IsThreadAbortException(ex))
return;
//
Log.WriteError("Site settigs error", ex);
//
throw;
}
}
}
public class CreateDesktopShortcutsAction : Action, IInstallAction
{
public const string LogStartInstallMessage = "Creating shortcut...";
@ -253,6 +303,7 @@ namespace WebsitePanel.Setup.Actions
new CreateWebSiteAction(),
new SwitchAppPoolAspNetVersion(),
new UpdateEnterpriseServerUrlAction(),
new GenerateSessionValidationKeyAction(),
new SaveComponentConfigSettingsAction(),
new CreateDesktopShortcutsAction()
};

View file

@ -88,6 +88,7 @@ namespace WebsitePanel.Setup
SwitchServer2AspNet40,
SwitchEntServer2AspNet40,
SwitchWebPortal2AspNet40,
ConfigureSecureSessionModuleInWebConfig
}
public class InstallAction

View file

@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Security.Cryptography;
using System.Text;
namespace WebsitePanel.Setup.Common
{
public class StringUtils
{
public static string GenerateRandomString(int length)
{
RNGCryptoServiceProvider crypto = new RNGCryptoServiceProvider();
byte[] data = new byte[length];
crypto.GetNonZeroBytes(data);
return BitConverter.ToString(data).Replace("-", "").ToLowerInvariant();
}
}
}

View file

@ -7,32 +7,6 @@ using WebsitePanel.Setup.Actions;
namespace WebsitePanel.Setup
{
/// <summary>
/// Release 1.2.2
/// </summary>
public class EnterpriseServer122 : EnterpriseServer
{
public static new object Install(object obj)
{
//
return EnterpriseServer.InstallBase(obj, "1.2.2");
}
public static new DialogResult Uninstall(object obj)
{
return EnterpriseServer.Uninstall(obj);
}
public static new DialogResult Setup(object obj)
{
return EnterpriseServer.Setup(obj);
}
public static new DialogResult Update(object obj)
{
return UpdateBase(obj, "1.2.2", "1.2.1", true);
}
}
/// <summary>
/// Release 1.2.1
/// </summary>

View file

@ -0,0 +1,38 @@
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;
using WebsitePanel.Setup.Actions;
namespace WebsitePanel.Setup
{
/// <summary>
/// Release 2.0.0
/// </summary>
public class EnterpriseServer200 : EnterpriseServer
{
public static new object Install(object obj)
{
//
return EnterpriseServer.InstallBase(obj, minimalInstallerVersion: "2.0.0");
}
public static new DialogResult Uninstall(object obj)
{
return EnterpriseServer.Uninstall(obj);
}
public static new DialogResult Setup(object obj)
{
return EnterpriseServer.Setup(obj);
}
public static new DialogResult Update(object obj)
{
return UpdateBase(obj,
minimalInstallerVersion: "2.0.0",
versionToUpgrade: "1.2.1",
updateSql: true);
}
}
}

View file

@ -6,33 +6,6 @@ using WebsitePanel.Setup.Actions;
namespace WebsitePanel.Setup
{
/// <summary>
/// Release 1.2.2
/// </summary>
public class Portal122 : Portal
{
public static new object Install(object obj)
{
//
return Portal.InstallBase(obj, "1.2.2");
}
public static new DialogResult Uninstall(object obj)
{
return Portal.Uninstall(obj);
}
public static new DialogResult Setup(object obj)
{
return Portal.Setup(obj);
}
public static new DialogResult Update(object obj)
{
return UpdateBase(obj, "1.2.2", "1.2.1", false);
}
}
/// <summary>
/// Release 1.2.1
/// </summary>

View file

@ -0,0 +1,39 @@
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;
using WebsitePanel.Setup.Actions;
namespace WebsitePanel.Setup
{
/// <summary>
/// Release 2.0.0
/// </summary>
public class Portal200 : Portal
{
public static new object Install(object obj)
{
//
return Portal.InstallBase(obj, minimalInstallerVersion: "2.0.0");
}
public static new DialogResult Uninstall(object obj)
{
return Portal.Uninstall(obj);
}
public static new DialogResult Setup(object obj)
{
return Portal.Setup(obj);
}
public static new DialogResult Update(object obj)
{
return UpdateBase(obj,
minimalInstallerVersion: "2.0.0",
versionsToUpgrade: "1.2.1",
updateSql: false,
versionSpecificAction: new InstallAction(ActionTypes.ConfigureSecureSessionModuleInWebConfig));
}
}
}

View file

@ -6,33 +6,6 @@ using WebsitePanel.Setup.Actions;
namespace WebsitePanel.Setup
{
/// <summary>
/// Release 1.2.2
/// </summary>
public class Server122 : Server
{
public static new object Install(object obj)
{
//
return Server.InstallBase(obj, "1.2.2");
}
public static new object Uninstall(object obj)
{
return Server.Uninstall(obj);
}
public static new object Setup(object obj)
{
return Server.Setup(obj);
}
public static new object Update(object obj)
{
return Server.UpdateBase(obj, "1.2.2", "1.2.1", false);
}
}
/// <summary>
/// Release 1.2.1
/// </summary>

View file

@ -0,0 +1,37 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace WebsitePanel.Setup
{
/// <summary>
/// Release 2.0.0
/// </summary>
public class Server200 : Server
{
public static new object Install(object obj)
{
//
return Server.InstallBase(obj, minimalInstallerVersion: "2.0.0");
}
public static new object Uninstall(object obj)
{
return Server.Uninstall(obj);
}
public static new object Setup(object obj)
{
return Server.Setup(obj);
}
public static new object Update(object obj)
{
return Server.UpdateBase(obj,
minimalInstallerVersion: "2.0.0",
versionToUpgrade: "1.2.1",
updateSql: false);
}
}
}

View file

@ -5,18 +5,6 @@ using System.Windows.Forms;
namespace WebsitePanel.Setup
{
/// <summary>
/// Release 1.2.2
/// </summary>
public class StandaloneServerSetup122 : StandaloneServerSetup
{
public static new object Install(object obj)
{
return StandaloneServerSetup.InstallBase(obj, "1.2.2");
}
}
/// <summary>
/// Release 1.2.1
/// </summary>

View file

@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.Text;
using System.Windows.Forms;
namespace WebsitePanel.Setup
{
/// <summary>
/// Release 2.0.0
/// </summary>
public class StandaloneServerSetup200 : StandaloneServerSetup
{
public static new object Install(object obj)
{
return StandaloneServerSetup.InstallBase(obj, minimalInstallerVersion: "2.0.0");
}
}
}

View file

@ -133,6 +133,7 @@
<Compile Include="Common\SqlProcess.cs" />
<Compile Include="Common\SqlUtils.cs" />
<Compile Include="Common\ServerItem.cs" />
<Compile Include="Common\StringUtils.cs" />
<Compile Include="Common\Utils.cs" />
<Compile Include="Common\WebException.cs" />
<Compile Include="Common\WebUtils.cs" />
@ -140,8 +141,11 @@
<Compile Include="Common\XmlUtils.cs" />
<Compile Include="Common\ZipIndicator.cs" />
<Compile Include="EnterpriseServer10.cs" />
<Compile Include="EnterpriseServer20.cs" />
<Compile Include="Portal10.cs" />
<Compile Include="Portal20.cs" />
<Compile Include="Server10.cs" />
<Compile Include="Server20.cs" />
<Compile Include="StandaloneServerSetup.cs" />
<Compile Include="EnterpriseServer.cs" />
<Compile Include="Portal.cs" />
@ -160,6 +164,7 @@
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<Compile Include="StandaloneServerSetup10.cs" />
<Compile Include="StandaloneServerSetup20.cs" />
<Compile Include="Web\AspNetVersion.cs" />
<Compile Include="Web\ServerBinding.cs" />
<Compile Include="Web\ServerState.cs" />

View file

@ -258,6 +258,9 @@ namespace WebsitePanel.Setup
case ActionTypes.AddCustomErrorsPage:
AddCustomErrorsPage();
break;
case ActionTypes.ConfigureSecureSessionModuleInWebConfig:
ConfigureSecureSessionModuleInWebConfig();
break;
}
}
this.progressBar.Value = 100;
@ -281,6 +284,87 @@ namespace WebsitePanel.Setup
Wizard.GoNext();
}
private void ConfigureSecureSessionModuleInWebConfig()
{
try
{
string webConfigPath = Path.Combine(Wizard.SetupVariables.InstallationFolder, "web.config");
Log.WriteStart("Web.config file is being updated");
// Ensure the web.config exists
if (!File.Exists(webConfigPath))
{
Log.WriteInfo(string.Format("File {0} not found", webConfigPath));
return;
}
// Load web.config
XmlDocument doc = new XmlDocument();
doc.Load(webConfigPath);
// add node:
//<system.webServer>
// <modules>
// <add name="SecureSession" type="WebsitePanel.WebPortal.SecureSessionModule" />
// </modules>
//</system.webServer>
//
// ... or for IIS 6:
//
//<system.web>
// <httpModules>
// <add name="SecureSession" type="WebsitePanel.WebPortal.SecureSessionModule" />
// </httpModules>
//</system.web>
bool iis6 = false;
XmlElement webServer = doc.SelectSingleNode("configuration/system.webServer") as XmlElement;
if (webServer == null)
{
// this is IIS 6
webServer = doc.SelectSingleNode("configuration/system.web") as XmlElement;
iis6 = true;
}
if (webServer != null)
{
var modules = doc.CreateElement(iis6 ? "httpModules" : "modules");
webServer.AppendChild(modules);
var sessionModule = doc.CreateElement("add");
sessionModule.SetAttribute("name", "SecureSession");
sessionModule.SetAttribute("type", "WebsitePanel.WebPortal.SecureSessionModule");
modules.AppendChild(sessionModule);
}
// update /system.web/httpRuntime element
var httpRuntime = doc.SelectSingleNode("configuration/system.web/httpRuntime") as XmlElement;
if (httpRuntime != null)
httpRuntime.SetAttribute("enableVersionHeader", "false");
// add:
//<appSettings>
// <add key="SessionValidationKey" value="XXXXXX" />
//</appSettings>
var appSettings = doc.SelectSingleNode("configuration/appSettings");
if (appSettings != null)
{
var sessionKey = doc.CreateElement("add");
sessionKey.SetAttribute("name", "SessionValidationKey");
sessionKey.SetAttribute("value", StringUtils.GenerateRandomString(16));
appSettings.AppendChild(sessionKey);
}
// save changes have been made
doc.Save(webConfigPath);
//
Log.WriteEnd("Web.config has been updated");
}
catch (Exception ex)
{
if (Utils.IsThreadAbortException(ex))
return;
Log.WriteError("Could not update web.config file", ex);
throw;
}
}
private void SwitchWebPortal2AspNet40(InstallAction action, Setup.SetupVariables setupVariables)
{
var sam = new WebPortalActionManager(setupVariables);

View file

@ -6508,6 +6508,7 @@ CREATE TABLE [dbo].[ExchangeOrganizationDomains](
[ItemID] [int] NOT NULL,
[DomainID] [int] NULL,
[IsHost] [bit] NULL,
[DomainTypeID] [int] NOT NULL,
CONSTRAINT [PK_ExchangeOrganizationDomains] PRIMARY KEY CLUSTERED
(
[OrganizationDomainID] ASC
@ -6634,7 +6635,8 @@ AS
SELECT
ED.DomainID,
D.DomainName,
ED.IsHost
ED.IsHost,
ED.DomainTypeID
FROM
ExchangeOrganizationDomains AS ED
INNER JOIN Domains AS D ON ED.DomainID = D.DomainID
@ -45799,6 +45801,29 @@ GO
CREATE PROCEDURE [dbo].ChangeExchangeAcceptedDomainType
(
@ItemID int,
@DomainID int,
@DomainTypeID int
)
AS
UPDATE ExchangeOrganizationDomains
SET DomainTypeID=@DomainTypeID
WHERE ItemID=ItemID AND DomainID=@DomainID
RETURN
GO
@ -46064,6 +46089,8 @@ ALTER TABLE [dbo].[ExchangeOrganizationDomains] CHECK CONSTRAINT [FK_ExchangeOrg
GO
ALTER TABLE [dbo].[ExchangeOrganizationDomains] ADD CONSTRAINT [DF_ExchangeOrganizationDomains_IsHost] DEFAULT ((0)) FOR [IsHost]
GO
ALTER TABLE [dbo].[ExchangeOrganizationDomains] ADD CONSTRAINT [DF_ExchangeOrganizationDomains_DomainTypeID] DEFAULT ((0)) FOR [DomainTypeID]
GO
ALTER TABLE [dbo].[PrivateIPAddresses] WITH CHECK ADD CONSTRAINT [FK_PrivateIPAddresses_ServiceItems] FOREIGN KEY([ItemID])
REFERENCES [dbo].[ServiceItems] ([ItemID])
ON DELETE CASCADE

View file

@ -29,7 +29,7 @@ GO
-- IIS 8.0
IF NOT EXISTS (SELECT * FROM [dbo].[Providers] WHERE [DisplayName] = 'Internet Information Services 8.0')
BEGIN
INSERT [dbo].[Providers] ([ProviderID], [GroupID], [ProviderName], [DisplayName], [ProviderType], [EditorControl], [DisableAutoDiscovery]) VALUES (105, 2, N'IIS80', N'Internet Information Services 8.0', N'WebsitePanel.Providers.Web.IIs70, WebsitePanel.Providers.Web.IIs70', N'IIS70', NULL)
INSERT [dbo].[Providers] ([ProviderID], [GroupID], [ProviderName], [DisplayName], [ProviderType], [EditorControl], [DisableAutoDiscovery]) VALUES (105, 2, N'IIS80', N'Internet Information Services 8.0', N'WebsitePanel.Providers.Web.IIs80, WebsitePanel.Providers.Web.IIs80', N'IIS70', NULL)
END
GO
@ -168,7 +168,7 @@ GO
-- MS FTP 8.0
IF NOT EXISTS (SELECT * FROM [dbo].[Providers] WHERE [DisplayName] = 'Microsoft FTP Server 8.0')
BEGIN
INSERT [dbo].[Providers] ([ProviderID], [GroupID], [ProviderName], [DisplayName], [ProviderType], [EditorControl], [DisableAutoDiscovery]) VALUES (106, 3, N'MSFTP80', N'Microsoft FTP Server 8.0', N'WebsitePanel.Providers.FTP.MsFTP, WebsitePanel.Providers.FTP.IIs70', N'MSFTP70', NULL)
INSERT [dbo].[Providers] ([ProviderID], [GroupID], [ProviderName], [DisplayName], [ProviderType], [EditorControl], [DisableAutoDiscovery]) VALUES (106, 3, N'MSFTP80', N'Microsoft FTP Server 8.0', N'WebsitePanel.Providers.FTP.MsFTP80, WebsitePanel.Providers.FTP.IIs80', N'MSFTP70', NULL)
END
GO
@ -5211,6 +5211,66 @@ GO
IF NOT EXISTS(select 1 from sys.columns COLS INNER JOIN sys.objects OBJS ON OBJS.object_id=COLS.object_id and OBJS.type='U' AND OBJS.name='ExchangeOrganizationDomains' AND COLS.name='DomainTypeID')
BEGIN
ALTER TABLE [dbo].[ExchangeOrganizationDomains] ADD
[DomainTypeID] [int] NOT NULL CONSTRAINT DF_ExchangeOrganizationDomains_DomainTypeID DEFAULT 0
END
GO
ALTER PROCEDURE [dbo].[GetExchangeOrganizationDomains]
(
@ItemID int
)
AS
SELECT
ED.DomainID,
D.DomainName,
ED.IsHost,
ED.DomainTypeID
FROM
ExchangeOrganizationDomains AS ED
INNER JOIN Domains AS D ON ED.DomainID = D.DomainID
WHERE ED.ItemID = @ItemID
RETURN
GO
IF NOT EXISTS (SELECT * FROM sys.objects WHERE type_desc = N'SQL_STORED_PROCEDURE' AND name = N'ChangeExchangeAcceptedDomainType')
BEGIN
EXEC sp_executesql N'
CREATE PROCEDURE [dbo].ChangeExchangeAcceptedDomainType
(
@ItemID int,
@DomainID int,
@DomainTypeID int
)
AS
UPDATE ExchangeOrganizationDomains
SET DomainTypeID=@DomainTypeID
WHERE ItemID=ItemID AND DomainID=@DomainID
RETURN'
END
GO
ALTER PROCEDURE [dbo].[GetPackages]
(
@ActorID int,

View file

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8" ?>
<?xml version="1.0"?>
<configuration>
<configSections/>
<appSettings>
@ -7,4 +7,4 @@
<add key="enableVerboseLogging" value="false"/>
<add key="blockInternalInterTenantOOF" value="true"/>
</appSettings>
</configuration>
<startup><supportedRuntime version="v2.0.50727"/></startup></configuration>

View file

@ -115,8 +115,8 @@ namespace WSPTransportAgent
foreach (AcceptedDomain domain in server.AcceptedDomains)
{
htAcceptedDomains.Add(domain.ToString(), "1");
WriteLine("\tAccepted Domain: " + domain.ToString());
htAcceptedDomains.Add(domain.ToString().ToLower(), "1");
WriteLine("\tAccepted Domain: " + domain.ToString().ToLower());
}
}
catch (Exception ex)
@ -154,11 +154,14 @@ namespace WSPTransportAgent
{
foreach (EnvelopeRecipient recp in e.MailItem.Recipients)
{
WriteLine("\t\tFrom: " + e.MailItem.Message.From.SmtpAddress.ToString().ToLower());
WriteLine("\t\tTo: " + recp.Address.ToString().ToLower());
if (IsMessageBetweenTenants(e.MailItem.FromAddress.DomainPart.ToLower(), recp.Address.DomainPart.ToLower()))
string[] tmpFrom = e.MailItem.Message.From.SmtpAddress.Split('@');
string[] tmpTo = recp.Address.ToString().Split('@');
if (IsMessageBetweenTenants(tmpFrom[1].ToLower(), tmpTo[1].ToLower()))
{
WriteLine("\t\tMessage routed to domain: " + recp.Address.DomainPart.ToLower() + routingDomain);
RoutingDomain myRoutingDomain = new RoutingDomain(recp.Address.DomainPart.ToLower() + routingDomain);
WriteLine("\t\tMessage routed to domain: " + tmpTo[1].ToLower() + routingDomain);
RoutingDomain myRoutingDomain = new RoutingDomain(tmpTo[1].ToLower() + routingDomain);
RoutingOverride myRoutingOverride = new RoutingOverride(myRoutingDomain, DeliveryQueueDomain.UseOverrideDomain);
source.SetRoutingOverride(recp, myRoutingOverride);
touched = true;
@ -173,13 +176,14 @@ namespace WSPTransportAgent
WriteLine("\t\tOOF From: " + e.MailItem.Message.From.SmtpAddress);
if (e.MailItem.Message.From.SmtpAddress.Contains("@"))
{
string[] tmp = e.MailItem.Message.From.SmtpAddress.Split('@');
string[] tmpFrom = e.MailItem.Message.From.SmtpAddress.Split('@');
foreach (EnvelopeRecipient recp in e.MailItem.Recipients)
{
WriteLine("\t\tTo: " + recp.Address.ToString().ToLower());
if (IsMessageBetweenTenants(tmp[1].ToLower(), recp.Address.DomainPart.ToLower()))
string[] tmpTo = recp.Address.ToString().Split('@');
if (IsMessageBetweenTenants(tmpFrom[1].ToLower(), tmpTo[1].ToLower()))
{
WriteLine("\t\tRemove: " + recp.Address.DomainPart.ToLower());
WriteLine("\t\tRemove: " + tmpTo[1].ToLower());
e.MailItem.Recipients.Remove(recp);
}
}

View file

@ -10,8 +10,9 @@
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>WSPTransportAgent</RootNamespace>
<AssemblyName>WSPTransportAgent</AssemblyName>
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>

View file

@ -1,11 +1,11 @@
Windows Registry Editor Version 5.00
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\eventlog\MEACPTransportAgent]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\eventlog\WSPTransportAgent]
"MaxSize"=dword:00080000
"AutoBackupLogFiles"=dword:00000000
"Retention"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\eventlog\MEACPTransportAgent\MEACPTransportAgent]
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\eventlog\WSPTransportAgent\WSPTransportAgent]
"EventMessageFile"=hex(2):43,00,3a,00,5c,00,57,00,69,00,6e,00,64,00,6f,00,77,\
00,73,00,5c,00,4d,00,69,00,63,00,72,00,6f,00,73,00,6f,00,66,00,74,00,2e,00,\
4e,00,45,00,54,00,5c,00,46,00,72,00,61,00,6d,00,65,00,77,00,6f,00,72,00,6b,\

View file

@ -0,0 +1,13 @@
WSP Transport Agent Installation
================================
Perform the following steps:
A) Copy the files WSPTransportAgent.dll and WSPTransportAgent.dll.config to "C:\Program Files\Microsoft\Exchange Server\V14\Public"
B) Import the WSPTransportAgent.reg to create the event source
C) Use the registry editor and provide the "NETWORK SERVICE" Full Control on the following Key
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\eventlog\WSPTransportAgent
D) Run the following powershell command in the exchange management shell:
Install-TransportAgent "WSPTransportAgent" -TransportAgentFactory WSPTransportAgent.WSPRoutingAgentFactory -AssemblyPath "C:\Program Files\Microsoft\Exchange Server\V14\Public\WSPTransportAgent.dll"
E) Enable-TransportAgent "WSPTransportAgent"
F) Restart-Service MSExchangeTransport

View file

@ -735,6 +735,17 @@ namespace WebsitePanel.EnterpriseServer.HostedSolution {
domainId});
return ((int)(results[0]));
}
/// <remarks/>
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/ChangeOrganizationDomainType", RequestNamespace = "http://tempuri.org/", ResponseNamespace = "http://tempuri.org/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
public int ChangeOrganizationDomainType(int itemId, int domainId, ExchangeAcceptedDomainType newDomainType)
{
object[] results = this.Invoke("ChangeOrganizationDomainType", new object[] {
itemId,
domainId,
newDomainType});
return ((int)(results[0]));
}
/// <remarks/>
public System.IAsyncResult BeginDeleteOrganizationDomain(int itemId, int domainId, System.AsyncCallback callback, object asyncState) {

View file

@ -26,34 +26,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
// Copyright (c) 2012, 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.
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
@ -80,7 +52,7 @@ namespace WebsitePanel.EnterpriseServer {
using WebsitePanel.Providers.Common;
using WebsitePanel.Providers.Web;
using WebsitePanel.Providers.ResultObjects;
/// <remarks/>
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
@ -124,6 +96,10 @@ namespace WebsitePanel.EnterpriseServer {
private System.Threading.SendOrPostCallback DeleteWebSiteOperationCompleted;
private System.Threading.SendOrPostCallback SwitchWebSiteToDedicatedIPOperationCompleted;
private System.Threading.SendOrPostCallback SwitchWebSiteToSharedIPOperationCompleted;
private System.Threading.SendOrPostCallback DeleteVirtualDirectoryOperationCompleted;
private System.Threading.SendOrPostCallback ChangeSiteStateOperationCompleted;
@ -306,6 +282,12 @@ namespace WebsitePanel.EnterpriseServer {
/// <remarks/>
public event DeleteWebSiteCompletedEventHandler DeleteWebSiteCompleted;
/// <remarks/>
public event SwitchWebSiteToDedicatedIPCompletedEventHandler SwitchWebSiteToDedicatedIPCompleted;
/// <remarks/>
public event SwitchWebSiteToSharedIPCompletedEventHandler SwitchWebSiteToSharedIPCompleted;
/// <remarks/>
public event DeleteVirtualDirectoryCompletedEventHandler DeleteVirtualDirectoryCompleted;
@ -855,22 +837,24 @@ namespace WebsitePanel.EnterpriseServer {
/// <remarks/>
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/AddWebSite", 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 int AddWebSite(int packageId, string hostName, int domainId, int ipAddressId) {
public int AddWebSite(int packageId, string hostName, int domainId, int ipAddressId, bool ignoreGlobalDNSZone) {
object[] results = this.Invoke("AddWebSite", new object[] {
packageId,
hostName,
domainId,
ipAddressId});
ipAddressId,
ignoreGlobalDNSZone});
return ((int)(results[0]));
}
/// <remarks/>
public System.IAsyncResult BeginAddWebSite(int packageId, string hostName, int domainId, int ipAddressId, System.AsyncCallback callback, object asyncState) {
public System.IAsyncResult BeginAddWebSite(int packageId, string hostName, int domainId, int ipAddressId, bool ignoreGlobalDNSZone, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("AddWebSite", new object[] {
packageId,
hostName,
domainId,
ipAddressId}, callback, asyncState);
ipAddressId,
ignoreGlobalDNSZone}, callback, asyncState);
}
/// <remarks/>
@ -880,12 +864,12 @@ namespace WebsitePanel.EnterpriseServer {
}
/// <remarks/>
public void AddWebSiteAsync(int packageId, string hostName, int domainId, int ipAddressId) {
this.AddWebSiteAsync(packageId, hostName, domainId, ipAddressId, null);
public void AddWebSiteAsync(int packageId, string hostName, int domainId, int ipAddressId, bool ignoreGlobalDNSZone) {
this.AddWebSiteAsync(packageId, hostName, domainId, ipAddressId, ignoreGlobalDNSZone, null);
}
/// <remarks/>
public void AddWebSiteAsync(int packageId, string hostName, int domainId, int ipAddressId, object userState) {
public void AddWebSiteAsync(int packageId, string hostName, int domainId, int ipAddressId, bool ignoreGlobalDNSZone, object userState) {
if ((this.AddWebSiteOperationCompleted == null)) {
this.AddWebSiteOperationCompleted = new System.Threading.SendOrPostCallback(this.OnAddWebSiteOperationCompleted);
}
@ -893,7 +877,8 @@ namespace WebsitePanel.EnterpriseServer {
packageId,
hostName,
domainId,
ipAddressId}, this.AddWebSiteOperationCompleted, userState);
ipAddressId,
ignoreGlobalDNSZone}, this.AddWebSiteOperationCompleted, userState);
}
private void OnAddWebSiteOperationCompleted(object arg) {
@ -1252,6 +1237,91 @@ namespace WebsitePanel.EnterpriseServer {
}
}
/// <remarks/>
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/SwitchWebSiteToDedicatedIP", 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 int SwitchWebSiteToDedicatedIP(int siteItemId, int ipAddressId) {
object[] results = this.Invoke("SwitchWebSiteToDedicatedIP", new object[] {
siteItemId,
ipAddressId});
return ((int)(results[0]));
}
/// <remarks/>
public System.IAsyncResult BeginSwitchWebSiteToDedicatedIP(int siteItemId, int ipAddressId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("SwitchWebSiteToDedicatedIP", new object[] {
siteItemId,
ipAddressId}, callback, asyncState);
}
/// <remarks/>
public int EndSwitchWebSiteToDedicatedIP(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((int)(results[0]));
}
/// <remarks/>
public void SwitchWebSiteToDedicatedIPAsync(int siteItemId, int ipAddressId) {
this.SwitchWebSiteToDedicatedIPAsync(siteItemId, ipAddressId, null);
}
/// <remarks/>
public void SwitchWebSiteToDedicatedIPAsync(int siteItemId, int ipAddressId, object userState) {
if ((this.SwitchWebSiteToDedicatedIPOperationCompleted == null)) {
this.SwitchWebSiteToDedicatedIPOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSwitchWebSiteToDedicatedIPOperationCompleted);
}
this.InvokeAsync("SwitchWebSiteToDedicatedIP", new object[] {
siteItemId,
ipAddressId}, this.SwitchWebSiteToDedicatedIPOperationCompleted, userState);
}
private void OnSwitchWebSiteToDedicatedIPOperationCompleted(object arg) {
if ((this.SwitchWebSiteToDedicatedIPCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.SwitchWebSiteToDedicatedIPCompleted(this, new SwitchWebSiteToDedicatedIPCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
/// <remarks/>
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/SwitchWebSiteToSharedIP", 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 int SwitchWebSiteToSharedIP(int siteItemId) {
object[] results = this.Invoke("SwitchWebSiteToSharedIP", new object[] {
siteItemId});
return ((int)(results[0]));
}
/// <remarks/>
public System.IAsyncResult BeginSwitchWebSiteToSharedIP(int siteItemId, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("SwitchWebSiteToSharedIP", new object[] {
siteItemId}, callback, asyncState);
}
/// <remarks/>
public int EndSwitchWebSiteToSharedIP(System.IAsyncResult asyncResult) {
object[] results = this.EndInvoke(asyncResult);
return ((int)(results[0]));
}
/// <remarks/>
public void SwitchWebSiteToSharedIPAsync(int siteItemId) {
this.SwitchWebSiteToSharedIPAsync(siteItemId, null);
}
/// <remarks/>
public void SwitchWebSiteToSharedIPAsync(int siteItemId, object userState) {
if ((this.SwitchWebSiteToSharedIPOperationCompleted == null)) {
this.SwitchWebSiteToSharedIPOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSwitchWebSiteToSharedIPOperationCompleted);
}
this.InvokeAsync("SwitchWebSiteToSharedIP", new object[] {
siteItemId}, this.SwitchWebSiteToSharedIPOperationCompleted, userState);
}
private void OnSwitchWebSiteToSharedIPOperationCompleted(object arg) {
if ((this.SwitchWebSiteToSharedIPCompleted != null)) {
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
this.SwitchWebSiteToSharedIPCompleted(this, new SwitchWebSiteToSharedIPCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
}
}
/// <remarks/>
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/DeleteVirtualDirectory", 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 int DeleteVirtualDirectory(int siteItemId, string vdirName) {
@ -4422,6 +4492,58 @@ namespace WebsitePanel.EnterpriseServer {
}
}
/// <remarks/>
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SwitchWebSiteToDedicatedIPCompletedEventHandler(object sender, SwitchWebSiteToDedicatedIPCompletedEventArgs e);
/// <remarks/>
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SwitchWebSiteToDedicatedIPCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
private object[] results;
internal SwitchWebSiteToDedicatedIPCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
base(exception, cancelled, userState) {
this.results = results;
}
/// <remarks/>
public int Result {
get {
this.RaiseExceptionIfNecessary();
return ((int)(this.results[0]));
}
}
}
/// <remarks/>
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void SwitchWebSiteToSharedIPCompletedEventHandler(object sender, SwitchWebSiteToSharedIPCompletedEventArgs e);
/// <remarks/>
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]
public partial class SwitchWebSiteToSharedIPCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
private object[] results;
internal SwitchWebSiteToSharedIPCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
base(exception, cancelled, userState) {
this.results = results;
}
/// <remarks/>
public int Result {
get {
this.RaiseExceptionIfNecessary();
return ((int)(this.results[0]));
}
}
}
/// <remarks/>
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
public delegate void DeleteVirtualDirectoryCompletedEventHandler(object sender, DeleteVirtualDirectoryCompletedEventArgs e);

View file

@ -102,7 +102,6 @@ namespace WebsitePanel.EnterpriseServer
if (allowEmptyValue)
{
if (String.IsNullOrEmpty(str)) return str;
if (String.IsNullOrEmpty(value)) return string.Empty;
}
else
{

View file

@ -33,6 +33,7 @@ using System.Data.SqlClient;
using System.Text.RegularExpressions;
using WebsitePanel.Providers.HostedSolution;
using Microsoft.ApplicationBlocks.Data;
using System.Collections.Generic;
namespace WebsitePanel.EnterpriseServer
{
@ -2152,6 +2153,18 @@ namespace WebsitePanel.EnterpriseServer
);
}
public static void ChangeExchangeAcceptedDomainType(int itemId, int domainId, int domainTypeId)
{
SqlHelper.ExecuteNonQuery(
ConnectionString,
CommandType.StoredProcedure,
"ChangeExchangeAcceptedDomainType",
new SqlParameter("@ItemID", itemId),
new SqlParameter("@DomainID", domainId),
new SqlParameter("@DomainTypeID", domainTypeId)
);
}
public static IDataReader GetExchangeOrganizationStatistics(int itemId)
{
return SqlHelper.ExecuteReader(
@ -3399,5 +3412,45 @@ namespace WebsitePanel.EnterpriseServer
#endregion
public static int GetPackageIdByName(string Name)
{
// get Helicon Zoo provider
int packageId = -1;
List<ProviderInfo> providers = ServerController.GetProviders();
foreach (ProviderInfo providerInfo in providers)
{
if (string.Equals(Name, providerInfo.ProviderName, StringComparison.OrdinalIgnoreCase))
{
packageId = providerInfo.ProviderId;
break;
}
}
if (-1 == packageId)
{
throw new Exception("Provider not found");
}
return packageId;
}
public static int GetServiceIdByProviderForServer(int providerId, int serverId)
{
IDataReader reader = SqlHelper.ExecuteReader(ConnectionString, CommandType.Text,
@"SELECT TOP 1
ServiceID
FROM Services
WHERE ProviderID = @ProviderID AND ServerID = @ServerID",
new SqlParameter("@ProviderID", providerId),
new SqlParameter("@ServerID", serverId));
if (reader.Read())
{
return (int)reader["ServiceID"];
}
return -1;
}
}
}

View file

@ -284,7 +284,7 @@ namespace WebsitePanel.EnterpriseServer
if (record.RecordType == "A" || record.RecordType == "AAAA")
{
rr.RecordData = String.IsNullOrEmpty(record.RecordData) ? record.ExternalIP : record.RecordData;
rr.RecordData = Utils.ReplaceStringVariable(rr.RecordData, "ip", record.ExternalIP);
rr.RecordData = Utils.ReplaceStringVariable(rr.RecordData, "ip", string.IsNullOrEmpty(serviceIP) ? record.ExternalIP : serviceIP);
if (String.IsNullOrEmpty(rr.RecordData) && !String.IsNullOrEmpty(serviceIP))
rr.RecordData = serviceIP;
@ -310,7 +310,10 @@ namespace WebsitePanel.EnterpriseServer
rr.MxPriority = record.MxPriority;
if (!String.IsNullOrEmpty(rr.RecordData))
zoneRecords.Add(rr);
{
if (rr.RecordName != "[host_name]")
zoneRecords.Add(rr);
}
}
return zoneRecords;

View file

@ -446,6 +446,10 @@ namespace WebsitePanel.EnterpriseServer
{
hubTransportRole.AddAuthoritativeDomain(domain.DomainName);
}
if (domain.DomainType != ExchangeAcceptedDomainType.Authoritative)
{
hubTransportRole.ChangeAcceptedDomainType(domain.DomainName, domain.DomainType);
}
}
authDomainCreated = true;
break;
@ -1423,8 +1427,64 @@ namespace WebsitePanel.EnterpriseServer
TaskManager.CompleteTask();
}
}
public static int ChangeAcceptedDomainType(int itemId, int domainId, ExchangeAcceptedDomainType domainType)
{
// check account
int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive);
if (accountCheck < 0) return accountCheck;
// place log record
TaskManager.StartTask("EXCHANGE", "CHANGE_DOMAIN_TYPE");
TaskManager.TaskParameters["Domain ID"] = domainId;
TaskManager.TaskParameters["Domain Type"] = domainType.ToString();
TaskManager.ItemId = itemId;
try
{
// load organization
Organization org = (Organization)PackageController.GetPackageItem(itemId);
if (org == null)
return -1;
// load domain
DomainInfo domain = ServerController.GetDomain(domainId);
if (domain == null)
return -1;
int[] hubTransportServiceIds;
int[] clientAccessServiceIds;
int exchangeServiceId = GetExchangeServiceID(org.PackageId);
GetExchangeServices(exchangeServiceId, out hubTransportServiceIds, out clientAccessServiceIds);
foreach (int id in hubTransportServiceIds)
{
ExchangeServer hubTransportRole = null;
try
{
hubTransportRole = GetExchangeServer(id, org.ServiceId);
}
catch (Exception ex)
{
TaskManager.WriteError(ex);
continue;
}
hubTransportRole.ChangeAcceptedDomainType(domain.DomainName, domainType);
break;
}
return 0;
}
catch (Exception ex)
{
throw TaskManager.WriteError(ex);
}
finally
{
TaskManager.CompleteTask();
}
}
public static int DeleteAuthoritativeDomain(int itemId, int domainId)
{

View file

@ -1042,6 +1042,37 @@ namespace WebsitePanel.EnterpriseServer
}
}
public static int ChangeOrganizationDomainType(int itemId, int domainId, ExchangeAcceptedDomainType newDomainType)
{
// check account
int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive);
if (accountCheck < 0) return accountCheck;
// place log record
TaskManager.StartTask("ORGANIZATION", "CHANGE_DOMAIN_TYPE", domainId);
TaskManager.ItemId = itemId;
try
{
// change accepted domain type on Exchange
int checkResult = ExchangeServerController.ChangeAcceptedDomainType(itemId, domainId, newDomainType);
// change accepted domain type in DB
int domainTypeId= (int) newDomainType;
DataProvider.ChangeExchangeAcceptedDomainType(itemId, domainId, domainTypeId);
return checkResult;
}
catch (Exception ex)
{
throw TaskManager.WriteError(ex);
}
finally
{
TaskManager.CompleteTask();
}
}
public static int AddOrganizationDomain(int itemId, string domainName)
{

View file

@ -41,6 +41,7 @@ using WebsitePanel.Providers.OS;
using OS = WebsitePanel.Providers.OS;
using System.Collections;
namespace WebsitePanel.EnterpriseServer
{
public class OperatingSystemController : IImportController, IBackupController
@ -409,6 +410,23 @@ namespace WebsitePanel.EnterpriseServer
#region Web Platform Installer
public static bool CheckLoadUserProfile(int serverId)
{
int packageId = DataProvider.GetPackageIdByName("IIS70");
int serviceId = DataProvider.GetServiceIdByProviderForServer(packageId, serverId);
return WebServerController.GetWebServer(serviceId).CheckLoadUserProfile();
}
public static void EnableLoadUserProfile(int serverId)
{
int packageId = DataProvider.GetPackageIdByName("IIS70");
int serviceId = DataProvider.GetServiceIdByProviderForServer(packageId, serverId);
WebServerController.GetWebServer(serviceId).EnableLoadUserProfile();
}
public static void InitWPIFeeds(int serverId, string feedUrls)
{
GetServerService(serverId).InitWPIFeeds(feedUrls);
@ -746,6 +764,7 @@ namespace WebsitePanel.EnterpriseServer
return 0;
}
#endregion
}

View file

@ -481,7 +481,7 @@ namespace WebsitePanel.EnterpriseServer
// create web site
try
{
int webSiteId = WebServerController.AddWebSite(packageId, hostName, domainId, 0, true);
int webSiteId = WebServerController.AddWebSite(packageId, hostName, domainId, 0, true, false);
if (webSiteId < 0)
{
result.Result = webSiteId;

View file

@ -1729,7 +1729,7 @@ namespace WebsitePanel.EnterpriseServer
int webSiteId = 0;
if (webEnabled && createWebSite)
{
webSiteId = WebServerController.AddWebSite(packageId, hostName, domainId, 0, createInstantAlias);
webSiteId = WebServerController.AddWebSite(packageId, hostName, domainId, 0, createInstantAlias, false);
if (webSiteId < 0)
{
@ -2005,7 +2005,8 @@ namespace WebsitePanel.EnterpriseServer
}
// delete zone if required
DnsServerController.DeleteZone(domain.ZoneItemId);
if (!domain.IsDomainPointer)
DnsServerController.DeleteZone(domain.ZoneItemId);
// delete domain
DataProvider.DeleteDomain(SecurityContext.User.UserId, domainId);

View file

@ -228,7 +228,7 @@ namespace WebsitePanel.EnterpriseServer
"sp_dropsrvrolemember '{0}', 'dbcreator'\nGO", dbUser.Name));
// restore original web site bindings
web.UpdateSiteBindings(site.SiteId, bindings);
web.UpdateSiteBindings(site.SiteId, bindings, false);
// save statistics item
item.ServiceId = serviceId;

View file

@ -199,7 +199,7 @@ namespace WebsitePanel.EnterpriseServer
try
{
int webSiteId = WebServerController.AddWebSite(
createdPackageId, hostName, domainId, 0, true);
createdPackageId, hostName, domainId, 0, true, false);
if (webSiteId < 0)
{
// rollback wizard

View file

@ -122,6 +122,12 @@ namespace WebsitePanel.EnterpriseServer
return OrganizationController.AddOrganizationDomain(itemId, domainName);
}
[WebMethod]
public int ChangeOrganizationDomainType(int itemId, int domainId, ExchangeAcceptedDomainType newDomainType)
{
return OrganizationController.ChangeOrganizationDomainType(itemId, domainId, newDomainType);
}
[WebMethod]
public List<OrganizationDomainName> GetOrganizationDomains(int itemId)
{

View file

@ -670,6 +670,20 @@ namespace WebsitePanel.EnterpriseServer
#region Web Platform Installer
[WebMethod]
public bool CheckLoadUserProfile(int serverId)
{
return OperatingSystemController.CheckLoadUserProfile(serverId);
}
[WebMethod]
public void EnableLoadUserProfile(int serverId)
{
OperatingSystemController.EnableLoadUserProfile(serverId);
}
[WebMethod]
public void InitWPIFeeds(int serverId)
{

View file

@ -104,9 +104,9 @@ namespace WebsitePanel.EnterpriseServer
}
[WebMethod]
public int AddWebSite(int packageId, string hostName, int domainId, int ipAddressId)
public int AddWebSite(int packageId, string hostName, int domainId, int ipAddressId, bool ignoreGlobalDNSZone)
{
return WebServerController.AddWebSite(packageId, hostName, domainId, ipAddressId, true);
return WebServerController.AddWebSite(packageId, hostName, domainId, ipAddressId, true, ignoreGlobalDNSZone);
}
[WebMethod]
@ -157,6 +157,18 @@ namespace WebsitePanel.EnterpriseServer
return WebServerController.DeleteWebSite(siteItemId);
}
[WebMethod]
public int SwitchWebSiteToDedicatedIP(int siteItemId, int ipAddressId)
{
return WebServerController.SwitchWebSiteToDedicatedIP(siteItemId, ipAddressId);
}
[WebMethod]
public int SwitchWebSiteToSharedIP(int siteItemId)
{
return WebServerController.SwitchWebSiteToSharedIP(siteItemId);
}
[WebMethod]
public int DeleteVirtualDirectory(int siteItemId, string vdirName)
{

View file

@ -0,0 +1,37 @@
// Copyright (c) 2012, 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.
namespace WebsitePanel.Providers.HostedSolution
{
public enum ExchangeAcceptedDomainType
{
Authoritative = 0,
InternalRelay = 1,
ExternalRelay = 2
}
}

View file

@ -53,6 +53,7 @@ namespace WebsitePanel.Providers.HostedSolution
// Domains
void AddAuthoritativeDomain(string domain);
void DeleteAuthoritativeDomain(string domain);
void ChangeAcceptedDomainType(string domain, ExchangeAcceptedDomainType domainType);
string[] GetAuthoritativeDomains();
// Mailboxes

View file

@ -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;
namespace WebsitePanel.Providers.HostedSolution
{
public class OrganizationDomainName
@ -33,6 +34,7 @@ namespace WebsitePanel.Providers.HostedSolution
int organizationDomainId;
int itemId;
int domainId;
int domainTypeId;
string domainName;
bool isHost;
bool isDefault;
@ -55,6 +57,21 @@ namespace WebsitePanel.Providers.HostedSolution
set { domainId = value; }
}
public int DomainTypeId
{
get { return domainTypeId; }
set { domainTypeId = value; }
}
public ExchangeAcceptedDomainType DomainType
{
get
{
ExchangeAcceptedDomainType type = (ExchangeAcceptedDomainType)domainTypeId;
return type;
}
}
public int OrganizationDomainId
{
get { return organizationDomainId; }

View file

@ -51,7 +51,7 @@ namespace WebsitePanel.Providers.Web
ServerBinding[] GetSiteBindings(string siteId);
string CreateSite(WebSite site);
void UpdateSite(WebSite site);
void UpdateSiteBindings(string siteId, ServerBinding[] bindings);
void UpdateSiteBindings(string siteId, ServerBinding[] bindings, bool emptyBindingsAllowed);
void DeleteSite(string siteId);
// virtual directories
@ -119,6 +119,8 @@ namespace WebsitePanel.Providers.Web
// web app gallery
bool CheckLoadUserProfile();
void EnableLoadUserProfile();
void InitFeeds(int UserId, string[] feeds);
void SetResourceLanguage(int UserId, string resourceLanguage);
bool IsMsDeployInstalled();
@ -153,5 +155,7 @@ namespace WebsitePanel.Providers.Web
ResultObject DeleteCertificate(SSLCertificate certificate, WebSite website);
SSLCertificate ImportCertificate(WebSite website);
bool CheckCertificate(WebSite webSite);
}
}
}

View file

@ -87,7 +87,7 @@ namespace WebsitePanel.Providers.WebAppGallery
//SiteUserPassword = 549755813888,
ALLKNOWN =
AllKnown =
AppHostConfig |
AppPoolConfig |
Boolean |
@ -155,5 +155,21 @@ namespace WebsitePanel.Providers.WebAppGallery
return String.Format("{0}=\"{1}\", Tags={2}", Name, Value, WellKnownTags.ToString());
}
#endif
public void SetWellKnownTagsFromRawString(string rawTags)
{
string[] tags = rawTags.Split(new[] {','}, StringSplitOptions.RemoveEmptyEntries);
DeploymentParameterWellKnownTag wellKnownTags = DeploymentParameterWellKnownTag.None;
foreach (string tag in tags)
{
try
{
wellKnownTags |= (DeploymentParameterWellKnownTag)Enum.Parse(typeof(DeploymentParameterWellKnownTag), tag, true);
}
catch(Exception){}
}
WellKnownTags = wellKnownTags & DeploymentParameterWellKnownTag.AllKnown;
}
}
}

View file

@ -954,7 +954,7 @@ namespace WebsitePanel.Providers.FTP
#endregion
protected bool IsMsFTPInstalled()
protected virtual bool IsMsFTPInstalled()
{
int value = 0;
RegistryKey root = Registry.LocalMachine;
@ -966,7 +966,7 @@ namespace WebsitePanel.Providers.FTP
}
RegistryKey ftp = root.OpenSubKey("SYSTEM\\CurrentControlSet\\Services\\ftpsvc");
bool res = (value == 7 || value == 8) && ftp != null;
bool res = (value == 7) && ftp != null;
if (ftp != null)
ftp.Close();

View file

@ -0,0 +1,67 @@
// Copyright (c) 2012, 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 Microsoft.Win32;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace WebsitePanel.Providers.FTP
{
public class MsFTP80 : MsFTP
{
public MsFTP80() : base()
{
}
protected override bool IsMsFTPInstalled()
{
int value = 0;
RegistryKey root = Registry.LocalMachine;
RegistryKey rk = root.OpenSubKey("SOFTWARE\\Microsoft\\InetStp");
if (rk != null)
{
value = (int)rk.GetValue("MajorVersion", null);
rk.Close();
}
RegistryKey ftp = root.OpenSubKey("SYSTEM\\CurrentControlSet\\Services\\ftpsvc");
bool res = (value == 8) && ftp != null;
if (ftp != null)
ftp.Close();
return res;
}
public override bool IsInstalled()
{
return IsMsFTPInstalled();
}
}
}

View file

@ -0,0 +1,49 @@
// Copyright (c) 2012, 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 System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("WebsitePanel.Providers.FTP.IIs80")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyProduct("WebsitePanel.Providers.FTP.IIs80")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("587b5738-51db-4525-bcf5-60de49e89be4")]

View file

@ -0,0 +1,65 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>WebsitePanel.Providers.FTP.IIs80</RootNamespace>
<AssemblyName>WebsitePanel.Providers.FTP.IIs80</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\WebsitePanel.Server\bin\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>..\WebsitePanel.Server\bin\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\VersionInfo.cs">
<Link>VersionInfo.cs</Link>
</Compile>
<Compile Include="MsFTP80.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\WebsitePanel.Providers.Base\WebsitePanel.Providers.Base.csproj">
<Project>{684c932a-6c75-46ac-a327-f3689d89eb42}</Project>
<Name>WebsitePanel.Providers.Base</Name>
</ProjectReference>
<ProjectReference Include="..\WebsitePanel.Providers.FTP.IIs70\WebsitePanel.Providers.FTP.IIs70.csproj">
<Project>{a28bd694-c308-449f-8fd2-f08f3d54aba0}</Project>
<Name>WebsitePanel.Providers.FTP.IIs70</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View file

@ -230,6 +230,11 @@ namespace WebsitePanel.Providers.HostedSolution
{
DeleteAuthoritativeDomainInternal(domain);
}
public void ChangeAcceptedDomainType(string domainName, ExchangeAcceptedDomainType domainType)
{
ChangeAcceptedDomainTypeInternal(domainName, domainType);
}
#endregion
#region Mailboxes
@ -1374,30 +1379,37 @@ namespace WebsitePanel.Providers.HostedSolution
long size = 0;
Command cmd = new Command("Get-PublicFolderStatistics");
cmd.Parameters.Add("Identity", folder);
if (!string.IsNullOrEmpty(PublicFolderServer))
cmd.Parameters.Add("Server", PublicFolderServer);
Command cmd = new Command("Get-PublicFolderDatabase");
Collection<PSObject> result = ExecuteShellCommand(runSpace, cmd);
if (result != null && result.Count > 0)
{
PSObject obj = result[0];
Unlimited<ByteQuantifiedSize> totalItemSize =
(Unlimited<ByteQuantifiedSize>)GetPSObjectProperty(obj, "TotalItemSize");
size += ConvertUnlimitedToBytes(totalItemSize);
}
if (result != null && result.Count > 0)
{
cmd = new Command("Get-PublicFolderStatistics");
cmd.Parameters.Add("Identity", folder);
if (!string.IsNullOrEmpty(PublicFolderServer))
cmd.Parameters.Add("Server", PublicFolderServer);
result = ExecuteShellCommand(runSpace, cmd);
if (result != null && result.Count > 0)
{
PSObject obj = result[0];
Unlimited<ByteQuantifiedSize> totalItemSize =
(Unlimited<ByteQuantifiedSize>)GetPSObjectProperty(obj, "TotalItemSize");
size += ConvertUnlimitedToBytes(totalItemSize);
}
cmd = new Command("Get-PublicFolder");
cmd.Parameters.Add("Identity", folder);
cmd.Parameters.Add("GetChildren", new SwitchParameter(true));
if (!string.IsNullOrEmpty(PublicFolderServer))
cmd.Parameters.Add("Server", PublicFolderServer);
result = ExecuteShellCommand(runSpace, cmd);
foreach (PSObject obj in result)
{
string id = ObjToString(GetPSObjectProperty(obj, "Identity"));
size += CalculatePublicFolderDiskSpace(runSpace, id);
}
cmd = new Command("Get-PublicFolder");
cmd.Parameters.Add("Identity", folder);
cmd.Parameters.Add("GetChildren", new SwitchParameter(true));
if (!string.IsNullOrEmpty(PublicFolderServer))
cmd.Parameters.Add("Server", PublicFolderServer);
result = ExecuteShellCommand(runSpace, cmd);
foreach (PSObject obj in result)
{
string id = ObjToString(GetPSObjectProperty(obj, "Identity"));
size += CalculatePublicFolderDiskSpace(runSpace, id);
}
}
else
size = 0;
ExchangeLog.LogEnd("CalculatePublicFolderDiskSpace");
return size;
}
@ -3353,7 +3365,7 @@ namespace WebsitePanel.Providers.HostedSolution
//fix showInAddressBook Attribute
if (addressLists.Length > 0)
FixShowInAddressBook(runSpace, email, addressLists);
FixShowInAddressBook(runSpace, email, addressLists, false);
}
catch (Exception ex)
@ -3370,7 +3382,7 @@ namespace WebsitePanel.Providers.HostedSolution
ExchangeLog.LogEnd("CreateDistributionListInternal");
}
private void FixShowInAddressBook(Runspace runSpace, string accountName, string[] addressLists)
private void FixShowInAddressBook(Runspace runSpace, string accountName, string[] addressLists, bool HideFromAddressList)
{
Command cmd = new Command("Get-DistributionGroup");
cmd.Parameters.Add("Identity", accountName);
@ -3380,9 +3392,12 @@ namespace WebsitePanel.Providers.HostedSolution
DirectoryEntry dlDEEntry = GetADObject(AddADPrefix(id));
dlDEEntry.Properties["showInAddressBook"].Clear();
foreach (string addressList in addressLists)
if (!HideFromAddressList)
{
dlDEEntry.Properties["showInAddressBook"].Add(addressList);
foreach (string addressList in addressLists)
{
dlDEEntry.Properties["showInAddressBook"].Add(addressList);
}
}
dlDEEntry.CommitChanges();
}
@ -3542,7 +3557,7 @@ namespace WebsitePanel.Providers.HostedSolution
}
if (addressLists.Length > 0)
FixShowInAddressBook(runSpace, accountName, addressLists);
FixShowInAddressBook(runSpace, accountName, addressLists, hideFromAddressBook);
}
finally
@ -3612,7 +3627,14 @@ namespace WebsitePanel.Providers.HostedSolution
}
if (addressLists.Length > 0)
FixShowInAddressBook(runSpace, accountName, addressLists);
{
cmd = new Command("Get-DistributionGroup");
cmd.Parameters.Add("Identity", accountName);
Collection<PSObject> result = ExecuteShellCommand(runSpace, cmd);
PSObject distributionGroup = result[0];
FixShowInAddressBook(runSpace, accountName, addressLists, (bool)GetPSObjectProperty(distributionGroup, "HiddenFromAddressListsEnabled"));
}
}
finally
@ -3648,7 +3670,14 @@ namespace WebsitePanel.Providers.HostedSolution
}
if (addressLists.Length > 0)
FixShowInAddressBook(runSpace, accountName, addressLists);
{
cmd = new Command("Get-DistributionGroup");
cmd.Parameters.Add("Identity", accountName);
Collection<PSObject> result = ExecuteShellCommand(runSpace, cmd);
PSObject distributionGroup = result[0];
FixShowInAddressBook(runSpace, accountName, addressLists, (bool)GetPSObjectProperty(distributionGroup, "HiddenFromAddressListsEnabled"));
}
}
finally
@ -3720,7 +3749,14 @@ namespace WebsitePanel.Providers.HostedSolution
ExecuteShellCommand(runSpace, cmd);
if (addressLists.Length > 0)
FixShowInAddressBook(runSpace, accountName, addressLists);
{
cmd = new Command("Get-DistributionGroup");
cmd.Parameters.Add("Identity", accountName);
Collection<PSObject> result = ExecuteShellCommand(runSpace, cmd);
PSObject distributionGroup = result[0];
FixShowInAddressBook(runSpace, accountName, addressLists, (bool)GetPSObjectProperty(distributionGroup, "HiddenFromAddressListsEnabled"));
}
}
finally
@ -3856,7 +3892,14 @@ namespace WebsitePanel.Providers.HostedSolution
ExecuteShellCommand(runSpace, cmd);
if (addressLists.Length > 0)
FixShowInAddressBook(runSpace, accountName, addressLists);
{
cmd = new Command("Get-DistributionGroup");
cmd.Parameters.Add("Identity", accountName);
Collection<PSObject> r = ExecuteShellCommand(runSpace, cmd);
PSObject distributionGroup = r[0];
FixShowInAddressBook(runSpace, accountName, addressLists, (bool)GetPSObjectProperty(distributionGroup, "HiddenFromAddressListsEnabled"));
}
}
finally
{
@ -3955,17 +3998,24 @@ namespace WebsitePanel.Providers.HostedSolution
if (sendOnBehalfAccounts == null)
throw new ArgumentNullException("sendOnBehalfAccounts");
Runspace runspace = null;
Runspace runSpace = null;
try
{
runspace = OpenRunspace();
string cn = GetDistributionListCommonName(runspace, accountName);
ExchangeDistributionList distributionList = GetDistributionListPermissionsInternal(organizationId, accountName, runspace);
SetSendAsPermissions(runspace, distributionList.SendAsAccounts, cn, sendAsAccounts);
SetDistributionListSendOnBehalfAccounts(runspace, accountName, sendOnBehalfAccounts);
runSpace = OpenRunspace();
string cn = GetDistributionListCommonName(runSpace, accountName);
ExchangeDistributionList distributionList = GetDistributionListPermissionsInternal(organizationId, accountName, runSpace);
SetSendAsPermissions(runSpace, distributionList.SendAsAccounts, cn, sendAsAccounts);
SetDistributionListSendOnBehalfAccounts(runSpace, accountName, sendOnBehalfAccounts);
if (addressLists.Length > 0)
FixShowInAddressBook(runspace, accountName, addressLists);
{
Command cmd = new Command("Get-DistributionGroup");
cmd.Parameters.Add("Identity", accountName);
Collection<PSObject> result = ExecuteShellCommand(runSpace, cmd);
PSObject distributionGroup = result[0];
FixShowInAddressBook(runSpace, accountName, addressLists, (bool)GetPSObjectProperty(distributionGroup, "HiddenFromAddressListsEnabled"));
}
}
catch (Exception ex)
@ -3975,7 +4025,7 @@ namespace WebsitePanel.Providers.HostedSolution
}
finally
{
CloseRunspace(runspace);
CloseRunspace(runSpace);
}
ExchangeLog.LogEnd("SetDistributionListPermissionsInternal");
@ -5916,6 +5966,31 @@ namespace WebsitePanel.Providers.HostedSolution
ExchangeLog.LogEnd("CreateAuthoritativeDomainInternal");
}
private void ChangeAcceptedDomainTypeInternal(string domainName, ExchangeAcceptedDomainType domainType)
{
ExchangeLog.LogStart("ChangeAcceptedDomainType");
Runspace runSpace = null;
try
{
runSpace = OpenRunspace();
SetAcceptedDomainType(runSpace, domainName,domainType);
}
catch (Exception ex)
{
ExchangeLog.LogError("ChangeAcceptedDomainType", ex);
throw;
}
finally
{
CloseRunspace(runSpace);
}
ExchangeLog.LogEnd("ChangeAcceptedDomainType");
}
private void DeleteAcceptedDomain(string domainName)
{
ExchangeLog.LogStart("DeleteAcceptedDomain");
@ -5980,6 +6055,17 @@ namespace WebsitePanel.Providers.HostedSolution
ExchangeLog.LogEnd("RemoveAcceptedDomain");
}
private void SetAcceptedDomainType(Runspace runSpace, string id, ExchangeAcceptedDomainType domainType)
{
ExchangeLog.LogStart("SetAcceptedDomainType");
Command cmd = new Command("Set-AcceptedDomain");
cmd.Parameters.Add("Identity", id);
cmd.Parameters.Add("DomainType", domainType.ToString());
cmd.Parameters.Add("Confirm", false);
ExecuteShellCommand(runSpace, cmd);
ExchangeLog.LogEnd("SetAcceptedDomainType");
}
#endregion
#region ActiveSync

View file

@ -1237,7 +1237,7 @@ namespace WebsitePanel.Providers.Web
// Create site
webObjectsSvc.CreateSite(site);
// Update web site bindings
webObjectsSvc.UpdateSiteBindings(site.SiteId, site.Bindings);
webObjectsSvc.UpdateSiteBindings(site.SiteId, site.Bindings, false);
// Set web site logging settings
webObjectsSvc.SetWebSiteLoggingSettings(site);
}
@ -1322,7 +1322,7 @@ namespace WebsitePanel.Providers.Web
// Update website
webObjectsSvc.UpdateSite(site);
// Update website bindings
webObjectsSvc.UpdateSiteBindings(site.SiteId, site.Bindings);
webObjectsSvc.UpdateSiteBindings(site.SiteId, site.Bindings, false);
// Set website logging settings
webObjectsSvc.SetWebSiteLoggingSettings(site);
//
@ -1440,9 +1440,9 @@ namespace WebsitePanel.Providers.Web
/// </summary>
/// <param name="siteId">Site's id to update bindings for.</param>
/// <param name="bindings">Bindings information.</param>
public override void UpdateSiteBindings(string siteId, ServerBinding[] bindings)
public override void UpdateSiteBindings(string siteId, ServerBinding[] bindings, bool emptyBindingsAllowed)
{
this.webObjectsSvc.UpdateSiteBindings(siteId, bindings);
this.webObjectsSvc.UpdateSiteBindings(siteId, bindings, emptyBindingsAllowed);
}
/// <summary>
@ -3477,7 +3477,7 @@ namespace WebsitePanel.Providers.Web
#endregion
public new bool IsIISInstalled()
public override bool IsIISInstalled()
{
int value = 0;
RegistryKey root = Registry.LocalMachine;
@ -3488,7 +3488,7 @@ namespace WebsitePanel.Providers.Web
rk.Close();
}
return value == 7 || value == 8;
return value == 7;
}
public override bool IsInstalled()
@ -4042,6 +4042,26 @@ namespace WebsitePanel.Providers.Web
// moved down to IIs60
override public bool CheckLoadUserProfile()
{
using (var srvman = new ServerManager())
{
return srvman.ApplicationPools["WebsitePanel Server"].ProcessModel.LoadUserProfile;
}
}
override public void EnableLoadUserProfile()
{
using (var srvman = new ServerManager())
{
srvman.ApplicationPools["WebsitePanel Server"].ProcessModel.LoadUserProfile = true;
// save changes
srvman.CommitChanges();
}
}
#endregion
}
}

View file

@ -1,4 +1,32 @@
using System.Reflection;
// Copyright (c) 2012, 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 System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
@ -18,14 +46,4 @@ using System.Runtime.InteropServices;
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("0eb18093-bb95-406a-ab78-a2e45f4cb972")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:
[assembly: Guid("0eb18093-bb95-406a-ab78-a2e45f4cb972")]

View file

@ -422,11 +422,14 @@ namespace WebsitePanel.Providers.Web.Iis.WebObjects
return bindings.ToArray();
}
private void SyncWebSiteBindingsChanges(string siteId, ServerBinding[] bindings)
private void SyncWebSiteBindingsChanges(string siteId, ServerBinding[] bindings, bool emptyBindingsAllowed)
{
// ensure site bindings
if (bindings == null || bindings.Length == 0)
throw new Exception("SiteServerBindingsEmpty");
if (!emptyBindingsAllowed)
{
if (bindings == null || bindings.Length == 0)
throw new Exception("SiteServerBindingsEmpty");
}
using (var srvman = GetServerManager())
{
@ -461,7 +464,7 @@ namespace WebsitePanel.Providers.Web.Iis.WebObjects
}
}
public void UpdateSiteBindings(string siteId, ServerBinding[] bindings)
public void UpdateSiteBindings(string siteId, ServerBinding[] bindings, bool emptyBindingsAllowed)
{
using (ServerManager srvman = GetServerManager())
{
@ -470,7 +473,7 @@ namespace WebsitePanel.Providers.Web.Iis.WebObjects
return;
}
//
SyncWebSiteBindingsChanges(siteId, bindings);
SyncWebSiteBindingsChanges(siteId, bindings, emptyBindingsAllowed);
}
public string GetPhysicalPath(ServerManager srvman, WebVirtualDirectory virtualDir)

View file

@ -847,7 +847,7 @@ namespace WebsitePanel.Providers.Web
}
}
public virtual void UpdateSiteBindings(string siteId, ServerBinding[] bindings)
public virtual void UpdateSiteBindings(string siteId, ServerBinding[] bindings, bool emptyBindingsAllowed)
{
ManagementObject objSite = wmi.GetObject(String.Format("IIsWebServerSetting='{0}'", siteId));
@ -3368,7 +3368,7 @@ namespace WebsitePanel.Providers.Web
}
#endregion
public bool IsIISInstalled()
public virtual bool IsIISInstalled()
{
int value = 0;
RegistryKey root = Registry.LocalMachine;
@ -3394,6 +3394,18 @@ namespace WebsitePanel.Providers.Web
private const string WPI_INSTANCE_VIEWER = "viewer";
private const string WPI_INSTANCE_INSTALLER = "installer";
virtual public bool CheckLoadUserProfile()
{
throw new NotImplementedException("LoadUserProfile option valid only on IIS7 or higer");
}
virtual public void EnableLoadUserProfile()
{
throw new NotImplementedException("LoadUserProfile option valid only on IIS7 or higer");
}
public void InitFeeds(int UserId, string[] feeds)
{
//need to call InitFeeds() before any operation with WPIApplicationGallery()
@ -3667,5 +3679,10 @@ namespace WebsitePanel.Providers.Web
throw new NotSupportedException();
}
#endregion
}
}
}

View file

@ -44,6 +44,7 @@ using System.Web;
using System.Diagnostics;
using Microsoft.Practices.EnterpriseLibrary.Caching.Expirations;
using DeploymentParameter = WebsitePanel.Providers.WebAppGallery.DeploymentParameter;
using DeploymentParameterWPI = Microsoft.Web.PlatformInstaller.DeploymentParameter;
namespace WebsitePanel.Providers.Web.WPIWebApplicationGallery
{
@ -268,10 +269,10 @@ namespace WebsitePanel.Providers.Web.WPIWebApplicationGallery
Product product = wpi.GetProduct(id);
List<DeploymentParameter> deploymentParameters = new List<DeploymentParameter>();
IList<DeclaredParameter> appDecalredParameters = wpi.GetAppDecalredParameters(id);
foreach (DeclaredParameter declaredParameter in appDecalredParameters)
IList<DeploymentParameterWPI> appDeploymentWPIParameters = wpi.GetAppDecalredParameters(id);
foreach (DeploymentParameterWPI deploymentParameter in appDeploymentWPIParameters)
{
deploymentParameters.Add(MakeDeploymentParameterFromDecalredParameter(declaredParameter));
deploymentParameters.Add(MakeDeploymentParameterFromDecalredParameter(deploymentParameter));
}
return deploymentParameters;
@ -398,28 +399,41 @@ namespace WebsitePanel.Providers.Web.WPIWebApplicationGallery
};
}
protected static DeploymentParameter MakeDeploymentParameterFromDecalredParameter(DeclaredParameter d)
protected static DeploymentParameter MakeDeploymentParameterFromDecalredParameter(DeploymentParameterWPI d)
{
DeploymentParameter r = new DeploymentParameter();
r.Name = d.Name;
r.FriendlyName = d.FriendlyName;
r.DefaultValue = d.DefaultValue;
r.Description = d.Description;
#pragma warning disable 612,618
r.WellKnownTags = DeploymentParameterWellKnownTag.ALLKNOWN & (DeploymentParameterWellKnownTag) d.Tags;
if (null != d.Validation)
r.SetWellKnownTagsFromRawString(d.RawTags);
if (!string.IsNullOrEmpty(d.ValidationString))
{
r.ValidationKind = (DeploymentParameterValidationKind) d.Validation.Kind;
r.ValidationString = d.Validation.ValidationString;
// synchronized with Microsoft.Web.Deployment.DeploymentSyncParameterValidationKind
if (d.HasValidation((int)DeploymentParameterValidationKind.AllowEmpty))
{
r.ValidationKind |= DeploymentParameterValidationKind.AllowEmpty;
}
if (d.HasValidation((int)DeploymentParameterValidationKind.RegularExpression))
{
r.ValidationKind |= DeploymentParameterValidationKind.RegularExpression;
}
if (d.HasValidation((int)DeploymentParameterValidationKind.Enumeration))
{
r.ValidationKind |= DeploymentParameterValidationKind.Enumeration;
}
if (d.HasValidation((int)DeploymentParameterValidationKind.Boolean))
{
r.ValidationKind |= DeploymentParameterValidationKind.Boolean;
}
r.ValidationString = d.ValidationString;
}
else
{
r.ValidationKind = DeploymentParameterValidationKind.None;
}
#pragma warning restore 612,618
return r;
}

View file

@ -77,11 +77,6 @@
<HintPath>..\..\Lib\References\Microsoft\Microsoft.Web.PlatformInstaller.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.Web.PlatformInstaller.WebDeployShim, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\Lib\References\Microsoft\Microsoft.Web.PlatformInstaller.WebDeployShim.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.DirectoryServices" />

View file

@ -0,0 +1,62 @@
// Copyright (c) 2012, 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 Microsoft.Win32;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace WebsitePanel.Providers.Web
{
public class IIs80 : IIs70, IWebServer
{
public IIs80() : base()
{
}
public override bool IsIISInstalled()
{
int value = 0;
RegistryKey root = Registry.LocalMachine;
RegistryKey rk = root.OpenSubKey("SOFTWARE\\Microsoft\\InetStp");
if (rk != null)
{
value = (int)rk.GetValue("MajorVersion", null);
rk.Close();
}
return value == 8;
}
public override bool IsInstalled()
{
return IsIISInstalled();
}
}
}

View file

@ -0,0 +1,49 @@
// Copyright (c) 2012, 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 System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("WebsitePanel.Providers.Web.IIs80")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyProduct("WebsitePanel.Providers.Web.IIs80")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("b0305c67-ead3-4d69-a0d8-548f6d0f705b")]

View file

@ -0,0 +1,69 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{6E348968-461D-45A1-B235-4F552947B9F1}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>WebsitePanel.Providers.Web</RootNamespace>
<AssemblyName>WebsitePanel.Providers.Web.IIs80</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>..\WebsitePanel.Server\bin\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>..\WebsitePanel.Server\bin\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="..\VersionInfo.cs">
<Link>VersionInfo.cs</Link>
</Compile>
<Compile Include="IIs80.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\WebsitePanel.Providers.Base\WebsitePanel.Providers.Base.csproj">
<Project>{684c932a-6c75-46ac-a327-f3689d89eb42}</Project>
<Name>WebsitePanel.Providers.Base</Name>
</ProjectReference>
<ProjectReference Include="..\WebsitePanel.Providers.Web.IIs60\WebsitePanel.Providers.Web.IIs60.csproj">
<Project>{9be0317d-e42e-4ff6-9a87-8c801f046ea1}</Project>
<Name>WebsitePanel.Providers.Web.IIs60</Name>
</ProjectReference>
<ProjectReference Include="..\WebsitePanel.Providers.Web.IIS70\WebsitePanel.Providers.Web.IIs70.csproj">
<Project>{1b9dce85-c664-49fc-b6e1-86c63cab88d1}</Project>
<Name>WebsitePanel.Providers.Web.IIs70</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View file

@ -1032,7 +1032,17 @@ namespace WebsitePanel.Providers.Exchange
this.Invoke("AddAuthoritativeDomain", new object[] {
domain});
}
/// <remarks/>
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/ChangeAcceptedDomainType", 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 void ChangeAcceptedDomainType(string domain, ExchangeAcceptedDomainType domainType)
{
this.Invoke("ChangeAcceptedDomainType", new object[] {
domain,
domainType});
}
/// <remarks/>
public System.IAsyncResult BeginAddAuthoritativeDomain(string domain, System.AsyncCallback callback, object asyncState) {
return this.BeginInvoke("AddAuthoritativeDomain", new object[] {

View file

@ -1,5 +1,5 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2010
# Visual Studio 2012
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Caching Application Block", "Caching Application Block", "{C8E6F2E4-A5B8-486A-A56E-92D864524682}"
ProjectSection(SolutionItems) = preProject
Bin\Microsoft.Practices.EnterpriseLibrary.Common.dll = Bin\Microsoft.Practices.EnterpriseLibrary.Common.dll
@ -107,6 +107,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebsitePanel.Providers.Mail
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebsitePanel.Providers.OS.Windows2012", "WebsitePanel.Providers.OS.Windows2012\WebsitePanel.Providers.OS.Windows2012.csproj", "{27130BBB-76FA-411E-8B4D-51CD4DC821AF}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebsitePanel.Providers.Web.IIs80", "WebsitePanel.Providers.Web.IIs80\WebsitePanel.Providers.Web.IIs80.csproj", "{6E348968-461D-45A1-B235-4F552947B9F1}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebsitePanel.Providers.FTP.IIs80", "WebsitePanel.Providers.FTP.IIs80\WebsitePanel.Providers.FTP.IIs80.csproj", "{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@ -587,6 +591,26 @@ Global
{27130BBB-76FA-411E-8B4D-51CD4DC821AF}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{27130BBB-76FA-411E-8B4D-51CD4DC821AF}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{27130BBB-76FA-411E-8B4D-51CD4DC821AF}.Release|x86.ActiveCfg = Release|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Debug|x86.ActiveCfg = Debug|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Release|Any CPU.Build.0 = Release|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{6E348968-461D-45A1-B235-4F552947B9F1}.Release|x86.ActiveCfg = Release|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Debug|x86.ActiveCfg = Debug|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Release|Any CPU.Build.0 = Release|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{D73CCF4C-9CFF-4D61-9030-34DCAF0C50D6}.Release|x86.ActiveCfg = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

View file

@ -38,6 +38,7 @@ using System.Threading;
using Microsoft.Web.Deployment;
using Microsoft.Web.PlatformInstaller;
using Installer = Microsoft.Web.PlatformInstaller.Installer;
using DeploymentParameterWPI = Microsoft.Web.PlatformInstaller.DeploymentParameter;
namespace WebsitePanel.Server.Code
{
@ -453,11 +454,11 @@ namespace WebsitePanel.Server.Code
return products;
}
public IList<DeclaredParameter> GetAppDecalredParameters(string productId)
public IList<DeploymentParameterWPI> GetAppDecalredParameters(string productId)
{
Product app = _productManager.GetProduct(productId);
Installer appInstaller = app.GetInstaller(GetLanguage(null));
return appInstaller.MSDeployPackage.DeclaredParameters;
return appInstaller.MSDeployPackage.DeploymentParameters;
}
public bool InstallApplication(
@ -501,7 +502,7 @@ namespace WebsitePanel.Server.Code
DeploymentWellKnownTag dbTag = (DeploymentWellKnownTag)GetDbTag(updatedValues);
// remove parameters with alien db tags
foreach (DeclaredParameter parameter in appInstaller.MSDeployPackage.DeclaredParameters)
foreach (DeploymentParameterWPI parameter in appInstaller.MSDeployPackage.DeploymentParameters)
{
if (IsAlienDbTaggedParameter(dbTag, parameter))
{
@ -726,13 +727,16 @@ namespace WebsitePanel.Server.Code
return DeploymentWellKnownTag.None;
}
private static bool IsAlienDbTaggedParameter(DeploymentWellKnownTag dbTag, DeclaredParameter parameter)
private static bool IsAlienDbTaggedParameter(DeploymentWellKnownTag dbTag, DeploymentParameterWPI parameter)
{
return parameter.HasTags((long)databaseEngineTags) && !parameter.HasTags((long)dbTag);
/*
#pragma warning disable 612,618
return (parameter.Tags & databaseEngineTags) != DeploymentWellKnownTag.None
&&
(parameter.Tags & dbTag) == DeploymentWellKnownTag.None;
#pragma warning restore 612,618
*/
}
private static void RemoveUnusedProviders(MSDeployPackage msDeployPackage, DeploymentWellKnownTag dbTag)

View file

@ -265,6 +265,21 @@ namespace WebsitePanel.Server
}
}
[WebMethod, SoapHeader("settings")]
public void ChangeAcceptedDomainType(string domain, ExchangeAcceptedDomainType domainType)
{
try
{
LogStart("ChangeAcceptedDomainType");
ES.ChangeAcceptedDomainType(domain, domainType);
LogEnd("ChangeAcceptedDomainType");
}
catch (Exception ex)
{
LogError("ChangeAcceptedDomainType", ex);
throw;
}
}
[WebMethod, SoapHeader("settings")]
public string[] GetAuthoritativeDomains()

View file

@ -229,12 +229,12 @@ namespace WebsitePanel.Server
}
[WebMethod, SoapHeader("settings")]
public void UpdateSiteBindings(string siteId, ServerBinding[] bindings)
public void UpdateSiteBindings(string siteId, ServerBinding[] bindings, bool emptyBindingsAllowed)
{
try
{
Log.WriteStart("'{0}' UpdateSiteBindings", ProviderSettings.ProviderName);
WebProvider.UpdateSiteBindings(siteId, bindings);
WebProvider.UpdateSiteBindings(siteId, bindings, emptyBindingsAllowed);
Log.WriteEnd("'{0}' UpdateSiteBindings", ProviderSettings.ProviderName);
}
catch (Exception ex)
@ -1061,6 +1061,42 @@ namespace WebsitePanel.Server
#endregion
#region Web Application Gallery
[WebMethod, SoapHeader("settings")]
public bool CheckLoadUserProfile()
{
try
{
Log.WriteStart("CheckLoadUserProfile");
return WebProvider.CheckLoadUserProfile();
Log.WriteEnd("CheckLoadUserProfile");
}
catch (Exception ex)
{
Log.WriteError("CheckLoadUserProfile", ex);
throw;
}
}
[WebMethod, SoapHeader("settings")]
public void EnableLoadUserProfile()
{
try
{
Log.WriteStart("EnableLoadUserProfile");
WebProvider.EnableLoadUserProfile();
Log.WriteEnd("EnableLoadUserProfile");
}
catch (Exception ex)
{
Log.WriteError("EnableLoadUserProfile", ex);
throw;
}
}
[WebMethod, SoapHeader("settings")]
public void InitFeeds(int UserId, string[] feeds)
{

View file

@ -876,6 +876,9 @@
<data name="Error.WPI_LOAD_FEED" xml:space="preserve">
<value>Error loading feeds. Please check system settings</value>
</data>
<data name="Error.WPI_CHECK_LOAD_USER_PROFILE" xml:space="preserve">
<value>Error checking 'Load user profile' application pool setting.</value>
</data>
<data name="Error.SPACE_LETTER_GET" xml:space="preserve">
<value>Error building hosting space summary letter</value>
</data>
@ -5125,9 +5128,6 @@
<data name="ResourceGroup.Lync" xml:space="preserve">
<value>Lync Server</value>
</data>
<data name="Success.UPDATE_LYNC_USER" xml:space="preserve">
<value>General Lync User settings have been successfully updated.</value>
</data>
<data name="Warning.CREATE_LYNC_USER" xml:space="preserve">
<value>Lync User has been successfully created but the following errors have been occured:</value>
</data>
@ -5191,14 +5191,12 @@
<data name="Success.EXCHANGE_STAMPMAILBOXES" xml:space="preserve">
<value>Succesfully stamp mailboxes</value>
</data>
<data name="Error.EXCHANGE_UPDATEPLANS" xml:space="preserve">
<value>Mailbox plan update failed</value>
</data>
<data name="Success.EXCHANGE_UPDATEPLANS" xml:space="preserve">
<value>Mailbox plan updated</value>
</data>
<data name="Error.LYNC_APPLYPLANTEMPLATE" xml:space="preserve">
<value>Failed to apply plans template</value>
</data>
@ -5208,7 +5206,16 @@
<data name="Success.REQUEST_COMPLETED_SUCCESFULLY" xml:space="preserve">
<value>Request Completed Succesfully</value>
</data>
<data name="Error.WEB_SWITCH_TO_DEDICATED_IP" xml:space="preserve">
<value>Error updating web site to dedicated IP</value>
</data>
<data name="Error.WEB_SWITCH_TO_SHARED_IP" xml:space="preserve">
<value>Error updating web site to shared IP</value>
</data>
<data name="Success.WEB_SWITCH_TO_DEDICATED_IP" xml:space="preserve">
<value>Web site has been updated to dedicated IP</value>
</data>
<data name="Success.WEB_SWITCH_TO_SHARED_IP" xml:space="preserve">
<value>Web site has been updated to shared IP</value>
</data>
</root>

View file

@ -195,4 +195,7 @@
<data name="lblExchangeStorage.Text" xml:space="preserve">
<value>Exchange Storage, MB:</value>
</data>
<data name="lblOrganizations.Text" xml:space="preserve">
<value>Organizations:</value>
</data>
</root>

View file

@ -151,6 +151,6 @@
<value>Status</value>
</data>
<data name="locSubscriberNumber.Text" xml:space="preserve">
<value>Subscriber Number:</value>
<value>Account Number:</value>
</data>
</root>

View file

@ -160,7 +160,7 @@
<value>Secondary E-Mail:</value>
</data>
<data name="lblSubscriberNumber.Text" xml:space="preserve">
<value>Subscriber Number:</value>
<value>Account Number:</value>
</data>
<data name="lblUsername.Text" xml:space="preserve">
<value>User name:</value>

View file

@ -202,6 +202,6 @@
<value>*</value>
</data>
<data name="lblSubscriberNumber" xml:space="preserve">
<value>Subscriber Number:</value>
<value>Account Number:</value>
</data>
</root>

View file

@ -112,10 +112,10 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="btnAdd.Text" xml:space="preserve">
<value>Add Pointer</value>
@ -124,6 +124,6 @@
<value>Cancel</value>
</data>
<data name="lblDomainName.Text" xml:space="preserve">
<value>Domain Alias:</value>
<value>Web Site Pointer:</value>
</data>
</root>

View file

@ -112,10 +112,10 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="btnAdd.OnClientClick" xml:space="preserve">
<value>ShowProgressDialog('Creating web site...');</value>
@ -126,11 +126,14 @@
<data name="btnCancel.Text" xml:space="preserve">
<value>Cancel</value>
</data>
<data name="chkIgnoreGlobalDNSRecords.Text" xml:space="preserve">
<value>Ignore Zone Template</value>
</data>
<data name="lblAspNetVersion.Text" xml:space="preserve">
<value>ASP.NET Version:</value>
</data>
<data name="lblDomainName.Text" xml:space="preserve">
<value>Domain Name:</value>
<value>Site:</value>
</data>
<data name="lblIPAddress.Text" xml:space="preserve">
<value>IP address:</value>
@ -138,6 +141,9 @@
<data name="lblIPHelp.Text" xml:space="preserve">
<value>If you need your web site to be accessible via dedicated IP address or you are planning to enable SSL for your site you should choose "Dedicated IP" option; otherwise leave this settings by default. In order to create IP-based site you need to purchase IP address from your host.</value>
</data>
<data name="lblIPHelp2.Text" xml:space="preserve">
<value>Note: A Zone Template is often defined by your host and contains additional Web Site Pointers to create when creating a new Web Site. Static record definitions such as 'www' conflicts when creating an additional Web Site in the same Domain. &lt;/p&gt;Check this option to ignore the Zone Template and create the new Web Site with this Web Site Pointer only. </value>
</data>
<data name="rbDedicatedIP.Text" xml:space="preserve">
<value>Dedicated</value>
</data>

View file

@ -112,10 +112,10 @@
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="btnAddFolder.Text" xml:space="preserve">
<value>Add Folder</value>
@ -243,7 +243,7 @@
<data name="gvHeliconApeGroupsName.Header" xml:space="preserve">
<value>.htaccess Groups</value>
</data>
<data name="gvMimeTypes.Empty" xml:space="preserve">
<data name="gvMimeTypes.Empty" xml:space="preserve">
<value>Custom MIME types are not defined</value>
</data>
<data name="gvMimeTypesExtension.Header" xml:space="preserve">
@ -408,55 +408,82 @@ To connect to web site management service please use username and password provi
<data name="Tab.SSL" xml:space="preserve">
<value>SSL</value>
</data>
<data name="Tab.WebDeployPublishing" xml:space="preserve">
<data name="Tab.WebDeployPublishing" xml:space="preserve">
<value>Web Publishing</value>
</data>
<data name="WDeploySitePublishingDisabled.Text" xml:space="preserve">
<data name="WDeploySitePublishingDisabled.Text" xml:space="preserve">
<value>Web Deploy Publishing is Disabled.</value>
</data>
<data name="WDeploySitePublishingEnabled.Text" xml:space="preserve">
<data name="WDeploySitePublishingEnabled.Text" xml:space="preserve">
<value>Web Deploy Publishing is Enabled.</value>
</data>
<data name="WDeploySitePublishingEnablementHint.Text" xml:space="preserve">
<data name="WDeploySitePublishingEnablementHint.Text" xml:space="preserve">
<value>To enable Web Publishing for this web site specify account user name and password and then click "Enable" button.</value>
</data>
<data name="PubProfileMsSqlLocalize.Text" xml:space="preserve">
<data name="PubProfileMsSqlLocalize.Text" xml:space="preserve">
<value>Please choose a Microsoft SQL database:</value>
</data>
<data name="WDeployBuildPublishingProfileWizard.Text" xml:space="preserve">
<data name="WDeployBuildPublishingProfileWizard.Text" xml:space="preserve">
<value>Build Publising Profile Wizard</value>
</data>
<data name="WDeployBuildSitePublishingProfileHint.Text" xml:space="preserve">
<data name="WDeployBuildSitePublishingProfileHint.Text" xml:space="preserve">
<value>Please use the link below to build a publishing profile that makes it easy to configure publishing settings for your convenience.</value>
</data>
<data name="WDeployChangePublishingPasswButton.Text" xml:space="preserve">
<data name="WDeployChangePublishingPasswButton.Text" xml:space="preserve">
<value>Change Password</value>
</data>
<data name="WDeployDisablePublishingButton.Text" xml:space="preserve">
<data name="WDeployDisablePublishingButton.Text" xml:space="preserve">
<value>Disable</value>
</data>
<data name="WDeployEnabePublishingButton.Text" xml:space="preserve">
<data name="WDeployEnabePublishingButton.Text" xml:space="preserve">
<value>Enable</value>
</data>
<data name="WDeployPublishingAccountLocalize.Text" xml:space="preserve">
<data name="WDeployPublishingAccountLocalize.Text" xml:space="preserve">
<value>Username:</value>
</data>
<data name="WDeployPublishingConfirmPasswordLocalize.Text" xml:space="preserve">
<data name="WDeployPublishingConfirmPasswordLocalize.Text" xml:space="preserve">
<value>Confim password:</value>
</data>
<data name="WDeployPublishingPasswordLocalize.Text" xml:space="preserve">
<data name="WDeployPublishingPasswordLocalize.Text" xml:space="preserve">
<value>Password:</value>
</data>
<data name="WDeployPublishingProfileUsageNotes.Text" xml:space="preserve">
<data name="WDeployPublishingProfileUsageNotes.Text" xml:space="preserve">
<value>Now you can publish content to this site easily via either Web Matrix or Visual Studio .NET 2010. Please use the link below to download publishing profile that makes it easy to publish the content online for your convenience. You also have an option to re-build publishing profile if you decide to change or update your publishing settings.</value>
</data>
<data name="WebPublishing.ChooseDatabasePrompt" xml:space="preserve">
<data name="WebPublishing.ChooseDatabasePrompt" xml:space="preserve">
<value>Choose database...</value>
</data>
<data name="WebPublishing.ChooseDatabaseUserPrompt" xml:space="preserve">
<data name="WebPublishing.ChooseDatabaseUserPrompt" xml:space="preserve">
<value>Choose database user...</value>
</data>
<data name="WebPublishing.ChooseFtpAccountPrompt" xml:space="preserve">
<data name="WebPublishing.ChooseFtpAccountPrompt" xml:space="preserve">
<value>Choose FTP account...</value>
</data>
<data name="cmdApplyDedicatedIP.OnClientClick" xml:space="preserve">
<value>ShowProgressDialog('Applying changes...');</value>
</data>
<data name="cmdApplyDedicatedIP.Text" xml:space="preserve">
<value>Apply</value>
</data>
<data name="cmdCancelDedicatedIP.Text" xml:space="preserve">
<value>Cancel</value>
</data>
<data name="cmdSwitchToDedicatedIP.Text" xml:space="preserve">
<value>Switch to dedicated IP</value>
</data>
<data name="cmdSwitchToSharedIP.OnClientClick" xml:space="preserve">
<value>if(!confirm('Do you really want to switch this web site to shared IP?')) return false;ShowProgressDialog('Applying changes...');</value>
</data>
<data name="cmdSwitchToSharedIP.Text" xml:space="preserve">
<value>Switch to shared IP</value>
</data>
<data name="locDedicatedIPAddress.Text" xml:space="preserve">
<value>IP address:</value>
</data>
<data name="locSelectIPAddress.Text" xml:space="preserve">
<value>Select IP address:</value>
</data>
<data name="locSharedIPAddress.Text" xml:space="preserve">
<value>IP address: Shared</value>
</data>
</root>

View file

@ -157,7 +157,7 @@
<value>Password: *</value>
</data>
<data name="locSubscriberNumber.Text" xml:space="preserve">
<value>Subscriber Number: *</value>
<value>Account Number: *</value>
</data>
<data name="locTitle.Text" xml:space="preserve">
<value>Create New Mailbox</value>
@ -187,7 +187,7 @@
<value>*</value>
</data>
<data name="valRequireSubscriberNumber.ErrorMessage" xml:space="preserve">
<value>Enter Subscriber Number</value>
<value>Enter Account Number</value>
</data>
<data name="valRequireSubscriberNumber.Text" xml:space="preserve">
<value>*</value>

View file

@ -155,4 +155,13 @@
<data name="Text.PageName" xml:space="preserve">
<value>Domain Names</value>
</data>
<data name="gvDomainsType.Header" xml:space="preserve">
<value>Domain Type</value>
</data>
<data name="gvDomainsTypeChange.Header" xml:space="preserve">
<value>Change Type</value>
</data>
<data name="btnChangeDomain.Text" xml:space="preserve">
<value>Change</value>
</data>
</root>

View file

@ -145,7 +145,7 @@
<value>Password: *</value>
</data>
<data name="locSubscriberNumber.Text" xml:space="preserve">
<value>Subscriber Number: *</value>
<value>Account Number: *</value>
</data>
<data name="locTitle.Text" xml:space="preserve">
<value>Create New User</value>
@ -160,7 +160,7 @@
<value>*</value>
</data>
<data name="valRequireSubscriberNumber.ErrorMessage" xml:space="preserve">
<value>Enter Subscriber Number</value>
<value>Enter Account Number</value>
</data>
<data name="valRequireSubscriberNumber.Text" xml:space="preserve">
<value>*</value>

View file

@ -201,7 +201,7 @@
<value>State/Province:</value>
</data>
<data name="locSubscriberNumber.Text" xml:space="preserve">
<value>Subscriber Number:</value>
<value>Account Number:</value>
</data>
<data name="locTitle.Text" xml:space="preserve">
<value>Edit User</value>

View file

@ -142,7 +142,7 @@
<value>E-mail Address</value>
</data>
<data name="ddlSearchColumnSubscriberNumber" xml:space="preserve">
<value>Subscriber Number</value>
<value>Account Number</value>
</data>
<data name="gvSubscriberNumber.Header" xml:space="preserve">
<value>Subscriber</value>

View file

@ -58,7 +58,10 @@ namespace WebsitePanel.Portal.ExchangeServer
}
}
if (ddlDomains.Items.Count == 0) btnAdd.Enabled = false;
if (ddlDomains.Items.Count == 0)
{
ddlDomains.Visible= btnAdd.Enabled = false;
}

View file

@ -95,11 +95,11 @@
</td>
</tr>
<tr>
<td class="FormLabel150"><asp:Localize ID="locSubscriberNumber" runat="server" meta:resourcekey="locSubscriberNumber" Text="Subscriber Number: *"></asp:Localize></td>
<td class="FormLabel150"><asp:Localize ID="locSubscriberNumber" runat="server" meta:resourcekey="locSubscriberNumber" Text="Account Number: *"></asp:Localize></td>
<td>
<asp:TextBox ID="txtSubscriberNumber" runat="server" CssClass="HugeTextBox200"></asp:TextBox>
<asp:RequiredFieldValidator ID="valRequireSubscriberNumber" runat="server" meta:resourcekey="valRequireSubscriberNumber" ControlToValidate="txtSubscriberNumber"
ErrorMessage="Enter Subscriber Number" ValidationGroup="CreateMailbox" Display="Dynamic" Text="*" SetFocusOnError="True"></asp:RequiredFieldValidator>
ErrorMessage="Enter Account Number" ValidationGroup="CreateMailbox" Display="Dynamic" Text="*" SetFocusOnError="True"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>

View file

@ -1,31 +1,3 @@
// Copyright (c) 2012, 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.
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.

View file

@ -33,7 +33,7 @@
Width="100%" EmptyDataText="gvDomains" CssSelectorClass="NormalGridView" OnRowCommand="gvDomains_RowCommand">
<Columns>
<asp:TemplateField HeaderText="gvDomainsName">
<ItemStyle Width="70%"></ItemStyle>
<ItemStyle Width="50%"></ItemStyle>
<ItemTemplate>
<asp:hyperlink id="lnkEditZone" runat="server" EnableViewState="false"
NavigateUrl='<%# GetDomainRecordsEditUrl(Eval("DomainID").ToString()) %>' Enabled='<%# !(bool)Eval("IsHost") %>'>
@ -41,13 +41,27 @@
</asp:hyperlink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="gvDomainsType">
<ItemTemplate>
<div style="text-align:center">
<asp:Label ID="Label1" Text='<%# Eval("DomainType") %>' runat="server"/>
</div>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="gvDomainsTypeChange">
<ItemTemplate>
<div style="text-align:center">
<asp:Button ID="btnChangeDomain" text="Change" meta:resourcekey="btnChangeDomain" runat="server" CommandName="Change" CommandArgument='<%# Eval("DomainId") + "|" + Eval("DomainType") %>'/>
</div>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="gvDomainsDefault">
<ItemTemplate>
<div style="text-align:center">
<input type="radio" name="DefaultDomain" value='<%# Eval("DomainId") %>' <%# IsChecked((bool)Eval("IsDefault")) %> />
</div>
</ItemTemplate>
</asp:TemplateField>
</asp:TemplateField>
<asp:TemplateField>
<ItemTemplate>
&nbsp;<asp:ImageButton ID="imgDelDomain" runat="server" Text="Delete" SkinID="ExchangeDelete"

View file

@ -117,6 +117,37 @@ namespace WebsitePanel.Portal.ExchangeServer
ShowErrorMessage("EXCHANGE_DELETE_DOMAIN", ex);
}
}
else if (e.CommandName == "Change")
{
string[] commandArgument = e.CommandArgument.ToString().Split('|');
int domainId = Utils.ParseInt(commandArgument[0].ToString(), 0);
ExchangeAcceptedDomainType acceptedDomainType = (ExchangeAcceptedDomainType)Enum.Parse(typeof(ExchangeAcceptedDomainType), commandArgument[1]);
try
{
ExchangeAcceptedDomainType newDomainType = ExchangeAcceptedDomainType.Authoritative;
if (acceptedDomainType == ExchangeAcceptedDomainType.Authoritative)
newDomainType = ExchangeAcceptedDomainType.InternalRelay;
int result = ES.Services.Organizations.ChangeOrganizationDomainType(PanelRequest.ItemID, domainId, newDomainType);
if (result < 0)
{
messageBox.ShowResultMessage(result);
return;
}
// rebind domains
BindDomainNames();
BindStats();
}
catch (Exception ex)
{
ShowErrorMessage("EXCHANGE_CHANGE_DOMAIN", ex);
}
}
}
protected void btnSetDefaultDomain_Click(object sender, EventArgs e)
@ -143,5 +174,6 @@ namespace WebsitePanel.Portal.ExchangeServer
ShowErrorMessage("EXCHANGE_SET_DEFAULT_DOMAIN", ex);
}
}
}
}

View file

@ -1,3 +1,31 @@
// Copyright (c) 2012, 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.
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
@ -110,14 +138,5 @@ namespace WebsitePanel.Portal.ExchangeServer {
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::WebsitePanel.Portal.QuotaViewer domainsQuota;
/// <summary>
/// FormComments control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.Localize FormComments;
}
}

View file

@ -45,7 +45,7 @@
<asp:ListItem Value="DisplayName" meta:resourcekey="ddlSearchColumnDisplayName">DisplayName</asp:ListItem>
<asp:ListItem Value="PrimaryEmailAddress" meta:resourcekey="ddlSearchColumnEmail">Email</asp:ListItem>
<asp:ListItem Value="AccountName" meta:resourcekey="ddlSearchColumnAccountName">AccountName</asp:ListItem>
<asp:ListItem Value="SubscriberNumber" meta:resourcekey="ddlSearchColumnSubscriberNumber">Subscriber Number</asp:ListItem>
<asp:ListItem Value="SubscriberNumber" meta:resourcekey="ddlSearchColumnSubscriberNumber">Account Number</asp:ListItem>
</asp:DropDownList><asp:TextBox ID="txtSearchValue" runat="server" CssClass="NormalTextBox" Width="100"></asp:TextBox><asp:ImageButton ID="cmdSearch" Runat="server" meta:resourcekey="cmdSearch" SkinID="SearchButton"
CausesValidation="false"/>
</asp:Panel>

View file

@ -155,14 +155,5 @@ namespace WebsitePanel.Portal.ExchangeServer {
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::WebsitePanel.Portal.QuotaViewer mailboxesQuota;
/// <summary>
/// FormComments control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.Localize FormComments;
}
}

View file

@ -68,11 +68,11 @@
</td>
</tr>
<tr>
<td class="FormLabel150"><asp:Localize ID="locSubscriberNumber" runat="server" meta:resourcekey="locSubscriberNumber" Text="Subscriber Number: *"></asp:Localize></td>
<td class="FormLabel150"><asp:Localize ID="locSubscriberNumber" runat="server" meta:resourcekey="locSubscriberNumber" Text="Account Number: *"></asp:Localize></td>
<td>
<asp:TextBox ID="txtSubscriberNumber" runat="server" CssClass="HugeTextBox200"></asp:TextBox>
<asp:RequiredFieldValidator ID="valRequireSubscriberNumber" runat="server" meta:resourcekey="valRequireSubscriberNumber" ControlToValidate="txtSubscriberNumber"
ErrorMessage="Enter Subscriber Number" ValidationGroup="CreateMailbox" Display="Dynamic" Text="*" SetFocusOnError="True"></asp:RequiredFieldValidator>
ErrorMessage="Enter Account Number" ValidationGroup="CreateMailbox" Display="Dynamic" Text="*" SetFocusOnError="True"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>

View file

@ -236,14 +236,5 @@ namespace WebsitePanel.Portal.HostedSolution {
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.ValidationSummary ValidationSummary1;
/// <summary>
/// FormComments control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.Localize FormComments;
}
}

View file

@ -46,7 +46,7 @@
<asp:ListItem Value="DisplayName" meta:resourcekey="ddlSearchColumnDisplayName">DisplayName</asp:ListItem>
<asp:ListItem Value="PrimaryEmailAddress" meta:resourcekey="ddlSearchColumnEmail">Email</asp:ListItem>
<asp:ListItem Value="AccountName" meta:resourcekey="ddlSearchColumnAccountName">AccountName</asp:ListItem>
<asp:ListItem Value="SubscriberNumber" meta:resourcekey="ddlSearchColumnSubscriberNumber">Subscriber Number</asp:ListItem>
<asp:ListItem Value="SubscriberNumber" meta:resourcekey="ddlSearchColumnSubscriberNumber">Account Number</asp:ListItem>
</asp:DropDownList><asp:TextBox ID="txtSearchValue" runat="server" CssClass="NormalTextBox" Width="100"></asp:TextBox><asp:ImageButton ID="cmdSearch" Runat="server" meta:resourcekey="cmdSearch" SkinID="SearchButton"
CausesValidation="false"/>
</asp:Panel>

View file

@ -155,14 +155,5 @@ namespace WebsitePanel.Portal.HostedSolution {
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::WebsitePanel.Portal.QuotaViewer usersQuota;
/// <summary>
/// FormComments control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.Localize FormComments;
}
}

View file

@ -54,10 +54,13 @@
<td class="SubHead"><asp:Label ID="lblRecordData" runat="server" meta:resourcekey="lblRecordData" Text="Record Data:"></asp:Label></td>
<td class="Normal" nowrap>
<asp:TextBox ID="txtRecordData" runat="server" Width="260px" CssClass="NormalTextBox"></asp:TextBox><uc1:SelectIPAddress ID="ipAddress" runat="server" />
<!--
<asp:RequiredFieldValidator ID="valRequireData" runat="server" ControlToValidate="txtRecordData"
ErrorMessage="*" ValidationGroup="DnsRecord" Display="Dynamic"></asp:RequiredFieldValidator>
-->
<asp:CustomValidator ID="IPValidator" runat="server" ControlToValidate="txtRecordData" ValidationGroup="DnsRecord" Display="Dynamic" CssClass="NormalBold"
OnServerValidate="Validate" Text="Please enter a valid IP" meta:resourcekey="IPValidator"/>
OnServerValidate="Validate" Text="Please enter a valid IP" meta:resourcekey="IPValidator" ValidateEmptyText="True" />
</td>
</tr>
<tr id="rowMXPriority" runat="server">

View file

@ -176,16 +176,23 @@ namespace WebsitePanel.Portal
}
}
protected void Validate(object source, ServerValidateEventArgs args) {
/*
var ip = args.Value;
System.Net.IPAddress ipaddr;
args.IsValid = System.Net.IPAddress.TryParse(ip, out ipaddr) && (ip.Contains(":") || ip.Contains(".")) &&
((ddlRecordType.SelectedValue == "A" && ipaddr.AddressFamily == System.Net.Sockets.AddressFamily.InterNetwork) ||
(ddlRecordType.SelectedValue == "AAAA" && ipaddr.AddressFamily == System.Net.Sockets.AddressFamily.InterNetworkV6));
if (string.IsNullOrEmpty(args.Value))
args.IsValid = true;
else
args.IsValid = System.Net.IPAddress.TryParse(ip, out ipaddr) && (ip.Contains(":") || ip.Contains(".")) &&
((ddlRecordType.SelectedValue == "A" && ipaddr.AddressFamily == System.Net.Sockets.AddressFamily.InterNetwork) ||
(ddlRecordType.SelectedValue == "AAAA" && ipaddr.AddressFamily == System.Net.Sockets.AddressFamily.InterNetworkV6));
*/
args.IsValid = true;
}
private void SaveRecord()
{
if (!Page.IsValid) return;
if (!string.IsNullOrEmpty(txtRecordData.Text))
if (!Page.IsValid) return;
GlobalDnsRecord record = new GlobalDnsRecord();
record.RecordId = (int)ViewState["RecordID"];

View file

@ -26,7 +26,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
@ -149,6 +148,24 @@ namespace WebsitePanel.Portal {
/// </remarks>
protected global::WebsitePanel.Portal.SelectIPAddress ipAddress;
/// <summary>
/// valRequireData control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.RequiredFieldValidator valRequireData;
/// <summary>
/// IPValidator control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.CustomValidator IPValidator;
/// <summary>
/// rowMXPriority control.
/// </summary>
@ -176,6 +193,24 @@ namespace WebsitePanel.Portal {
/// </remarks>
protected global::System.Web.UI.WebControls.TextBox txtMXPriority;
/// <summary>
/// valRequireMxPriority control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.RequiredFieldValidator valRequireMxPriority;
/// <summary>
/// valRequireCorrectPriority control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.RegularExpressionValidator valRequireCorrectPriority;
/// <summary>
/// rowSRVPriority control.
/// </summary>

View file

@ -249,4 +249,7 @@
<data name="lblWmSvcNETBIOS.Text" xml:space="preserve">
<value>NETBIOS Domain name:</value>
</data>
<data name="txtPublicSharedIP.Text" xml:space="preserve">
<value>Web Sites Public Shared Address:</value>
</data>
</root>

View file

@ -21,6 +21,14 @@
<uc1:SelectIPAddress ID="ipAddress" runat="server" ServerIdParam="ServerID" />
</td>
</tr>
<tr>
<td class="Normal" width="200" nowrap>
<asp:Label ID="lblPublicSharedIP" runat="server" meta:resourcekey="lblPublicSharedIP" Text="Web Sites Public Shared IP Address:"></asp:Label>
</td>
<td width="100%">
<asp:TextBox ID="txtPublicSharedIP" runat="server" Width="200" CssClass="NormalTextBox"></asp:TextBox>
</td>
</tr>
<tr>
<td class="Normal" valign="top">
<asp:Label ID="lblGroupName" runat="server" meta:resourcekey="lblGroupName" Text="Web Users Group Name:"></asp:Label>

View file

@ -107,6 +107,7 @@ namespace WebsitePanel.Portal.ProviderControls
//
ipAddress.AddressId = (settings["SharedIP"] != null) ? Utils.ParseInt(settings["SharedIP"], 0) : 0;
ipAddress.SelectValueText = GetLocalizedString("ipAddress.SelectValueText");
txtPublicSharedIP.Text = settings["PublicSharedIP"];
txtWebGroupName.Text = settings["WebGroupName"];
chkAssignIPAutomatically.Checked = Utils.ParseBool(settings["AutoAssignDedicatedIP"], true);
@ -205,6 +206,7 @@ namespace WebsitePanel.Portal.ProviderControls
{
//
settings["SharedIP"] = ipAddress.AddressId.ToString();
settings["PublicSharedIP"] = txtPublicSharedIP.Text.Trim();
settings["WebGroupName"] = txtWebGroupName.Text.Trim();
settings["AutoAssignDedicatedIP"] = chkAssignIPAutomatically.Checked.ToString();

View file

@ -67,6 +67,24 @@ namespace WebsitePanel.Portal.ProviderControls {
/// </remarks>
protected global::WebsitePanel.Portal.SelectIPAddress ipAddress;
/// <summary>
/// lblPublicSharedIP control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.Label lblPublicSharedIP;
/// <summary>
/// txtPublicSharedIP control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.TextBox txtPublicSharedIP;
/// <summary>
/// lblGroupName control.
/// </summary>

View file

@ -126,6 +126,16 @@ h2.ProductTitle {
</script>
<asp:Panel runat="server" ID="CheckLoadUserProfilePanel" Visible="False">
<div class="MessageBox Yellow">
To continue "Load User Profile" setting for the current application pool must be enabled.
<br/>
Enable this setting now? (May require relogin)
<br/>
<br/>
<asp:Button runat="server" ID="EnableLoadUserProfileButton" Text="Yes" OnClick="EnableLoadUserProfileButton_OnClick"/>
</div>
</asp:Panel>
<asp:Panel ID="SearchPanel" class="FormBody" runat="server">
@ -284,7 +294,7 @@ h2.ProductTitle {
<ContentTemplate>
<asp:Timer ID="ProgressTimer" runat="server" Enabled="False" Interval="3000" OnTick="ProgressTimerTick"></asp:Timer>
<asp:Panel ID="ProgressMessagePanel" class="FormBody" runat="server">
<h3 class="NormalBold">Selected products are installed now:</h3>
<h3 class="NormalBold">Selected products are being installed now:</h3>
<br/>
<asp:Image runat="server" ID="ProgressAnimation" ImageAlign="AbsMiddle" ImageUrl="" CssClass="ProgressAnimation"></asp:Image>
<asp:Label ID="ProgressMessage" runat="server">initializing...</asp:Label>

View file

@ -52,6 +52,33 @@ namespace WebsitePanel.Portal
{
if (!IsPostBack)
{
try
{
if (!ES.Services.Servers.CheckLoadUserProfile(PanelRequest.ServerId))
{
CheckLoadUserProfilePanel.Visible = true;
}
}
catch (NotImplementedException ex)
{
CheckLoadUserProfilePanel.Visible = false;
ShowWarningMessage("Server application pool \"Load User Profile\" setting unavailable. IIS7 or higher is expected.");
}
catch (Exception ex)
{
CheckLoadUserProfilePanel.Visible = false;
ProductsPanel.Visible = false;
keywordsList.Visible = false;
SearchPanel.Visible = false;
InstallButtons1.Visible = false;
InstallButtons2.Visible = false;
ShowErrorMessage("WPI_CHECK_LOAD_USER_PROFILE", ex);
}
try
{
ES.Services.Servers.InitWPIFeeds(PanelRequest.ServerId);
@ -582,5 +609,11 @@ namespace WebsitePanel.Portal
WpiLogsPre.InnerText = msg;
}
}
protected void EnableLoadUserProfileButton_OnClick(object sender, EventArgs e)
{
ES.Services.Servers.EnableLoadUserProfile(PanelRequest.ServerId);
CheckLoadUserProfilePanel.Visible = false;
}
}
}

View file

@ -26,7 +26,6 @@
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
@ -59,6 +58,24 @@ namespace WebsitePanel.Portal {
/// </remarks>
protected global::WebsitePanel.Portal.ServerHeaderControl ServerHeaderControl1;
/// <summary>
/// CheckLoadUserProfilePanel control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.Panel CheckLoadUserProfilePanel;
/// <summary>
/// EnableLoadUserProfileButton control.
/// </summary>
/// <remarks>
/// Auto-generated field.
/// To modify move field declaration from designer file to code-behind file.
/// </remarks>
protected global::System.Web.UI.WebControls.Button EnableLoadUserProfileButton;
/// <summary>
/// SearchPanel control.
/// </summary>

View file

@ -26,6 +26,11 @@
<td class="SubHead" nowrap><asp:Label ID="lblDomainPointers" runat="server" meta:resourcekey="lblDomainPointers" Text="Domain Pointers:"></asp:Label></td>
<td class="Normal"><wsp:Quota ID="quotaDomainPointers" runat="server" QuotaName="OS.DomainPointers" DisplayGauge="True" /></td>
</tr>
<tr ID="pnlOrganizations" runat="server">
<td class="SubHead" nowrap><asp:Label ID="lblOrganizations" runat="server" meta:resourcekey="lblOrganizations" Text="Organizations:"></asp:Label></td>
<td class="Normal"><wsp:Quota ID="quotaOrganizations" runat="server" QuotaName="HostedSolution.Organizations" DisplayGauge="True" /></td>
</tr>
<tr ID="pnlUserAccounts" runat="server">
<td class="SubHead" nowrap><asp:Label ID="lblUserAccounts" runat="server" meta:resourcekey="lblUserAccounts" Text="User Accounts:"></asp:Label></td>
<td class="Normal"><wsp:Quota ID="quotaUserAccounts" runat="server" QuotaName="HostedSolution.Users" DisplayGauge="True" /></td>

Some files were not shown because too many files have changed in this diff Show more