added license header
refactored and enhanced Security domain model to support consecutive
failed auth attempts and credentials that expire
added more unit testing