Error checkings for signature computation.