Implementing barebones authentication layer.