Detecting if API key file is regular before opening it, as well as checking for read access permissions.