Added separate providers for IIS 8 and FTP 8
This commit is contained in:
parent
d72e715ee6
commit
d826a96f6d
12 changed files with 271 additions and 16 deletions
|
@ -0,0 +1,35 @@
|
|||
using Microsoft.Win32;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
|
||||
namespace WebsitePanel.Providers.FTP
|
||||
{
|
||||
public class MsFTP80 : MsFTP
|
||||
{
|
||||
protected new 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();
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue