public TemporaryExposureKeyExportBatchService(
     IConfiguration config,
     ITemporaryExposureKeyRepository tek,
     ITemporaryExposureKeyExportRepository tekExport,
     ITemporaryExposureKeySignService signService,
     ITemporaryExposureKeySignatureInfoService signatureService,
     ITemporaryExposureKeyBlobService blobService,
     ILogger <TemporaryExposureKeyExportBatchService> logger)
 {
     TekRepository       = tek;
     TekExportRepository = tekExport;
     SignService         = signService;
     SignatureService    = signatureService;
     BlobService         = blobService;
     Logger = logger;
 }
 public TemporaryExposureKeyService(IConfiguration config,
                                    ITemporaryExposureKeyRepository tek,
                                    ITemporaryExposureKeyExportRepository tekExport,
                                    ITemporaryExposureKeySignService signService,
                                    ITemporaryExposureKeySignatureInfoService signatureService,
                                    ILogger <TemporaryExposureKeyService> logger)
 {
     TekExportBlobStorageConnectionString = config["TekExportBlobStorage"];
     TekExportBlobStorageContainerPrefix  = config["TekExportBlobStorageContainerPrefix"];
     TekRepository       = tek;
     TekExportRepository = tekExport;
     SignService         = signService;
     SignatureService    = signatureService;
     Logger         = logger;
     StorageAccount = CloudStorageAccount.Parse(TekExportBlobStorageConnectionString);
     BlobClient     = StorageAccount.CreateCloudBlobClient();
 }
Пример #3
0
 public TemporaryExposureKeyExportBatchService(
     IConfiguration config,
     ITemporaryExposureKeyRepository tek,
     ITemporaryExposureKeyExportRepository tekExport,
     ITemporaryExposureKeySignService signService,
     ITemporaryExposureKeySignatureInfoService signatureService,
     ITemporaryExposureKeyBlobService blobService,
     ILogger <TemporaryExposureKeyExportBatchService> logger)
 {
     Logger = logger;
     Logger.LogInformation($"{nameof(TemporaryExposureKeyExportBatchService)} constructor");
     TekRepository       = tek;
     TekExportRepository = tekExport;
     SignService         = signService;
     SignatureService    = signatureService;
     BlobService         = blobService;
     Regions             = config.SupportRegions();
 }
Пример #4
0
        public static async Task <X509Certificate2> GetX509PublicKeyAsync(this ITemporaryExposureKeySignService service)
        {
            var p = await service.GetPublicKeyAsync();

            return(new X509Certificate2(p));
        }