Added access to privateKey and updated test cases