Category Archives: Microsoft

Sending an e-mail with PowerShell

This is really useful if you want to test if a server is able to send out an e-mail through SMTP. Or just want to schedule a task to send out an e-mail once a month, Here are the details: … Continue reading →...

Posted in Microsoft, Scripting | Leave a comment

Generating a Certificate request for a WebSite with OpenSSL

There are different ways to generate a certificate request for your site or blog. Below is an example how to create a certificate request with OpenSSL and how to convert it to a .pfx format so that it can be … Continue reading →...

Posted in Microsoft | Tagged , | Leave a comment

Implementing HTTP security Response Headers in IIS

I recently received a request from security to add security headers to a few sites that we host. Some were running on Windows 2012, Server 2008 and some on Server 2003. After some research I found that you can scan … Continue reading →...

Posted in Microsoft | Tagged , , , | Leave a comment

IIS 6 Remove “Server: Microsoft-IIS/6.0” from Response Headers

Here are quick steps how to remove the IIS6 header from a Windows Server 2003 running IIS 6. Your site may be exposing unnecessary information and security scanners in your workplace like qualys may flag it as a security risk. … Continue readi...

Posted in Microsoft | Tagged | Leave a comment

Generating a Multi-Domain CA signed SSL certificate request

One of our DEV environments had a CA signed SSL certificate with 30 Alternative names, every time a new site was added I had to re-generate the cert and an additional DNS entry. Doing it through the wizard took forever … Continue reading &rarr...

Posted in Microsoft, Scripting | Tagged , , | 1 Comment

Restart a Remote Computer

Simple command to force RESTART a remote Server. I usually run this command from the domain controller that the server belongs to. /t xxx Set the time-out period before shutdown to xxx seconds./r Full shutdown and restart the computer./f Force &helli...

Posted in Microsoft | Tagged , , , | 1 Comment

Analyzing Storage Performance issues with PerfMon

Perfmon is a built in Windows utility that measures performance, it has been introduced in Windows 3.1 and has shipped with every version of Windows ever since. I think every admin should become a little bit more familiar with it … Continue re...

Posted in Microsoft, Storage | Tagged , , , , , , , , | Leave a comment

Script to rebind an IIS site to a new IP and a new SSL cert – PowerShell

Here is a script that I used during a DR failover test. We would failover a web server to a DR side,rename it, re-ip it, rebind the SSL certs. During this process it would loose the binding as the old … Continue reading →...

Posted in Microsoft, Scripting | Tagged , , , , | Leave a comment

Batch script to replace the hosts file with another

Used this batch script as part of a DR failover. I tried different powerShell and batch scripts to replace and add entries directly into the hosts file but most were giving me too many issues. The batch script below will … Continue reading &ra...

Posted in Microsoft, Scripting | Tagged | Leave a comment