Skip to content

Instantly share code, notes, and snippets.

View robinbihun's full-sized avatar

Robin Bihun robinbihun

  • Birmingham, AL
View GitHub Profile
public class CorsHandler : DelegatingHandler
{
private const string _trustedRegex = @"((https?\:\/\/)?(.+\.)?thisismydomain\.com)|((https?\:\/\/)?localhost:[\d]+)";
protected override Task<HttpResponseMessage> SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)
{
// runs before controller
var response = base.SendAsync(request, cancellationToken);
// runs after controller
@robinbihun
robinbihun / Basic Info a Software Shop needs to Track
Created December 4, 2012 23:53
A result of a contract where nobody knows where any of the "critical" code lives, I'm gathering a list of "things" a software shop should track that will be beneficial for code/server organization and onboarding new developers. Trying to get this company
Servers (repeat as many times as needed)
Name:
IP Address(es):
Environment: [Development, Test, User Acceptance, Production]
Role(s): [Web Server, Database, Failover, etc]
Host Names: [If a web site or web services, what url(s) are used to get here]
Server Version: [Windows Server 2003, Windows Server 2008, 2008 R2, Red Hat Enterprise, etc]
Installed Software/Version: [Sql Server 2008 R2, .NET {versions}, PHP, JRE, MSMQ, IIS6, IIS7, etc]
Environment Configuration: [Any non “out of the box” configurations for Windows, IIS, SQL, etc]