public async Task <int> AddClientSecretAsync(ClientSecretsDto clientSecret) { HashClientSharedSecret(clientSecret); var clientSecretEntity = clientSecret.ToEntity(); return(await _clientRepository.AddClientSecretAsync(clientSecret.ClientId, clientSecretEntity)); }
public virtual async Task <int> DeleteClientSecretAsync(ClientSecretsDto clientSecret) { var clientSecretEntity = clientSecret.ToEntity(); var deleted = await ClientRepository.DeleteClientSecretAsync(clientSecretEntity); await AuditEventLogger.LogEventAsync(new ClientSecretDeletedEvent(clientSecret.ClientId, clientSecret.ClientSecretId)); return(deleted); }
public virtual async Task <int> AddClientSecretAsync(ClientSecretsDto clientSecret) { HashClientSharedSecret(clientSecret); var clientSecretEntity = clientSecret.ToEntity(); var added = await ClientRepository.AddClientSecretAsync(clientSecret.ClientId, clientSecretEntity); await AuditEventLogger.LogEventAsync(new ClientSecretAddedEvent(clientSecret.ClientId, clientSecret.Type, clientSecret.Expiration)); return(added); }
public async Task <int> DeleteClientSecretAsync(ClientSecretsDto clientSecret) { var clientSecretEntity = clientSecret.ToEntity(); return(await _clientRepository.DeleteClientSecretAsync(clientSecretEntity)); }