This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$PSPath = 'MACHINE/WEBROOT/APPHOST/' + $WebsiteName | |
$Filter = 'system.webServer/httpProtocol/customHeaders' | |
# Ensure working with IIS 7 and 7.5(+?) | |
try { | |
Add-PSSnapin WebAdministration | |
} | |
catch { | |
try { | |
Import-Module WebAdministration |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Net.NetworkInformation; | |
namespace ServiceLayer.Utilities.Identity | |
{ | |
/// <summary> | |
/// Class used to get a unique machine identifier | |
/// </summary> | |
public static class MachineIdentifier | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// <summary> | |
/// Base class for Import/Export ModelState From/To TempData action filters | |
/// </summary> | |
public abstract class ModelStateTempDataAttribute : ActionFilterAttribute | |
{ | |
protected static readonly string Key = typeof(ModelStateTempDataAttribute).FullName; | |
} | |
/// <summary> | |
/// Import ModelState from previous ActionMethod from TempData |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// <summary> | |
/// This is just a helper class to make resolving dependencies manually a bit tidier | |
/// </summary> | |
public static class WebApiDependencyResolver | |
{ | |
/// <summary> | |
/// Use configured WebApi DependencyResolver to resolve dependency of type T. | |
/// </summary> | |
/// <typeparam name="T"></typeparam> | |
/// <returns></returns> |
NewerOlder