private void UpdateClientRedirectUris(String clientId, String uri) { String server = "192.168.1.132"; String database = "Configuration_uitest"; String user = "******"; String password = "******"; String sslM = "none"; String connectionString = $"server={server};user id={user}; password={password}; database={database}; SslMode={sslM}"; MySqlConnection connection = new MySqlConnection(connectionString); connection.Open(); // Get the client identifier Int32 clientIdentifier = SecurityServiceHelper.GetClientId(connection, clientId); // Now update the client redirect uri String redirectUri = $"{uri}/signin-oidc"; SecurityServiceHelper.UpdateClientRedirectUri(connection, clientIdentifier, redirectUri); // Now update the client post logout redirect uri String postLogoutRedirectUri = $"{uri}/signout-callback-oidc"; SecurityServiceHelper.UpdateClientPostLogoutRedirectUri(connection, clientIdentifier, postLogoutRedirectUri); connection.Close(); }
private void DeleteAllRegisteredUsers() { String server = "192.168.1.132"; String database = "Authentication_uitest"; String user = "******"; String password = "******"; String sslM = "none"; String connectionString = $"server={server};user id={user}; password={password}; database={database}; SslMode={sslM}"; MySqlConnection connection = new MySqlConnection(connectionString); connection.Open(); SecurityServiceHelper.DeleteAllUsers(connection); connection.Close(); }