Fixed secret key compatibility issues with secret key.