2020-02-23

Time-based One Time Password

A nice easy-to-use RFC-6238 based algorithm, that provides a HMAC-based One-Time Password authentication. The algorithm is based on one outlined in this article here. The interval is in seconds. It dictates how long before a TOTP expires. For example, if a TOTP is generated at 14:20 and the interval is 120 seconds. The TOTP will […]

Read More…

2018-02-18

Random AlphaNumeric Generator

Recently I needed to write a simple¬†token¬†generator for a project. In order to make it print-friendly and easy to read, I decided to make it an uppercase alphanumeric string. The code uses the ASCII (American Standard Code for Information Interchange) numeric representation of the character. A-Z (uppercase) is any number between 65 and 90. To […]

Read More…

2017-08-16

YubiKey OTP Implementation

In this article, I will be focussing on YubiKeys that are made by a Company called Yubico. Yubico offer a number of different styles of hardware based on two-factor authentication devices. In my case, I have been implementing the YubiKey 4, using their OTP (one time password) authentication API. Firstly, it is important to understand […]

Read More…