IIS 7.5 and IIS 8.0 European Hosting

BLOG about IIS 7.5 Hosting, IIS 8.0 Hosting and Its Technology - Dedicated to European Windows Hosting Customer

European IIS 8 Hosting - how to setup IIS ISAPI CGI Restriction with powershell

clock October 3, 2013 10:48 by author Ronny

There are several ways to enable IIS ISAPI CGI Restrictions. Enabling this feature can be directly in IIS or using Powershell. This section will explain How can enable IIS ISAPI CGI Restrictions with Powershell. Here below is the script for Powershell.

Import-Module webadministration 

function Is64Bit 
 { 
      [IntPtr]::Size -eq 8 

 }

 function EnableIsapiRestriction($isapiPath){ 

 $isapiConfiguration = get-webconfiguration "/system.webServer/security/isapiCgiRestriction/add[@path='$isapiPath']/@allowed" 

if (!$isapiConfiguration.value){ 

set-webconfiguration "/system.webServer/security/isapiCgiRestriction/add[@path='$isapiPath']/@allowed" -value "True" -PSPath:IIS:\ 

Write-Host "Enabled ISAPI - $isapiPath " -ForegroundColor Green 
 } 
 } 

    function EnableDotNet40Isapi($systemArchitecture){ 

$frameworkPath = "$env:windir\Microsoft.NET\Framework$systemArchitecture\v4.0.30319\aspnet_isapi.dll"

EnableIsapiRestriction $frameworkPath      
 } 

    function Main(){ 

if (Is64Bit){ 

EnableDotNet40Isapi "64" 


EnableDotNet40Isapi 

    Main

Now IIS ISAPI CGI Restrictions have been active. Happy programming!



SSL Installation issue on Windows 2008r2: How to Fix a “CertEnroll::CX509Enrollment::p_InstallResponse: ASN1” Certificate Private Key Error

clock September 18, 2013 08:17 by author Ronny

This error means that the private key does not match the public key (the .crt file).  The keypair is not successfully joined into a working SSL certificate.

 

Here solution to resolve this error

1. (Start button -> RUN -> Type : MMC)

2. Choose Tab “File”

3. Add/Remove Snap-ins -> certificates and click “Add >”.

4. Select “Computer account” and Finish. OK

 

5. Personal > Certificates >  right-click and select All Tasks > select Import > guide to the .crt file.)

6. Double-click the crt certificate file you just imported -> select the Details tab, scroll all the way down to Thumbprint and highlight Thumbprint.

7. In the lower pane, block and copy all the letters of the thumbprint.  Paste the thumbprint characters into notepad.  Open the command prompt and run this command: Certutil /?

8. The command you’ll want to run is:

certutil -repairstore my “{PASTE THE CODE }”

9. When you see “CertUtil: -repairstore command completed successfully” the private key will be associated with the .CRT file in the personal store. The certificate should show up in IIS 7.5 under Server Certificates.

10. Now you should be able to assign the SSL certificate to the appropriate website(s).



About HostForLIFE.eu

HostForLIFE.eu is European Windows Hosting Provider which focuses on Windows Platform only. We deliver on-demand hosting solutions including Shared hosting, Reseller Hosting, Cloud Hosting, Dedicated Servers, and IT as a Service for companies of all sizes.

We have offered the latest Windows 2016 Hosting, ASP.NET Core 2.2.1 Hosting, ASP.NET MVC 6 Hosting and SQL 2017 Hosting.


Tag cloud

Sign in