change copyright and rename azure identity provider
This commit is contained in:
		
							parent
							
								
									83fc1878c4
								
							
						
					
					
						commit
						f694b9a41a
					
				| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="ErrorDetailsDto.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="HttpErrorDto.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="HttpException.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="LogDetail.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="LogOperation.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="LogSeverity.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="LogTarget.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="ServiceSettings.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="Claims.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| namespace Core.Blueprint.Logging | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="DisplayNames.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="EnvironmentVariables.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="ErrorCodes.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="MimeTypes.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="Responses.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="HttpErrorMiddleware.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="HttpLogger.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -1,6 +1,6 @@ | ||||
| // *********************************************************************** | ||||
| // <copyright file="HttpLoggingMiddleware.cs"> | ||||
| //     Heath | ||||
| //     AgileWebs | ||||
| // </copyright> | ||||
| // *********************************************************************** | ||||
| 
 | ||||
|  | ||||
| @ -5,10 +5,10 @@ using MongoDB.Driver.Authentication.Oidc; | ||||
| namespace Core.Blueprint.Mongo.Configuration | ||||
| { | ||||
|     /// <summary> | ||||
|     /// The <see cref="HeathIdentityProvider"/> class is responsible for acquiring an OpenID Connect (OIDC)  | ||||
|     /// The <see cref="AzureIdentityProvider"/> class is responsible for acquiring an OpenID Connect (OIDC)  | ||||
|     /// access token for MongoDB authentication using Azure Identity and Managed Identity credentials. | ||||
|     /// </summary> | ||||
|     public class HeathIdentityProvider : IOidcCallback | ||||
|     public class AzureIdentityProvider : IOidcCallback | ||||
|     { | ||||
|         /// <summary> | ||||
|         /// The audience (resource identifier) for which the OIDC token is being requested. | ||||
| @ -21,10 +21,10 @@ namespace Core.Blueprint.Mongo.Configuration | ||||
|         private readonly string _environment; | ||||
| 
 | ||||
|         /// <summary> | ||||
|         /// Initializes a new instance of the <see cref="HeathIdentityProvider"/> class with the specified audience. | ||||
|         /// Initializes a new instance of the <see cref="AzureIdentityProvider"/> class with the specified audience. | ||||
|         /// </summary> | ||||
|         /// <param name="audience">The audience (resource identifier) for which the OIDC token is being requested.</param> | ||||
|         public HeathIdentityProvider(string audience) | ||||
|         public AzureIdentityProvider(string audience) | ||||
|         { | ||||
|             _audience = audience; | ||||
|             _environment = Environment.GetEnvironmentVariable("ASPNETCORE_ENVIRONMENT") ?? string.Empty; | ||||
| @ -46,7 +46,7 @@ namespace Core.Blueprint.DAL.Mongo.Configuration | ||||
|             { | ||||
|                 var settings = serviceProvider.GetRequiredService<IOptions<MongoDbSettings>>().Value; | ||||
|                 var mongoClientSettings = MongoClientSettings.FromConnectionString(settings.ConnectionString); | ||||
|                 mongoClientSettings.Credential = MongoCredential.CreateOidcCredential(new HeathIdentityProvider(settings.Audience)); | ||||
|                 mongoClientSettings.Credential = MongoCredential.CreateOidcCredential(new AzureIdentityProvider(settings.Audience)); | ||||
|                 return new MongoClient(mongoClientSettings); | ||||
|             }); | ||||
| 
 | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Sergio Matias Urquin
						Sergio Matias Urquin