Skip to content

Instantly share code, notes, and snippets.

View ryanrousseau's full-sized avatar
🏠
Working from home

Ryan Rousseau ryanrousseau

🏠
Working from home
View GitHub Profile
#print hello world
Console.WriteLine("Done");
using System;
using ScriptCs.Contracts;
namespace ScriptCs.Exec
{
public class PrintLinePreprocessor : DirectiveLineProcessor
{
public PrintLinePreprocessor()
{
Console.WriteLine("PrintLinePreprocessor created");
using System;
using ScriptCs.Contracts;
namespace ScriptCs.Exec
{
[Module("print", Extensions = "csx")]
public class PrintModule : IModule
{
public void Initialize(IModuleConfiguration config)
{
@ryanrousseau
ryanrousseau / OAuth2Authorize.cs
Created June 22, 2012 13:30
OAuth2 Authorize Attribute for MVC Web API
using System;
using System.Net;
using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using System.Security.Principal;
using System.ServiceModel.Channels;
using System.Threading;
using System.Web.Http;
using System.Web.Http.Controllers;
using System.Web.Http.Filters;