modified get_new_key
renamed get_new_key