Programming

ASP.NET Core API Routing

ASP.NET Core API Routing When creating a new API controller in a Web Application the template code created if you choose to include read/write actions provides a good overview of how to pass values through to the API methods and return results. The template assumes that the controller only has Read more…

By Shinigami, ago
Programming

Cryptographically Secure Random Number

Cryptographically Secure Random Number In a similar vein to my attempt to generate a cryptographically secure random string I also wanted to be able to create cryptographically secure random numbers. The below function is taken from the post here. public static int GetRandomInteger(int min = 0, int max = int.MaxValue) Read more…

By Shinigami, ago
Programming

Pre-Populating Social Sharing Messages

Pre-Populating Social Sharing Messages Sharing buttons on a site can be configured to pre-populate content through various sharing channels such as email, Facebook and Twitter, though unfortunately this doesn’t seem to be that well documented. The below examples show how to pre-compose a message to be sent by Outlook.com, Yahoo, Read more…

By Shinigami, ago
Programming

Cryptographically Secure Random String

Cryptographically Secure Random String I’ve been trying to generate unique referal codes composed of uppercase letters for a project and although it’s not really necessary I wanted to make these as cryptographically sound as possible so I could reuse the code later in a personal password generator project. Turns out Read more…

By Shinigami, ago