public string GetNewAppId() { bool check = false; string appId = ""; while (!check) { var tryAppId = BsUtils._RandomString(40); if (_dpAuth.GetAuthByIdApp(tryAppId) == null) { check = true; appId = tryAppId; } } return(appId); }
public string GetNewState() { bool check = false; string state = ""; while (!check) { var tryState = BsUtils._RandomString(40); if (_dpAuth.GetAuthByState(tryState) == null) { check = true; state = tryState; } } return(state); }