diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Code/Files/FilesController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Code/Files/FilesController.cs index 3e58f78a..7784cad8 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Code/Files/FilesController.cs +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Code/Files/FilesController.cs @@ -912,113 +912,5 @@ namespace WebsitePanel.EnterpriseServer return users.ToArray(); } - - public static int SetFolderQuota(int packageId, string path) - { - - // check account - int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive); - if (accountCheck < 0) return accountCheck; - - // check package - int packageCheck = SecurityContext.CheckPackage(packageId, DemandPackage.IsActive); - if (packageCheck < 0) return packageCheck; - - // place log record - TaskManager.StartTask("FILES", "SET_QUOTA_ON_FOLDER", path); - TaskManager.ItemId = packageId; - - try - { - - // file server cluster name - string fileServerClusterName = String.Empty; - - // Share Name where home folders are created - string shareName = String.Empty; - - string[] splits = GetHomeFolder(packageId).Split('\\'); - - if (splits.Length > 4) - { - fileServerClusterName = splits[2]; - shareName = splits[3]; - } - - // disk space quota - QuotaValueInfo diskSpaceQuota = PackageController.GetPackageQuota(packageId, Quotas.OS_DISKSPACE); - - // bat file pat - string cmdFilePath = @"\\" + fileServerClusterName + @"\" + shareName + @"\" + "Process.bat"; - - #region figure Quota Unit - - // Quota Unit - string unit = String.Empty; - if (diskSpaceQuota.QuotaDescription.ToLower().Contains("gb")) - unit = "GB"; - else if (diskSpaceQuota.QuotaDescription.ToLower().Contains("mb")) - unit = "MB"; - else - unit = "KB"; - - #endregion - - OS.OperatingSystem os = GetOS(packageId); - os.SetQuotaLimitOnFolder(cmdFilePath, fileServerClusterName, path, diskSpaceQuota.QuotaAllocatedValue.ToString() + unit, 0, String.Empty, String.Empty); - - return 0; - } - catch (Exception ex) - { - //Log and return a generic error rather than throwing an exception - TaskManager.WriteError(ex); - return BusinessErrorCodes.ERROR_FILE_GENERIC_LOGGED; - } - finally - { - TaskManager.CompleteTask(); - } - - - } - - public static int DeleteDirectoryRecursive(int packageId, string rootPath) - { - - // check account - int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive); - if (accountCheck < 0) return accountCheck; - - // check package - int packageCheck = SecurityContext.CheckPackage(packageId, DemandPackage.IsActive); - if (packageCheck < 0) return packageCheck; - - // place log record - TaskManager.StartTask("FILES", "DELETE_DIRECTORY_RECURSIVE", rootPath); - TaskManager.ItemId = packageId; - - try - { - - OS.OperatingSystem os = GetOS(packageId); - os.DeleteDirectoryRecursive(rootPath); - - return 0; - } - catch (Exception ex) - { - //Log and return a generic error rather than throwing an exception - TaskManager.WriteError(ex); - return BusinessErrorCodes.ERROR_FILE_GENERIC_LOGGED; - } - finally - { - TaskManager.CompleteTask(); - } - - - } - } } diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Code/WebServers/WebServerController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Code/WebServers/WebServerController.cs index 8966ac3a..5ea4e114 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Code/WebServers/WebServerController.cs +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Code/WebServers/WebServerController.cs @@ -157,11 +157,11 @@ namespace WebsitePanel.EnterpriseServer public static int AddWebSite(int packageId, string hostName, int domainId, int ipAddressId) { - return AddWebSite(packageId, hostName, domainId, ipAddressId, false); + return AddWebSite(packageId, hostName, domainId, ipAddressId, false, true); } public static int AddWebSite(int packageId, string hostName, int domainId, int packageAddressId, - bool addInstantAlias) + bool addInstantAlias, bool ignoreGlobalDNSRecords) { // check account int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive); @@ -180,12 +180,15 @@ namespace WebsitePanel.EnterpriseServer DomainInfo domain = ServerController.GetDomain(domainId); string domainName = domain.DomainName; - // check if the web site already exists - if (PackageController.GetPackageItemByName(packageId, domainName, typeof(WebSite)) != null) + string siteName = string.IsNullOrEmpty(hostName) ? domainName : hostName + "." + domainName; + + // check if the web site already exists (legacy) + if (PackageController.GetPackageItemByName(packageId, siteName, typeof(WebSite)) != null) return BusinessErrorCodes.ERROR_WEB_SITE_ALREADY_EXISTS; + if (DataProvider.CheckDomain(domain.PackageId, siteName, true) != 0) + return BusinessErrorCodes.ERROR_WEB_SITE_ALREADY_EXISTS; - string siteName = string.IsNullOrEmpty(hostName) ? domainName : hostName + "." + domainName; ; // place log record TaskManager.StartTask("WEB_SITE", "ADD", siteName); @@ -198,7 +201,7 @@ namespace WebsitePanel.EnterpriseServer if (serviceId == 0) return BusinessErrorCodes.ERROR_WEB_SITE_SERVICE_UNAVAILABLE; - #region Fix for bug #587 + // Initialize IIS provider webservice proxy WebServer web = new WebServer(); ServiceProviderProxy.Init(web, serviceId); @@ -216,7 +219,6 @@ namespace WebsitePanel.EnterpriseServer // Return generic operation failed error return BusinessErrorCodes.FAILED_EXECUTE_SERVICE_OPERATION; } - #endregion // load web settings StringDictionary webSettings = ServerController.GetServiceSettings(serviceId); @@ -240,13 +242,6 @@ namespace WebsitePanel.EnterpriseServer if (ip != null) ipAddr = !String.IsNullOrEmpty(ip.InternalIP) ? ip.InternalIP : ip.ExternalIP; - // load domain instant alias - /* - string instantAlias = ServerController.GetDomainAlias(packageId, domainName); - DomainInfo instantDomain = ServerController.GetDomain(instantAlias); - if (instantDomain == null || instantDomain.WebSiteId > 0) - instantAlias = ""; - */ // load web DNS records List dnsRecords = ServerController.GetDnsRecordsByService(serviceId); @@ -254,26 +249,15 @@ namespace WebsitePanel.EnterpriseServer // prepare site bindings List bindings = new List(); - if (!dedicatedIp) - { - // SHARED IP - // fill main domain bindings - /* - FillWebServerBindings(bindings, dnsRecords, ipAddr, domain.DomainName); + // SHARED IP + // fill main domain bindings + FillWebServerBindings(bindings, dnsRecords, ipAddr, hostName, domain.DomainName, ignoreGlobalDNSRecords); - // fill alias bindings if required - if (addInstantAlias && !String.IsNullOrEmpty(instantAlias)) - { - // fill bindings from DNS "A" records - FillWebServerBindings(bindings, dnsRecords, ipAddr, instantAlias); - } - */ - bindings.Add(new ServerBinding(ipAddr, "80", siteName)); - } - else + //double check all bindings + foreach (ServerBinding b in bindings) { - // DEDICATED IP - bindings.Add(new ServerBinding(ipAddr, "80", "")); + if (DataProvider.CheckDomain(domain.PackageId, b.Host, true) != 0) + return BusinessErrorCodes.ERROR_WEB_SITE_ALREADY_EXISTS; } UserInfo user = PackageController.GetPackageOwner(packageId); @@ -327,12 +311,10 @@ namespace WebsitePanel.EnterpriseServer site.EnableParentPaths = Utils.ParseBool(webPolicy["EnableParentPaths"], false); site.DedicatedApplicationPool = Utils.ParseBool(webPolicy["EnableDedicatedPool"], false); - #region Fix for bug: #1556 + // Ensure the website meets hosting plan quotas QuotaValueInfo quotaInfo = PackageController.GetPackageQuota(packageId, Quotas.WEB_APPPOOLS); site.DedicatedApplicationPool = site.DedicatedApplicationPool && (quotaInfo.QuotaAllocatedValue > 0); - - #endregion site.EnableAnonymousAccess = Utils.ParseBool(webPolicy["EnableAnonymousAccess"], false); site.EnableWindowsAuthentication = Utils.ParseBool(webPolicy["EnableWindowsAuthentication"], false); @@ -377,9 +359,6 @@ namespace WebsitePanel.EnterpriseServer // CREATE WEB SITE siteId = web.CreateSite(site); - // Set hard quota on the website content folder - FilesController.SetFolderQuota(packageId, site.DataPath); - // register item site.ServiceId = serviceId; site.PackageId = packageId; @@ -395,14 +374,9 @@ namespace WebsitePanel.EnterpriseServer // update domain // add main pointer - AddWebSitePointer(siteItemId, hostName, domain.DomainId, false); - - // add instant pointer - /* - if (addInstantAlias && !String.IsNullOrEmpty(instantAlias)) - AddWebSitePointer(siteItemId, instantDomain.DomainId, false); - */ + AddWebSitePointer(siteItemId, hostName, domain.DomainId, false, ignoreGlobalDNSRecords, false); + // add parking page // load package if (webPolicy["AddParkingPage"] != null) @@ -577,36 +551,26 @@ namespace WebsitePanel.EnterpriseServer // remove all web site pointers List pointers = GetWebSitePointers(siteItemId); foreach (DomainInfo pointer in pointers) - DeleteWebSitePointer(siteItemId, pointer.DomainId, false); + DeleteWebSitePointer(siteItemId, pointer.DomainId, false, true, true); // remove web site main pointer DomainInfo domain = ServerController.GetDomain(siteItem.Name); if(domain != null) - DeleteWebSitePointer(siteItemId, domain.DomainId, false); + DeleteWebSitePointer(siteItemId, domain.DomainId, false, true, true); // delete web site WebServer web = new WebServer(); ServiceProviderProxy.Init(web, siteItem.ServiceId); - #region Fix for bug #710 // if (web.IsFrontPageSystemInstalled() && web.IsFrontPageInstalled(siteItem.SiteId)) { web.UninstallFrontPage(siteItem.SiteId, siteItem.FrontPageAccount); } - #endregion // web.DeleteSite(siteItem.SiteId); - // Delete WebManagementAccess Account - WebServerController.RevokeWebManagementAccess(siteItemId); - - // Delete website directory from file server - // This will remove the hard quota as well - FilesController.DeleteDirectoryRecursive(siteItem.PackageId, new DirectoryInfo(siteItem.DataPath).Parent.FullName); - - // delete service item PackageController.DeletePackageItem(siteItemId); @@ -622,8 +586,119 @@ namespace WebsitePanel.EnterpriseServer } } + public static int SwitchWebSiteToDedicatedIP(int siteItemId, int ipAddressId) + { + // check account + int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive); + if (accountCheck < 0) return accountCheck; + + // load web site item + WebSite siteItem = (WebSite)PackageController.GetPackageItem(siteItemId); + if (siteItem == null) + return BusinessErrorCodes.ERROR_WEB_SITE_PACKAGE_ITEM_NOT_FOUND; + + // load assigned IP address + //IPAddressInfo ip = ServerController.GetIPAddress(ipAddressId); + //if (ip == null) + //return BusinessErrorCodes.ERROR_WEB_SITE_IP_ADDRESS_NOT_SPECIFIED; + + //string ipAddr = !String.IsNullOrEmpty(ip.InternalIP) ? ip.InternalIP : ip.ExternalIP; + int addressId = 0; + PackageIPAddress packageIp = ServerController.GetPackageIPAddress(ipAddressId); + if (packageIp != null) + { + addressId = packageIp.AddressID; + } + + + // place log record + TaskManager.StartTask("WEB_SITE", "SWITCH_TO_DEDICATED_IP", siteItem.Name); + TaskManager.ItemId = siteItemId; +/* + try + { + // remove all web site pointers + List pointers = GetWebSitePointers(siteItemId); + foreach (DomainInfo pointer in pointers) + DeleteWebSitePointer(siteItemId, pointer.DomainId, true, true, false); + + // remove web site main pointer + DomainInfo domain = ServerController.GetDomain(siteItem.Name); + if (domain != null) + DeleteWebSitePointer(siteItemId, domain.DomainId, true, true, false); + + // update site item + siteItem.SiteIPAddressId = addressId; + PackageController.UpdatePackageItem(siteItem); + + // associate IP with web site + if (addressId != 0) + ServerController.AddItemIPAddress(siteItemId, addressId); + + AddWebSitePointer(siteItemId, "", domain.DomainId, true, true, true); + + foreach (DomainInfo pointer in pointers) + AddWebSitePointer(siteItemId, "", pointer.DomainId, true, true, true); + + return 0; + } + catch (Exception ex) + { + throw TaskManager.WriteError(ex); + } + finally + { + TaskManager.CompleteTask(); + } + */ + + return 0; + } + + public static int SwitchWebSiteToSharedIP(int siteItemId) + { + // check account + int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive); + if (accountCheck < 0) return accountCheck; + + // load web site item + WebSite siteItem = (WebSite)PackageController.GetPackageItem(siteItemId); + if (siteItem == null) + return BusinessErrorCodes.ERROR_WEB_SITE_PACKAGE_ITEM_NOT_FOUND; + + // place log record + TaskManager.StartTask("WEB_SITE", "SWITCH_TO_SHARED_IP", siteItem.Name); + TaskManager.ItemId = siteItemId; +/* + try + { + // get web site pointers + var sitePointers = GetWebSitePointers(siteItemId); + + // get existing web site bindings + WebServer web = new WebServer(); + ServiceProviderProxy.Init(web, siteItem.ServiceId); + var bindings = web.GetSiteBindings(siteItem.SiteId); + + // TODO - what would be correct logic here? + + return 0; + } + catch (Exception ex) + { + throw TaskManager.WriteError(ex); + } + finally + { + TaskManager.CompleteTask(); + } + */ + return 0; + + } + private static void FillWebServerBindings(List bindings, List dnsRecords, - string ipAddr, string hostName, string domainName) + string ipAddr, string hostName, string domainName, bool ignoreGlobalDNSRecords) // TODO test if IPv6 works { int bindingsCount = bindings.Count; @@ -632,36 +707,46 @@ namespace WebsitePanel.EnterpriseServer if ((dnsRecord.RecordType == "A" || dnsRecord.RecordType == "AAAA" || dnsRecord.RecordType == "CNAME") && dnsRecord.RecordName != "*") { - /* - string recordData = dnsRecord.RecordName + - ((dnsRecord.RecordName != "") ? "." : "") + domainName; + string recordData = Utils.ReplaceStringVariable(dnsRecord.RecordName, "host_name", hostName, true); - bindings.Add(new ServerBinding(ipAddr, "80", recordData)); - */ - - string tmpName = string.Empty; - if (!String.IsNullOrEmpty(hostName)) - tmpName = Utils.ReplaceStringVariable(dnsRecord.RecordName, "host_name", hostName); - - string recordData = string.Empty; - if (tmpName.Contains(".")) - recordData = hostName; + if (!string.IsNullOrEmpty(domainName)) + recordData = recordData + ((string.IsNullOrEmpty(recordData)) ? "" : ".") + domainName; + //otherwise full recordData is supplied by hostName + + if (ignoreGlobalDNSRecords) + { + //only look for the host_nanme record, ignore all others + if (dnsRecord.RecordName == "[host_name]") + { + AddBinding(bindings, new ServerBinding(ipAddr, "80", recordData)); + break; + } + } else - recordData = tmpName + ((tmpName != "") ? "." : "") + domainName; - - bindings.Add(new ServerBinding(ipAddr, "80", recordData)); + { + AddBinding(bindings, new ServerBinding(ipAddr, "80", recordData)); + } } } - - /* - if(bindings.Count == bindingsCount) + + if ((bindings.Count == bindingsCount) | (bindings.Count == 0)) { - bindings.Add(new ServerBinding(ipAddr, "80", domainName)); - bindings.Add(new ServerBinding(ipAddr, "80", "www." + domainName)); + AddBinding(bindings, new ServerBinding(ipAddr, "80", string.IsNullOrEmpty(hostName) ? domainName : hostName + "." + domainName)); } - */ } + private static void AddBinding(List bindings, ServerBinding binding) + { + foreach (ServerBinding b in bindings) + { + if (string.Compare(b.Host, binding.Host, true) == 0) + return; + } + + bindings.Add(binding); + } + + private static string GetWebSiteUsername(UserSettings webPolicy, string domainName) { UsernamePolicy policy = new UsernamePolicy(webPolicy["AnonymousAccountPolicy"]); @@ -747,10 +832,15 @@ namespace WebsitePanel.EnterpriseServer public static int AddWebSitePointer(int siteItemId, string hostName, int domainId) { - return AddWebSitePointer(siteItemId, hostName, domainId, true); + return AddWebSitePointer(siteItemId, hostName, domainId, true, true, false); } internal static int AddWebSitePointer(int siteItemId, string hostName, int domainId, bool updateWebSite) + { + return AddWebSitePointer(siteItemId, hostName, domainId, updateWebSite, false, false); + } + + internal static int AddWebSitePointer(int siteItemId, string hostName, int domainId, bool updateWebSite, bool ignoreGlobalDNSRecords, bool rebuild) { // check account int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive); @@ -766,6 +856,13 @@ namespace WebsitePanel.EnterpriseServer if (domain == null) return BusinessErrorCodes.ERROR_DOMAIN_PACKAGE_ITEM_NOT_FOUND; + // check if the web site already exists + if (!rebuild) + { + if (DataProvider.CheckDomain(domain.PackageId, string.IsNullOrEmpty(hostName) ? domain.DomainName : hostName + "." + domain.DomainName, true) != 0) + return BusinessErrorCodes.ERROR_WEB_SITE_ALREADY_EXISTS; + } + // get zone records for the service List dnsRecords = ServerController.GetDnsRecordsByService(siteItem.ServiceId); @@ -781,16 +878,62 @@ namespace WebsitePanel.EnterpriseServer try { + + // load appropriate zone DnsZone zone = (DnsZone)PackageController.GetPackageItem(domain.ZoneItemId); + if (zone != null) { // change DNS zone + List tmpDnsRecords = new List(); + string serviceIp = (ip != null) ? ip.ExternalIP : null; - List resourceRecords = DnsServerController.BuildDnsResourceRecords( - dnsRecords, hostName, domain.DomainName, serviceIp); + if (string.IsNullOrEmpty(serviceIp)) + { + StringDictionary settings = ServerController.GetServiceSettings(siteItem.ServiceId); + if (settings["PublicSharedIP"] != null) + serviceIp = settings["PublicSharedIP"].ToString(); + } + + //filter initiat GlobaDNSRecords list + if (ignoreGlobalDNSRecords) + { + //ignore all other except the host_name record + foreach (GlobalDnsRecord r in dnsRecords) + { + if (rebuild) + { + if ((r.RecordName + (string.IsNullOrEmpty(r.RecordName) ? domain.ZoneName : "." + domain.ZoneName)) == domain.DomainName) tmpDnsRecords.Add(r); + } + else + { + if (r.RecordName == "[host_name]") tmpDnsRecords.Add(r); + } + + } + } + else + tmpDnsRecords = dnsRecords; + + + List resourceRecords = rebuild ? DnsServerController.BuildDnsResourceRecords(tmpDnsRecords, "", domain.DomainName, serviceIp): + DnsServerController.BuildDnsResourceRecords(tmpDnsRecords, hostName, domain.DomainName, serviceIp); + + if (!rebuild) + { + foreach (DnsRecord r in resourceRecords) + { + if (r.RecordName != "*") + { + // check if the web site already exists + if (DataProvider.CheckDomain(domain.PackageId, string.IsNullOrEmpty(r.RecordName) ? domain.DomainName : r.RecordName + "." + domain.DomainName, true) != 0) + return BusinessErrorCodes.ERROR_WEB_SITE_ALREADY_EXISTS; + } + } + } try { @@ -807,59 +950,60 @@ namespace WebsitePanel.EnterpriseServer } // update host headers - if (updateWebSite) + List bindings = new List(); + + // get existing web site bindings + WebServer web = new WebServer(); + ServiceProviderProxy.Init(web, siteItem.ServiceId); + + bindings.AddRange(web.GetSiteBindings(siteItem.SiteId)); + + // check if web site has dedicated IP assigned + bool dedicatedIp = bindings.Exists(binding => { return String.IsNullOrEmpty(binding.Host) && binding.IP != "*"; }); + + // update binding only for "shared" ip addresses + // add new host headers + string ipAddr = "*"; + if (ip != null) + ipAddr = !String.IsNullOrEmpty(ip.InternalIP) ? ip.InternalIP : ip.ExternalIP; + + // fill bindings + if (rebuild) + FillWebServerBindings(bindings, dnsRecords, "", domain.DomainName, "", ignoreGlobalDNSRecords); + else + FillWebServerBindings(bindings, dnsRecords, ipAddr, hostName, domain.DomainName, ignoreGlobalDNSRecords); + + //for logging purposes + foreach (ServerBinding b in bindings) { - // get existing web site bindings - WebServer web = new WebServer(); - ServiceProviderProxy.Init(web, siteItem.ServiceId); - - List bindings = new List(); - bindings.AddRange(web.GetSiteBindings(siteItem.SiteId)); - - // check if web site has dedicated IP assigned - bool dedicatedIp = bindings.Exists(binding => { return String.IsNullOrEmpty(binding.Host) && binding.IP != "*"; }); - - // update binding only for "shared" ip addresses - if (!dedicatedIp) - { - // add new host headers - string ipAddr = "*"; - if (ip != null) - ipAddr = !String.IsNullOrEmpty(ip.InternalIP) ? ip.InternalIP : ip.ExternalIP; - - // fill bindings - FillWebServerBindings(bindings, dnsRecords, ipAddr, hostName, domain.DomainName); - - foreach (ServerBinding b in bindings) - { - string header = string.Format("{0} {1} {2}", b.Host, b.IP, b.Port); - TaskManager.WriteParameter("Add Binding", b.Host); - } - - // update bindings - web.UpdateSiteBindings(siteItem.SiteId, bindings.ToArray()); - } + string header = string.Format("{0} {1} {2}", b.Host, b.IP, b.Port); + TaskManager.WriteParameter("Add Binding", header); } + // update bindings + if (updateWebSite) + web.UpdateSiteBindings(siteItem.SiteId, bindings.ToArray(), false); + // update domain - domain.WebSiteId = siteItemId; - //ServerController.UpdateDomain(domain); - if (!String.IsNullOrEmpty(hostName)) - domain.DomainName = hostName + "." + domain.DomainName; - else - domain.DomainName = domain.DomainName; - domain.IsDomainPointer = true; - int domainID = ServerController.AddDomain(domain); - - DomainInfo domainTmp = ServerController.GetDomain(domainID); - if (domainTmp != null) + if (!rebuild) { - domainTmp.WebSiteId = siteItemId; - domainTmp.ZoneItemId = domain.ZoneItemId; - ServerController.UpdateDomain(domainTmp); + domain.WebSiteId = siteItemId; + domain.IsDomainPointer = true; + foreach (ServerBinding b in bindings) + { + //add new domain record + domain.DomainName = b.Host; + int domainID = ServerController.AddDomain(domain); + DomainInfo domainTmp = ServerController.GetDomain(domainID); + if (domainTmp != null) + { + domainTmp.WebSiteId = siteItemId; + domainTmp.ZoneItemId = domain.ZoneItemId; + ServerController.UpdateDomain(domainTmp); + } + } } - return 0; } catch (Exception ex) @@ -874,10 +1018,10 @@ namespace WebsitePanel.EnterpriseServer public static int DeleteWebSitePointer(int siteItemId, int domainId) { - return DeleteWebSitePointer(siteItemId, domainId, true); + return DeleteWebSitePointer(siteItemId, domainId, true, true, true); } - public static int DeleteWebSitePointer(int siteItemId, int domainId, bool updateWebSite) + public static int DeleteWebSitePointer(int siteItemId, int domainId, bool updateWebSite, bool ignoreGlobalDNSRecords, bool deleteDomainsRecord) { // check account int accountCheck = SecurityContext.CheckAccount(DemandAccount.NotDemo | DemandAccount.IsActive); @@ -906,16 +1050,36 @@ namespace WebsitePanel.EnterpriseServer TaskManager.StartTask("WEB_SITE", "DELETE_POINTER", siteItem.Name); TaskManager.ItemId = siteItemId; TaskManager.WriteParameter("Domain pointer", domain.DomainName); + TaskManager.WriteParameter("updateWebSite", updateWebSite.ToString()); try { if (zone != null) { // change DNS zone + List tmpDnsRecords = new List(); + string serviceIp = (ip != null) ? ip.ExternalIP : null; + if (string.IsNullOrEmpty(serviceIp)) + { + StringDictionary settings = ServerController.GetServiceSettings(siteItem.ServiceId); + if (settings["PublicSharedIP"] != null) + serviceIp = settings["PublicSharedIP"].ToString(); + } + + if (ignoreGlobalDNSRecords) + { + foreach (GlobalDnsRecord r in dnsRecords) + { + if ((r.RecordName == "[host_name]") | ((r.RecordName + (string.IsNullOrEmpty(r.RecordName) ? domain.ZoneName : "." + domain.ZoneName)) == domain.DomainName)) + tmpDnsRecords.Add(r); + } + } + else tmpDnsRecords = dnsRecords; + List resourceRecords = DnsServerController.BuildDnsResourceRecords( - dnsRecords, domain.DomainName, "", serviceIp); + tmpDnsRecords, domain.DomainName, "", serviceIp); try { @@ -929,43 +1093,41 @@ namespace WebsitePanel.EnterpriseServer } } + // get existing web site bindings + WebServer web = new WebServer(); + ServiceProviderProxy.Init(web, siteItem.ServiceId); + + List bindings = new List(); + bindings.AddRange(web.GetSiteBindings(siteItem.SiteId)); + + // check if web site has dedicated IP assigned + bool dedicatedIp = bindings.Exists(binding => { return String.IsNullOrEmpty(binding.Host) && binding.IP != "*"; }); + + // update binding only for "shared" ip addresses + + // remove host headers + List domainBindings = new List(); + FillWebServerBindings(domainBindings, dnsRecords, "", domain.DomainName, "", ignoreGlobalDNSRecords); + + // fill to remove list + List headersToRemove = new List(); + foreach (ServerBinding domainBinding in domainBindings) + headersToRemove.Add(domainBinding.Host); + + // remove bndings + bindings.RemoveAll(b => { return headersToRemove.Contains(b.Host) && b.Port == "80"; } ); + + // update bindings if (updateWebSite) - { - // get existing web site bindings - WebServer web = new WebServer(); - ServiceProviderProxy.Init(web, siteItem.ServiceId); - - List bindings = new List(); - bindings.AddRange(web.GetSiteBindings(siteItem.SiteId)); - - // check if web site has dedicated IP assigned - bool dedicatedIp = bindings.Exists(binding => { return String.IsNullOrEmpty(binding.Host) && binding.IP != "*"; }); - - // update binding only for "shared" ip addresses - if (!dedicatedIp) - { - // remove host headers - List domainBindings = new List(); - FillWebServerBindings(domainBindings, dnsRecords, "", domain.DomainName, ""); - - // fill to remove list - List headersToRemove = new List(); - foreach (ServerBinding domainBinding in domainBindings) - headersToRemove.Add(domainBinding.Host); - - // remove bndings - bindings.RemoveAll(b => { return headersToRemove.Contains(b.Host) && b.Port == "80"; } ); - - // update bindings - web.UpdateSiteBindings(siteItem.SiteId, bindings.ToArray()); - } - } + web.UpdateSiteBindings(siteItem.SiteId, bindings.ToArray(), true); // update domain domain.WebSiteId = 0; - ServerController.UpdateDomain(domain); - ServerController.DeleteDomain(domain.DomainId); - + if (deleteDomainsRecord) + { + ServerController.UpdateDomain(domain); + ServerController.DeleteDomain(domain.DomainId); + } return 0; } catch (Exception ex) diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Web.config b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Web.config index 56350e5d..a99cd490 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Web.config +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/Web.config @@ -1,56 +1,56 @@ - + -
+
- + - + - + - + - + - + - + - + - - - + + + - + - + - + - - + + - + - + \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/WebsitePanel.EnterpriseServer.csproj b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/WebsitePanel.EnterpriseServer.csproj index ac8ea558..52285130 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/WebsitePanel.EnterpriseServer.csproj +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/WebsitePanel.EnterpriseServer.csproj @@ -19,11 +19,6 @@ v4.0 - false - - - - true @@ -415,7 +410,6 @@ - diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/OS/IOperatingSystem.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/OS/IOperatingSystem.cs index add15c94..fc9f3076 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/OS/IOperatingSystem.cs +++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/OS/IOperatingSystem.cs @@ -28,7 +28,6 @@ using System; using System.Collections; -using System.IO; namespace WebsitePanel.Providers.OS { @@ -82,8 +81,5 @@ namespace WebsitePanel.Providers.OS // Synchronizing FolderGraph GetFolderGraph(string path); void ExecuteSyncActions(FileSyncAction[] actions); - void SetQuotaLimitOnFolder(string cmdFilePath, string virtualFileClusterName, string folderPath, string quotaLimit, int mode, string wmiUserName, string wmiPassword); - void DeleteDirectoryRecursive(string rootPath); - } } diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj b/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj index 137151d2..b8623bcf 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj +++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj @@ -80,6 +80,7 @@ + @@ -92,11 +93,6 @@ - - True - True - Settings.settings - @@ -317,10 +313,6 @@ - - SettingsSingleFileGenerator - Settings.Designer.cs - diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.OS.Windows2003/Windows2003.cs b/WebsitePanel/Sources/WebsitePanel.Providers.OS.Windows2003/Windows2003.cs index 1d37b8b3..f251bd66 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.OS.Windows2003/Windows2003.cs +++ b/WebsitePanel/Sources/WebsitePanel.Providers.OS.Windows2003/Windows2003.cs @@ -209,17 +209,6 @@ namespace WebsitePanel.Providers.OS SecurityUtils.GrantGroupNtfsPermissions(path, users, resetChildPermissions, ServerSettings, usersOU, null); } - - public virtual void SetQuotaLimitOnFolder(string cmdFilePath, string virtualFileClusterName, string folderPath, string quotaLimit, int mode, string wmiUserName, string wmiPassword) - { - FileUtils.SetQuotaLimitOnFolder(cmdFilePath, virtualFileClusterName, folderPath, quotaLimit, mode, wmiUserName, wmiPassword); - } - - public virtual void DeleteDirectoryRecursive(string rootPath) - { - FileUtils.DeleteDirectoryRecursive(rootPath); - } - #endregion #region ODBC DSNs diff --git a/WebsitePanel/Sources/WebsitePanel.Server.Client/OperatingSystemProxy.cs b/WebsitePanel/Sources/WebsitePanel.Server.Client/OperatingSystemProxy.cs index 34be86c2..f40b6d59 100644 --- a/WebsitePanel/Sources/WebsitePanel.Server.Client/OperatingSystemProxy.cs +++ b/WebsitePanel/Sources/WebsitePanel.Server.Client/OperatingSystemProxy.cs @@ -61,10 +61,6 @@ namespace WebsitePanel.Providers.OS { private System.Threading.SendOrPostCallback CreatePackageFolderOperationCompleted; private System.Threading.SendOrPostCallback FileExistsOperationCompleted; - - private System.Threading.SendOrPostCallback SetQuotaLimitOnFolderOperationCompleted; - - private System.Threading.SendOrPostCallback DeleteDirectoryRecursiveOperationCompleted; private System.Threading.SendOrPostCallback DirectoryExistsOperationCompleted; @@ -135,8 +131,7 @@ namespace WebsitePanel.Providers.OS { private System.Threading.SendOrPostCallback UpdateDSNOperationCompleted; private System.Threading.SendOrPostCallback DeleteDSNOperationCompleted; - - + /// public OperatingSystem() { this.Url = "http://localhost/Server/OperatingSystem.asmx"; @@ -147,12 +142,6 @@ namespace WebsitePanel.Providers.OS { /// public event FileExistsCompletedEventHandler FileExistsCompleted; - - /// - public event SetQuotaLimitOnFolderCompletedEventHandler SetQuotaLimitOnFolderCompleted; - - /// - public event DeleteDirectoryRecursiveCompletedEventHandler DeleteDirectoryRecursiveCompleted; /// public event DirectoryExistsCompletedEventHandler DirectoryExistsCompleted; @@ -342,107 +331,6 @@ namespace WebsitePanel.Providers.OS { this.FileExistsCompleted(this, new FileExistsCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState)); } } - - /// - [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")] - [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/SetQuotaLimitOnFolder", RequestNamespace = "http://smbsaas/websitepanel/server/", ResponseNamespace = "http://smbsaas/websitepanel/server/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)] - public bool SetQuotaLimitOnFolder(string cmdFilePath, string virtualFileClusterName, string folderPath, string quotaLimit, int mode, string wmiUserName, string wmiPassword) - { - object[] results = this.Invoke("SetQuotaLimitOnFolder", new object[] { - cmdFilePath, virtualFileClusterName, folderPath, quotaLimit, mode, wmiUserName, wmiPassword}); - return ((bool)(results[0])); - } - - /// - public System.IAsyncResult BeginSetQuotaLimitOnFolder(string cmdFilePath, string virtualFileClusterName, string folderPath, string quotaLimit, int mode, string wmiUserName, string wmiPassword, System.AsyncCallback callback, object asyncState) - { - return this.BeginInvoke("SetQuotaLimitOnFolder", new object[] { - cmdFilePath, virtualFileClusterName, folderPath, quotaLimit, mode, wmiUserName, wmiPassword}, callback, asyncState); - } - - /// - public bool EndSetQuotaLimitOnFolder(System.IAsyncResult asyncResult) - { - object[] results = this.EndInvoke(asyncResult); - return ((bool)(results[0])); - } - - /// - public void SetQuotaLimitOnFolderAsync(string cmdFilePath, string virtualFileClusterName, string folderPath, string quotaLimit, int mode, string wmiUserName, string wmiPassword) - { - this.SetQuotaLimitOnFolderAsync(cmdFilePath, virtualFileClusterName, folderPath, quotaLimit, mode, wmiUserName, wmiPassword, null); - } - - /// - public void SetQuotaLimitOnFolderAsync(string cmdFilePath, string virtualFileClusterName, string folderPath, string quotaLimit, int mode, string wmiUserName, string wmiPassword, object userState) - { - if ((this.SetQuotaLimitOnFolderOperationCompleted == null)) - { - this.SetQuotaLimitOnFolderOperationCompleted = new System.Threading.SendOrPostCallback(this.OnSetQuotaLimitOnFolderOperationCompleted); - } - this.InvokeAsync("SetQuotaLimitOnFolder", new object[] { - cmdFilePath, virtualFileClusterName, folderPath, quotaLimit, mode, wmiUserName, wmiPassword}, this.SetQuotaLimitOnFolderOperationCompleted, userState); - } - - private void OnSetQuotaLimitOnFolderOperationCompleted(object arg) - { - if ((this.SetQuotaLimitOnFolderCompleted != null)) - { - System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg)); - this.SetQuotaLimitOnFolderCompleted(this, new SetQuotaLimitOnFolderCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState)); - } - } - - /// - [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")] - [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/DeleteDirectoryRecursive", RequestNamespace = "http://smbsaas/websitepanel/server/", ResponseNamespace = "http://smbsaas/websitepanel/server/", Use = System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle = System.Web.Services.Protocols.SoapParameterStyle.Wrapped)] - public bool DeleteDirectoryRecursive(string rootPath) - { - object[] results = this.Invoke("DeleteDirectoryRecursive", new object[] { - rootPath }); - return ((bool)(results[0])); - } - - /// - public System.IAsyncResult BeginDeleteDirectoryRecursive(string rootPath, System.AsyncCallback callback, object asyncState) - { - return this.BeginInvoke("DeleteDirectoryRecursive", new object[] { - rootPath}, callback, asyncState); - } - - /// - public bool EndDeleteDirectoryRecursive(System.IAsyncResult asyncResult) - { - object[] results = this.EndInvoke(asyncResult); - return ((bool)(results[0])); - } - - /// - public void DeleteDirectoryRecursiveAsync(string rootPath) - { - this.DeleteDirectoryRecursiveAsync(rootPath, null); - } - - /// - public void DeleteDirectoryRecursiveAsync(string rootPath, object userState) - { - if ((this.DeleteDirectoryRecursiveOperationCompleted == null)) - { - this.DeleteDirectoryRecursiveOperationCompleted = new System.Threading.SendOrPostCallback(this.OnDeleteDirectoryRecursiveOperationCompleted); - } - this.InvokeAsync("DeleteDirectoryRecursive", new object[] { - rootPath}, this.DeleteDirectoryRecursiveOperationCompleted, userState); - } - - private void OnDeleteDirectoryRecursiveOperationCompleted(object arg) - { - if ((this.DeleteDirectoryRecursiveCompleted != null)) - { - System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg)); - this.DeleteDirectoryRecursiveCompleted(this, new DeleteDirectoryRecursiveCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState)); - } - } - /// [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")] @@ -2011,67 +1899,6 @@ namespace WebsitePanel.Providers.OS { } } } - - /// - [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")] - public delegate void SetQuotaLimitOnFolderCompletedEventHandler(object sender, SetQuotaLimitOnFolderCompletedEventArgs e); - - /// - [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")] - [System.Diagnostics.DebuggerStepThroughAttribute()] - [System.ComponentModel.DesignerCategoryAttribute("code")] - public partial class SetQuotaLimitOnFolderCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs - { - - private object[] results; - - internal SetQuotaLimitOnFolderCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) : - base(exception, cancelled, userState) - { - this.results = results; - } - - /// - public bool Result - { - get - { - this.RaiseExceptionIfNecessary(); - return ((bool)(this.results[0])); - } - } - } - - /// - [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")] - public delegate void DeleteDirectoryRecursiveCompletedEventHandler(object sender, DeleteDirectoryRecursiveCompletedEventArgs e); - - /// - [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")] - [System.Diagnostics.DebuggerStepThroughAttribute()] - [System.ComponentModel.DesignerCategoryAttribute("code")] - public partial class DeleteDirectoryRecursiveCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs - { - - private object[] results; - - internal DeleteDirectoryRecursiveCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) : - base(exception, cancelled, userState) - { - this.results = results; - } - - /// - public bool Result - { - get - { - this.RaiseExceptionIfNecessary(); - return ((bool)(this.results[0])); - } - } - } - /// [System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")] diff --git a/WebsitePanel/Sources/WebsitePanel.Server.Utils/FileUtils.cs b/WebsitePanel/Sources/WebsitePanel.Server.Utils/FileUtils.cs index 06433897..f30354a5 100644 --- a/WebsitePanel/Sources/WebsitePanel.Server.Utils/FileUtils.cs +++ b/WebsitePanel/Sources/WebsitePanel.Server.Utils/FileUtils.cs @@ -37,7 +37,6 @@ using System.Collections.Generic; using System.Reflection; using Ionic.Zip; using WebsitePanel.Providers.OS; -using System.Management; namespace WebsitePanel.Providers.Utils { @@ -845,126 +844,6 @@ namespace WebsitePanel.Providers.Utils conn, null); cat = null; } - - public static void DeleteDirectoryRecursive(string rootPath) - { - // This code is done this way to force folder deletion - // even if the folder was opened - - DirectoryInfo treeRoot = new DirectoryInfo(rootPath); - if (treeRoot.Exists) - { - - DirectoryInfo[] dirs = treeRoot.GetDirectories(); - while (dirs.Length > 0) - { - foreach (DirectoryInfo dir in dirs) - DeleteDirectoryRecursive(dir.FullName); - - dirs = treeRoot.GetDirectories(); - } - - // DELETE THE FILES UNDER THE CURRENT ROOT - string[] files = Directory.GetFiles(treeRoot.FullName); - foreach (string file in files) - { - File.SetAttributes(file, FileAttributes.Normal); - File.Delete(file); - } - - Directory.Delete(treeRoot.FullName, true); - } - - - } - - public static void SetQuotaLimitOnFolder(string cmdFilePath, string virtualFileClusterName, string folderPath, string quotaLimit, int mode, string wmiUserName, string wmiPassword) - { - try - { - string[] splits = folderPath.Split('\\'); - if (splits.Length > 0) - { - // Creating the BAT file - FileStream fs = File.Create(cmdFilePath); - if (fs != null) - { - fs.Close(); - fs.Dispose(); - } - - StreamWriter swr = new StreamWriter(cmdFilePath); - - if (swr != null) - { - swr.WriteLine(@"cd c:\windows\system32"); - - string[] shareDrive = { }; - string sharePath = String.Empty; - - if (splits.Length > 4) - { - // Check the share name if it's not an empty string - if (splits[3].Length > 0) - shareDrive = splits[3].Split('_'); - - // Form the share physicalPath - if (shareDrive.Length == 2) - sharePath = shareDrive[1] + @":\" + splits[3]; - - if (splits.Length == 7 && !quotaLimit.Equals(String.Empty)) - { - splits[6] = "wwwroot"; - - switch (mode) - { - // Set - case 0: swr.WriteLine(@"dirquota quota add /path:" + sharePath + @"\" + splits[4] + @"\" + splits[5] + @"\" + splits[6] + @" /limit:" + quotaLimit + @" /remote:" + splits[2]); - break; - - // Modify - case 1: swr.WriteLine(@"dirquota quota modify /path:" + sharePath + @"\" + splits[4] + @"\" + splits[5] + @"\" + splits[6] + @" /limit:" + quotaLimit + @" /remote:" + splits[2]); - break; - } - } - - - } - swr.Flush(); - swr.Close(); - swr.Dispose(); - } - - ConnectionOptions connOptions = new ConnectionOptions(); - - if (wmiUserName.Length > 0) - { - connOptions.Username = wmiUserName; - connOptions.Password = wmiPassword; - } - - connOptions.Impersonation = ImpersonationLevel.Impersonate; - - connOptions.EnablePrivileges = true; - - ManagementScope manScope = - new ManagementScope(String.Format(@"\\{0}\ROOT\CIMV2", virtualFileClusterName), connOptions); - manScope.Connect(); - - ObjectGetOptions objectGetOptions = new ObjectGetOptions(); - ManagementPath managementPath = new ManagementPath("Win32_Process"); - ManagementClass processClass = new ManagementClass(manScope, managementPath, objectGetOptions); - - ManagementBaseObject inParams = processClass.GetMethodParameters("Create"); - inParams["CommandLine"] = cmdFilePath; - ManagementBaseObject outParams = processClass.InvokeMethod("Create", inParams, null); - - } - } - catch - { } - } - #region Advanced Delete /// /// Deletes the specified file. diff --git a/WebsitePanel/Sources/WebsitePanel.Server/OperatingSystem.asmx.cs b/WebsitePanel/Sources/WebsitePanel.Server/OperatingSystem.asmx.cs index d226536f..e258900a 100644 --- a/WebsitePanel/Sources/WebsitePanel.Server/OperatingSystem.asmx.cs +++ b/WebsitePanel/Sources/WebsitePanel.Server/OperatingSystem.asmx.cs @@ -533,39 +533,6 @@ namespace WebsitePanel.Server throw; } } - - - [WebMethod, SoapHeader("settings")] - public void SetQuotaLimitOnFolder(string cmdFilePath, string virtualFileClusterName, string folderPath, string quotaLimit, int mode, string wmiUserName, string wmiPassword) - { - try - { - Log.WriteStart("'{0}' SetQuotaLimitOnFolder", ProviderSettings.ProviderName); - OsProvider.SetQuotaLimitOnFolder(cmdFilePath, virtualFileClusterName, folderPath, quotaLimit, mode, wmiUserName, wmiPassword); - Log.WriteEnd("'{0}' SetQuotaLimitOnFolder", ProviderSettings.ProviderName); - } - catch (Exception ex) - { - Log.WriteError(String.Format("'{0}' SetQuotaLimitOnFolder", ProviderSettings.ProviderName), ex); - throw; - } - } - - [WebMethod, SoapHeader("settings")] - public void DeleteDirectoryRecursive(string rootPath) - { - try - { - Log.WriteStart("'{0}' DeleteDirectoryRecursive", ProviderSettings.ProviderName); - OsProvider.DeleteDirectoryRecursive(rootPath); - Log.WriteEnd("'{0}' DeleteDirectoryRecursive", ProviderSettings.ProviderName); - } - catch (Exception ex) - { - Log.WriteError(String.Format("'{0}' DeleteDirectoryRecursive", ProviderSettings.ProviderName), ex); - throw; - } - } #endregion #region Synchronizing diff --git a/WebsitePanel/Sources/WebsitePanel.Server/Web.config b/WebsitePanel/Sources/WebsitePanel.Server/Web.config index f4c59fb4..48568b3a 100644 --- a/WebsitePanel/Sources/WebsitePanel.Server/Web.config +++ b/WebsitePanel/Sources/WebsitePanel.Server/Web.config @@ -44,7 +44,7 @@ - + diff --git a/WebsitePanel/Sources/WebsitePanel.Server/WebsitePanel.Server.csproj b/WebsitePanel/Sources/WebsitePanel.Server/WebsitePanel.Server.csproj index 5c4731db..890ebc21 100644 --- a/WebsitePanel/Sources/WebsitePanel.Server/WebsitePanel.Server.csproj +++ b/WebsitePanel/Sources/WebsitePanel.Server/WebsitePanel.Server.csproj @@ -20,10 +20,6 @@ v3.5 false - - - - true @@ -235,7 +231,6 @@ - diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/WebsitePanel.WebPortal.csproj b/WebsitePanel/Sources/WebsitePanel.WebPortal/WebsitePanel.WebPortal.csproj index e852620d..c93b1a73 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/WebsitePanel.WebPortal.csproj +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/WebsitePanel.WebPortal.csproj @@ -241,7 +241,6 @@ -