Added check for the key permissions (exit)