added logic for validating license.