removed exit statement, moved checkSignature to invoker method