1
0
mirror of https://github.com/bitwarden/browser synced 2026-02-06 19:53:59 +00:00

PM-20578 renamed ReportDecipherService to risk-insights-encryption.service

This commit is contained in:
voommen-livefront
2025-06-24 14:51:23 -05:00
parent 8960acbe0b
commit 9ef274a444
4 changed files with 14 additions and 13 deletions

View File

@@ -14,8 +14,8 @@ import {
DrawerType,
} from "../models/password-health";
import { ReportDecipherService } from "./report-decipher.service";
import { RiskInsightsApiService } from "./risk-insights-api.service";
import { RiskInsightsEncryptionService } from "./risk-insights-encryption.service";
import { RiskInsightsReportService } from "./risk-insights-report.service";
export class RiskInsightsDataService {
private applicationsSubject = new BehaviorSubject<ApplicationHealthReportDetail[] | null>(null);
@@ -52,7 +52,7 @@ export class RiskInsightsDataService {
private reportService: RiskInsightsReportService,
private riskInsightsApiService: RiskInsightsApiService,
private cipherService: CipherService,
private reportDecipherService: ReportDecipherService,
private riskInsightsEncryptionService: RiskInsightsEncryptionService,
) {}
/**
@@ -99,10 +99,11 @@ export class RiskInsightsDataService {
lastUpdated: new Date(),
};
} else {
const [report, summary] = await this.reportDecipherService.decryptRiskInsightsReport(
organizationId as OrganizationId,
reportFromArchive,
);
const [report, summary] =
await this.riskInsightsEncryptionService.decryptRiskInsightsReport(
organizationId as OrganizationId,
reportFromArchive,
);
return {
report,

View File

@@ -13,7 +13,7 @@ import {
GetRiskInsightsReportResponse,
} from "../models/password-health";
export class ReportDecipherService {
export class RiskInsightsEncryptionService {
constructor(
private keyService: KeyService,
private encryptService: EncryptService,

View File

@@ -9,7 +9,7 @@ import {
RiskInsightsDataService,
RiskInsightsReportService,
} from "@bitwarden/bit-common/dirt/reports/risk-insights/services";
import { ReportDecipherService } from "@bitwarden/bit-common/dirt/reports/risk-insights/services/report-decipher.service";
import { RiskInsightsEncryptionService } from "@bitwarden/bit-common/dirt/reports/risk-insights/services/risk-insights-encryption.service";
import { ApiService } from "@bitwarden/common/abstractions/api.service";
import { AuditService } from "@bitwarden/common/abstractions/audit.service";
import { EncryptService } from "@bitwarden/common/key-management/crypto/abstractions/encrypt.service";
@@ -43,7 +43,7 @@ import { RiskInsightsComponent } from "./risk-insights.component";
RiskInsightsReportService,
RiskInsightsApiService,
CipherService,
ReportDecipherService,
RiskInsightsEncryptionService,
],
},
safeProvider({
@@ -61,8 +61,8 @@ import { RiskInsightsComponent } from "./risk-insights.component";
deps: [ApiService],
}),
safeProvider({
provide: ReportDecipherService,
useClass: ReportDecipherService,
provide: RiskInsightsEncryptionService,
useClass: RiskInsightsEncryptionService,
deps: [KeyService, EncryptService, KeyGenerationService],
}),
],

View File

@@ -24,7 +24,7 @@ import {
ApplicationHealthReportDetailWithCriticalFlagAndCipher,
ApplicationHealthReportSummary,
} from "@bitwarden/bit-common/dirt/reports/risk-insights/models/password-health";
import { ReportDecipherService } from "@bitwarden/bit-common/dirt/reports/risk-insights/services/report-decipher.service";
import { RiskInsightsEncryptionService } from "@bitwarden/bit-common/dirt/reports/risk-insights/services/risk-insights-encryption.service";
import {
getOrganizationById,
OrganizationService,
@@ -222,7 +222,7 @@ export class AllApplicationsComponent implements OnInit {
private accountService: AccountService,
protected criticalAppsService: CriticalAppsService,
protected riskInsightsApiService: RiskInsightsApiService,
protected reportDecipherService: ReportDecipherService,
protected reportDecipherService: RiskInsightsEncryptionService,
) {
this.searchControl.valueChanges
.pipe(debounceTime(200), takeUntilDestroyed())