Some checks failed
		
		
	
	Build Test Deploy / build-test (push) Has been cancelled
				
			Build Test Deploy / authority-container (push) Has been cancelled
				
			Build Test Deploy / docs (push) Has been cancelled
				
			Build Test Deploy / deploy (push) Has been cancelled
				
			Docs CI / lint-and-preview (push) Has been cancelled
				
			
		
			
				
	
	
		
			25 lines
		
	
	
		
			872 B
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			25 lines
		
	
	
		
			872 B
		
	
	
	
		
			C#
		
	
	
	
	
	
| using Microsoft.Extensions.DependencyInjection;
 | |
| using StellaOps.Vexer.Attestation.Dsse;
 | |
| using StellaOps.Vexer.Attestation.Transparency;
 | |
| using StellaOps.Vexer.Core;
 | |
| 
 | |
| namespace StellaOps.Vexer.Attestation.Extensions;
 | |
| 
 | |
| public static class VexAttestationServiceCollectionExtensions
 | |
| {
 | |
|     public static IServiceCollection AddVexAttestation(this IServiceCollection services)
 | |
|     {
 | |
|         services.AddSingleton<VexDsseBuilder>();
 | |
|         services.AddSingleton<IVexAttestationClient, VexAttestationClient>();
 | |
|         return services;
 | |
|     }
 | |
| 
 | |
|     public static IServiceCollection AddVexRekorClient(this IServiceCollection services, Action<RekorHttpClientOptions> configure)
 | |
|     {
 | |
|         ArgumentNullException.ThrowIfNull(configure);
 | |
|         services.Configure(configure);
 | |
|         services.AddHttpClient<ITransparencyLogClient, RekorHttpClient>();
 | |
|         return services;
 | |
|     }
 | |
| }
 |