Auth: Some modifications to simplify obtaining ids.