Skip to content

Instantly share code, notes, and snippets.

View davecluderay's full-sized avatar

Dave Cluderay davecluderay

  • UK
View GitHub Profile
@davecluderay
davecluderay / ShellLink.cs
Created March 17, 2015 14:54
Resolves shell links
@davecluderay
davecluderay / KilnUrlHandler.cs
Last active August 29, 2015 14:04
Handles kiln:// URLs, translating them into the full http(s) form before executing them.
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.InteropServices;
using System.Text;
using System.Text.RegularExpressions;
using System.Windows.Forms;
@davecluderay
davecluderay / PublicKeyToken.cs
Created July 4, 2014 13:34
Generate a public key token from an X.509 certificate (for use in ClickOnce manifests).
using System;
using System.ComponentModel;
using System.Runtime.InteropServices;
using System.Security.Cryptography.X509Certificates;
public static class PublicKeyToken
{
public static string FromCertificate(X509Certificate cert)
{
var publicKeyBlob = GetCspPublicKeyBlob(cert);