2 minutes read

Working with Certificates in Code

Just a quick little collection of useful code snippets when dealing with certificates.  Some of these don’t really need to be in their own methods but it helps for clarification. Namespaces for Everything using System.Security.Cryptography.X509Certificates; using System.Security; Save Certificate to Store // Nothing fancy here. Just a helper method to parse strings. private StoreName parseStoreName(string name) { return (StoreName)Enum.Parse(typeof(StoreName), name); } // Same here private StoreLocation parseStoreLocation(string location) { return (StoreLocation)Enum.Parse(typeof(StoreLocation), location); } private void saveCertToStore(X509Certificate2 x509Certificate2, StoreName storeName, StoreLocation storeLocation) { X509Store store = new X509Store(storeName, storeLocation); store.Open(OpenFlags.ReadWrite); store.Add(x509Certificate2); store.Close(); } Create Certificate from byte[] array private X509Certificate2 CreateCertificateFromByteArray(byte[]…

10 minutes read

Security, Security, Security is about Policy, Policy, Policy

The other day I had the opportunity to take part in an interesting meeting with Microsoft. The discussion was security, and the meeting members were 20 or so IT Pro’s, developers, and managers from various Fortune 500 companies in the GTA. It was not a sales call. Throughout the day, Microsofties Rob Labbe and Mohammad Akif went into significant detail about the current threat landscape facing all technology vendors and departments. There was one point that was paramount. Security is not all about technology. Security is about the policies implemented at the human level. Blinky-lighted devices look cool, but in…

5 minutes read

Security, Architecture, and Common Sense

Good enough is sometimes not good enough.  I’ve been doing a lot of thinking lately (well, I’m always thinking), and security has been an issue that has come up a lot.  Frankly, I’m a two-bit software developer.  I know my code isn’t the best, nor the most secure.  I use strong passwords, encrypt my sensitive data, and try to limit access to the applications for those who need to use it. In theory this works.  Problem is, it’s a lame theory.  There are so many unknown factors that have to be taken into account.  Often times they aren’t. When I…

4 minutes read

Windows LiveID Almost OpenID

The Windows Live team announced a few months ago that their Live ID service will be a new provider for the OpenID system.  The Live team was quoted: Beginning today, Windows Live™ ID is publicly committing to support the OpenID digital identity framework with the announcement of the public availability of a Community Technology Preview (CTP) of the Windows Live ID OpenID Provider. You will soon be able to use your Windows Live ID account to sign in to any OpenID Web site. I saw the potential in OpenID a while ago, long before I heard about Microsoft’s intentions.  The…