@cclabsnz/sf-audit 1.6.1 → 1.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +258 -5
- package/lib/apps/analyzeApps.d.ts +1 -1
- package/lib/apps/appResolver.d.ts +1 -1
- package/lib/apps/grantedAccess.d.ts +1 -1
- package/lib/chains/AttackChain.d.ts +1 -1
- package/lib/chains/namedChains.d.ts +1 -1
- package/lib/checks/CheckEngine.d.ts +1 -1
- package/lib/checks/SecurityCheck.d.ts +3 -3
- package/lib/checks/impl/AgentActionSurfaceCheck.d.ts +1 -1
- package/lib/checks/impl/AgentActionSurfaceCheck.js +1 -1
- package/lib/checks/impl/AgentChannelExposureCheck.d.ts +1 -1
- package/lib/checks/impl/AgentInventoryCheck.d.ts +1 -1
- package/lib/checks/impl/AgentInventoryCheck.js +1 -1
- package/lib/checks/impl/AgentMonitoringCoverageCheck.d.ts +1 -1
- package/lib/checks/impl/AgentUserPrivilegeCheck.d.ts +1 -1
- package/lib/checks/impl/AnonymousApexAuditCheck.d.ts +1 -1
- package/lib/checks/impl/ApexCrudFLSCheck.d.ts +1 -1
- package/lib/checks/impl/ApexLoggingCheck.d.ts +1 -1
- package/lib/checks/impl/ApexRestEndpointCheck.d.ts +1 -1
- package/lib/checks/impl/ApexSharingCheck.d.ts +1 -1
- package/lib/checks/impl/ApexSharingCheck.js +3 -2
- package/lib/checks/impl/ApiClientPermissionCheck.d.ts +1 -1
- package/lib/checks/impl/ApiLimitsCheck.d.ts +1 -1
- package/lib/checks/impl/AuditTrailCheck.d.ts +1 -1
- package/lib/checks/impl/AuthProvidersCheck.d.ts +1 -1
- package/lib/checks/impl/CertificateExpiryCheck.d.ts +1 -1
- package/lib/checks/impl/ClassicSitesCheck.d.ts +1 -1
- package/lib/checks/impl/CodeSecurityCheck.d.ts +1 -1
- package/lib/checks/impl/CodeSecurityCheck.js +5 -5
- package/lib/checks/impl/ConnectedAppInactivityCheck.d.ts +1 -1
- package/lib/checks/impl/ConnectedAppScopeCheck.d.ts +1 -1
- package/lib/checks/impl/ConnectedAppsCheck.d.ts +1 -1
- package/lib/checks/impl/ContentLinksCheck.d.ts +1 -1
- package/lib/checks/impl/CorsAllowlistCheck.d.ts +1 -1
- package/lib/checks/impl/CspTrustedSitesCheck.d.ts +1 -1
- package/lib/checks/impl/CustomLabelsCredentialCheck.d.ts +1 -1
- package/lib/checks/impl/CustomSettingsCheck.d.ts +1 -1
- package/lib/checks/impl/DataClassificationCheck.d.ts +1 -1
- package/lib/checks/impl/DataExportAccessCheck.d.ts +1 -1
- package/lib/checks/impl/DebugLogAccessCheck.d.ts +1 -1
- package/lib/checks/impl/DeploymentIdentityCheck.d.ts +1 -1
- package/lib/checks/impl/EmailSecurityCheck.d.ts +1 -1
- package/lib/checks/impl/EncryptionCoverageCheck.d.ts +1 -1
- package/lib/checks/impl/EnhancedDomainsCheck.d.ts +1 -1
- package/lib/checks/impl/EnhancedDomainsCheck.js +2 -2
- package/lib/checks/impl/EscalationPermsCheck.d.ts +1 -1
- package/lib/checks/impl/EventMonitoringCheck.d.ts +1 -1
- package/lib/checks/impl/EventMonitoringCheck.js +1 -1
- package/lib/checks/impl/ExperienceCloudSiteCheck.d.ts +1 -1
- package/lib/checks/impl/ExperienceCspCheck.d.ts +1 -1
- package/lib/checks/impl/ExternalCredentialsCheck.d.ts +1 -1
- package/lib/checks/impl/FailedLoginCheck.d.ts +1 -1
- package/lib/checks/impl/FieldHistoryTrackingCheck.d.ts +1 -1
- package/lib/checks/impl/FieldLevelSecurityCheck.d.ts +1 -1
- package/lib/checks/impl/FlowsWithoutSharingCheck.d.ts +1 -1
- package/lib/checks/impl/FlowsWithoutSharingCheck.js +10 -9
- package/lib/checks/impl/GuestApiAccessCheck.d.ts +1 -1
- package/lib/checks/impl/GuestExecutableApexCheck.d.ts +1 -1
- package/lib/checks/impl/GuestExecutableApexCheck.js +4 -3
- package/lib/checks/impl/GuestObjectExposureCheck.d.ts +1 -1
- package/lib/checks/impl/GuestRecordAccessPolicyCheck.d.ts +1 -1
- package/lib/checks/impl/GuestSiteOptionsCheck.d.ts +1 -1
- package/lib/checks/impl/GuestTrafficAnomalyCheck.d.ts +1 -1
- package/lib/checks/impl/GuestTrafficAnomalyCheck.js +1 -1
- package/lib/checks/impl/GuestUserAccessCheck.d.ts +1 -1
- package/lib/checks/impl/HardcodedCredentialsCheck.d.ts +1 -1
- package/lib/checks/impl/HardcodedCredentialsCheck.js +8 -1
- package/lib/checks/impl/HealthCheckCheck.d.ts +1 -1
- package/lib/checks/impl/HighAssuranceSessionCheck.d.ts +1 -1
- package/lib/checks/impl/InactiveUsersCheck.d.ts +1 -1
- package/lib/checks/impl/InstalledPackagesCheck.d.ts +1 -1
- package/lib/checks/impl/IntegrationUsersCheck.d.ts +1 -1
- package/lib/checks/impl/InternalUserMfaCheck.d.ts +1 -1
- package/lib/checks/impl/IpRestrictionsCheck.d.ts +1 -1
- package/lib/checks/impl/LegacyApiVersionCheck.d.ts +1 -1
- package/lib/checks/impl/LoginAccessPolicyCheck.d.ts +1 -1
- package/lib/checks/impl/LoginAnomalyCheck.d.ts +1 -1
- package/lib/checks/impl/LoginSessionCheck.d.ts +1 -1
- package/lib/checks/impl/MfaEnforcementCheck.d.ts +1 -1
- package/lib/checks/impl/MfaMethodStrengthCheck.d.ts +1 -1
- package/lib/checks/impl/MfaRegistrationCheck.d.ts +1 -1
- package/lib/checks/impl/MyDomainLoginPolicyCheck.d.ts +1 -1
- package/lib/checks/impl/NamedCredentialsCheck.d.ts +1 -1
- package/lib/checks/impl/NamedCredentialsCheck.js +13 -9
- package/lib/checks/impl/OutboundMessagesCheck.d.ts +1 -1
- package/lib/checks/impl/PasswordSessionPolicyCheck.d.ts +2 -2
- package/lib/checks/impl/PermissionsCheck.d.ts +1 -1
- package/lib/checks/impl/PrivilegedAccessCheck.d.ts +1 -1
- package/lib/checks/impl/PublicContentExposureCheck.d.ts +1 -1
- package/lib/checks/impl/PublicGroupSharingCheck.d.ts +1 -1
- package/lib/checks/impl/ReleaseUpdatesCheck.d.ts +1 -1
- package/lib/checks/impl/RemoteSitesCheck.d.ts +1 -1
- package/lib/checks/impl/ReportFolderAccessCheck.d.ts +1 -1
- package/lib/checks/impl/SandboxDataMaskingCheck.d.ts +1 -1
- package/lib/checks/impl/ScheduledApexCheck.d.ts +1 -1
- package/lib/checks/impl/SeparationOfDutiesCheck.d.ts +1 -1
- package/lib/checks/impl/SessionHardeningCheck.d.ts +1 -1
- package/lib/checks/impl/SharingModelCheck.d.ts +1 -1
- package/lib/checks/impl/SiemIntegrationCheck.d.ts +1 -1
- package/lib/checks/impl/SsoEnforcementCheck.d.ts +1 -1
- package/lib/checks/impl/StandardProfilesCheck.d.ts +1 -1
- package/lib/checks/impl/ThreatDetectionCheck.d.ts +1 -1
- package/lib/checks/impl/TransactionSecurityPolicyCheck.d.ts +1 -1
- package/lib/checks/impl/TrustedIPRangesCheck.d.ts +1 -1
- package/lib/checks/impl/TrustedUrlHygieneCheck.d.ts +1 -1
- package/lib/checks/impl/UsersAndAdminsCheck.d.ts +1 -1
- package/lib/checks/impl/VisualforceXssCheck.d.ts +1 -1
- package/lib/commands/audit/events/pull.d.ts +1 -1
- package/lib/commands/audit/events/pull.js +3 -3
- package/lib/commands/audit/security.js +3 -1
- package/lib/commands/audit/timeline.d.ts +26 -0
- package/lib/commands/audit/timeline.js +189 -0
- package/lib/findings/AuditResult.d.ts +1 -1
- package/lib/findings/Finding.d.ts +1 -1
- package/lib/findings/ScoringConfig.d.ts +9 -217
- package/lib/findings/scoring.d.ts +2 -2
- package/lib/findings/scoring.js +1 -1
- package/lib/history/AuditDiff.d.ts +1 -1
- package/lib/history/metricMeta.d.ts +1 -1
- package/lib/index.d.ts +2 -2
- package/lib/lib/apexRefs.d.ts +2 -0
- package/lib/lib/apexRefs.js +30 -0
- package/lib/lib/wire.d.ts +6 -6
- package/lib/lib/wire.js +4 -4
- package/lib/renderers/ClientReportRenderer.d.ts +1 -1
- package/lib/renderers/ClientReportRenderer.js +6 -3
- package/lib/renderers/HistoryRenderer.js +2 -1
- package/lib/renderers/HtmlRenderer.js +3 -4
- package/lib/renderers/MarkdownRenderer.js +1 -1
- package/lib/renderers/chartAsset.d.ts +12 -0
- package/lib/renderers/chartAsset.js +25 -0
- package/lib/timeline/CaptureIndex.d.ts +34 -0
- package/lib/timeline/CaptureIndex.js +82 -0
- package/lib/timeline/CardinalityIndex.d.ts +28 -0
- package/lib/timeline/CardinalityIndex.js +47 -0
- package/lib/timeline/CorrelationEngine.d.ts +65 -0
- package/lib/timeline/CorrelationEngine.js +0 -0
- package/lib/timeline/EventRow.d.ts +69 -0
- package/lib/timeline/EventRow.js +14 -0
- package/lib/timeline/JoinKeys.d.ts +50 -0
- package/lib/timeline/JoinKeys.js +63 -0
- package/lib/timeline/loadCaptures.d.ts +87 -0
- package/lib/timeline/loadCaptures.js +424 -0
- package/lib/timeline/normalise.d.ts +26 -0
- package/lib/timeline/normalise.js +161 -0
- package/lib/timeline/parseWindow.d.ts +29 -0
- package/lib/timeline/parseWindow.js +133 -0
- package/lib/timeline/render.d.ts +33 -0
- package/lib/timeline/render.js +120 -0
- package/package.json +22 -20
- package/lib/api/ApiError.d.ts +0 -6
- package/lib/api/ApiError.js +0 -6
- package/lib/api/MetadataClient.d.ts +0 -4
- package/lib/api/MetadataClient.js +0 -2
- package/lib/api/MetadataClientImpl.d.ts +0 -8
- package/lib/api/MetadataClientImpl.js +0 -22
- package/lib/api/RestClient.d.ts +0 -6
- package/lib/api/RestClient.js +0 -2
- package/lib/api/RestClientImpl.d.ts +0 -10
- package/lib/api/RestClientImpl.js +0 -45
- package/lib/api/SoqlClient.d.ts +0 -10
- package/lib/api/SoqlClient.js +0 -2
- package/lib/api/SoqlClientImpl.d.ts +0 -9
- package/lib/api/SoqlClientImpl.js +0 -19
- package/lib/api/ToolingClient.d.ts +0 -5
- package/lib/api/ToolingClient.js +0 -2
- package/lib/api/ToolingClientImpl.d.ts +0 -10
- package/lib/api/ToolingClientImpl.js +0 -29
- package/lib/api/index.d.ts +0 -9
- package/lib/api/index.js +0 -5
- package/lib/checks/eventLogAccess.d.ts +0 -14
- package/lib/checks/eventLogAccess.js +0 -33
- package/lib/context/AuditCache.d.ts +0 -78
- package/lib/context/AuditCache.js +0 -2
- package/lib/context/AuditContext.d.ts +0 -19
- package/lib/context/AuditContext.js +0 -2
- package/lib/context/OrgInfo.d.ts +0 -9
- package/lib/context/OrgInfo.js +0 -2
- package/lib/context/OrgMetrics.d.ts +0 -20
- package/lib/context/OrgMetrics.js +0 -20
- package/lib/events/EventBaselineStore.d.ts +0 -16
- package/lib/events/EventBaselineStore.js +0 -55
- package/lib/events/eventLogQuery.d.ts +0 -21
- package/lib/events/eventLogQuery.js +0 -34
- package/lib/events/pullEventLogs.d.ts +0 -51
- package/lib/events/pullEventLogs.js +0 -79
- package/lib/findings/RiskLevel.d.ts +0 -3
- package/lib/findings/RiskLevel.js +0 -2
- package/lib/renderers/html-utils.d.ts +0 -2
- package/lib/renderers/html-utils.js +0 -8
- package/lib/report/branding.d.ts +0 -18
- package/lib/report/branding.js +0 -19
- package/lib/report/fonts.d.ts +0 -2
- package/lib/report/fonts.js +0 -22
- package/src/assets/fonts/dm-sans-italic-latin.woff2 +0 -0
- package/src/assets/fonts/dm-sans-normal-latin.woff2 +0 -0
- package/src/assets/fonts/dm-serif-display-italic-latin.woff2 +0 -0
- package/src/assets/fonts/dm-serif-display-normal-latin.woff2 +0 -0
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { createWriteStream } from 'node:fs';
|
|
2
|
-
import { mkdir, rm, stat } from 'node:fs/promises';
|
|
3
|
-
import { dirname } from 'node:path';
|
|
4
|
-
import { Readable } from 'node:stream';
|
|
5
|
-
import { pipeline } from 'node:stream/promises';
|
|
6
|
-
export class RestClientImpl {
|
|
7
|
-
conn;
|
|
8
|
-
constructor(conn) {
|
|
9
|
-
this.conn = conn;
|
|
10
|
-
}
|
|
11
|
-
async get(path) {
|
|
12
|
-
const version = this.conn.getApiVersion();
|
|
13
|
-
const normalised = path.startsWith('/') ? path : `/${path}`;
|
|
14
|
-
return this.conn.request(`/services/data/v${version}${normalised}`);
|
|
15
|
-
}
|
|
16
|
-
async getRaw(path) {
|
|
17
|
-
const version = this.conn.getApiVersion();
|
|
18
|
-
const normalised = path.startsWith('/') ? path : `/${path}`;
|
|
19
|
-
// jsforce returns the raw body string for non-JSON content types (text/csv here).
|
|
20
|
-
return this.conn.request(`/services/data/v${version}${normalised}`);
|
|
21
|
-
}
|
|
22
|
-
async getRawToFile(path, destPath) {
|
|
23
|
-
const version = this.conn.getApiVersion();
|
|
24
|
-
const normalised = path.startsWith('/') ? path : `/${path}`;
|
|
25
|
-
// Stream directly from the org to disk with the session bearer token, so the body is never
|
|
26
|
-
// materialised as a JS string (which would fail on logs larger than ~512 MB).
|
|
27
|
-
const url = `${this.conn.instanceUrl}/services/data/v${version}${normalised}`;
|
|
28
|
-
const res = await fetch(url, {
|
|
29
|
-
headers: { Authorization: `Bearer ${this.conn.accessToken ?? ''}` },
|
|
30
|
-
});
|
|
31
|
-
if (!res.ok || !res.body) {
|
|
32
|
-
throw new Error(`Download failed for ${normalised} (HTTP ${res.status})`);
|
|
33
|
-
}
|
|
34
|
-
await mkdir(dirname(destPath), { recursive: true });
|
|
35
|
-
try {
|
|
36
|
-
await pipeline(Readable.fromWeb(res.body), createWriteStream(destPath));
|
|
37
|
-
}
|
|
38
|
-
catch (err) {
|
|
39
|
-
await rm(destPath, { force: true }); // never leave a partial file behind
|
|
40
|
-
throw err;
|
|
41
|
-
}
|
|
42
|
-
return (await stat(destPath)).size;
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
//# sourceMappingURL=RestClientImpl.js.map
|
package/lib/api/SoqlClient.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export interface QueryResult<T> {
|
|
2
|
-
totalSize: number;
|
|
3
|
-
done: boolean;
|
|
4
|
-
records: T[];
|
|
5
|
-
}
|
|
6
|
-
export interface SoqlClient {
|
|
7
|
-
query<T>(soql: string): Promise<QueryResult<T>>;
|
|
8
|
-
queryAll<T>(soql: string): Promise<T[]>;
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=SoqlClient.d.ts.map
|
package/lib/api/SoqlClient.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { Connection } from '@salesforce/core';
|
|
2
|
-
import type { QueryResult, SoqlClient } from './SoqlClient.js';
|
|
3
|
-
export declare class SoqlClientImpl implements SoqlClient {
|
|
4
|
-
private readonly anyConn;
|
|
5
|
-
constructor(conn: Connection);
|
|
6
|
-
query<T>(soql: string): Promise<QueryResult<T>>;
|
|
7
|
-
queryAll<T>(soql: string): Promise<T[]>;
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=SoqlClientImpl.d.ts.map
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
export class SoqlClientImpl {
|
|
2
|
-
anyConn;
|
|
3
|
-
constructor(conn) {
|
|
4
|
-
this.anyConn = conn;
|
|
5
|
-
}
|
|
6
|
-
async query(soql) {
|
|
7
|
-
const result = await this.anyConn.query(soql);
|
|
8
|
-
return {
|
|
9
|
-
totalSize: result.totalSize,
|
|
10
|
-
done: result.done,
|
|
11
|
-
records: (result.records ?? []),
|
|
12
|
-
};
|
|
13
|
-
}
|
|
14
|
-
async queryAll(soql) {
|
|
15
|
-
const result = await this.anyConn.autoFetchQuery(soql);
|
|
16
|
-
return (result.records ?? []);
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
//# sourceMappingURL=SoqlClientImpl.js.map
|
package/lib/api/ToolingClient.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { Connection } from '@salesforce/core';
|
|
2
|
-
import type { ToolingClient } from './ToolingClient.js';
|
|
3
|
-
export declare class ToolingClientImpl implements ToolingClient {
|
|
4
|
-
private readonly conn;
|
|
5
|
-
private readonly tooling;
|
|
6
|
-
constructor(conn: Connection);
|
|
7
|
-
query<T>(soql: string): Promise<T[]>;
|
|
8
|
-
getRecord<T>(type: string, id: string): Promise<T>;
|
|
9
|
-
}
|
|
10
|
-
//# sourceMappingURL=ToolingClientImpl.d.ts.map
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
export class ToolingClientImpl {
|
|
2
|
-
conn;
|
|
3
|
-
tooling;
|
|
4
|
-
constructor(conn) {
|
|
5
|
-
this.conn = conn;
|
|
6
|
-
this.tooling = conn.tooling;
|
|
7
|
-
}
|
|
8
|
-
async query(soql) {
|
|
9
|
-
const result = await this.tooling.query(soql);
|
|
10
|
-
let records = (result.records ?? []);
|
|
11
|
-
let nextUrl = result.nextRecordsUrl;
|
|
12
|
-
// Using conn.request() directly avoids the complex Query<> overload typings
|
|
13
|
-
// on tooling.queryMore — the nextRecordsUrl is a plain string handled cleanly here.
|
|
14
|
-
// Circuit breaker: 200 pages × 2000 rows = 400 000 records max before we abort.
|
|
15
|
-
let page = 0;
|
|
16
|
-
while (nextUrl && page < 200) {
|
|
17
|
-
page++;
|
|
18
|
-
const next = await this.conn.request(nextUrl);
|
|
19
|
-
records = records.concat(next.records ?? []);
|
|
20
|
-
nextUrl = next.nextRecordsUrl;
|
|
21
|
-
}
|
|
22
|
-
return records;
|
|
23
|
-
}
|
|
24
|
-
async getRecord(type, id) {
|
|
25
|
-
const version = this.conn.getApiVersion();
|
|
26
|
-
return this.conn.request(`/services/data/v${version}/tooling/sobjects/${type}/${id}/`);
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
//# sourceMappingURL=ToolingClientImpl.js.map
|
package/lib/api/index.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export type { QueryResult, SoqlClient } from './SoqlClient.js';
|
|
2
|
-
export type { ToolingClient } from './ToolingClient.js';
|
|
3
|
-
export type { RestClient } from './RestClient.js';
|
|
4
|
-
export type { ApiError } from './ApiError.js';
|
|
5
|
-
export { isApiError } from './ApiError.js';
|
|
6
|
-
export { SoqlClientImpl } from './SoqlClientImpl.js';
|
|
7
|
-
export { ToolingClientImpl } from './ToolingClientImpl.js';
|
|
8
|
-
export { RestClientImpl } from './RestClientImpl.js';
|
|
9
|
-
//# sourceMappingURL=index.d.ts.map
|
package/lib/api/index.js
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { EventLogAccess } from '../context/AuditCache.js';
|
|
2
|
-
/**
|
|
3
|
-
* Classifies why an `EventLogFile` query failed so callers can tell the two very
|
|
4
|
-
* different "no data" causes apart:
|
|
5
|
-
* - 'not-enabled' : Event Monitoring is not licensed/enabled (EventLogFile is
|
|
6
|
-
* an unknown/blocked sObject) — the org captures nothing.
|
|
7
|
-
* - 'no-permission' : the feature is on, but the running audit user lacks the
|
|
8
|
-
* "View Event Log Files" permission — logs exist, we can't read them.
|
|
9
|
-
* - 'unknown' : could not be attributed to either.
|
|
10
|
-
* Both are BLIND for guest-traffic analysis, but the remediation differs (license
|
|
11
|
-
* vs. grant a permission), so the distinction is worth surfacing.
|
|
12
|
-
*/
|
|
13
|
-
export declare function classifyEventLogAccessError(err: unknown): EventLogAccess;
|
|
14
|
-
//# sourceMappingURL=eventLogAccess.d.ts.map
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import { isApiError } from '../api/ApiError.js';
|
|
2
|
-
/**
|
|
3
|
-
* Classifies why an `EventLogFile` query failed so callers can tell the two very
|
|
4
|
-
* different "no data" causes apart:
|
|
5
|
-
* - 'not-enabled' : Event Monitoring is not licensed/enabled (EventLogFile is
|
|
6
|
-
* an unknown/blocked sObject) — the org captures nothing.
|
|
7
|
-
* - 'no-permission' : the feature is on, but the running audit user lacks the
|
|
8
|
-
* "View Event Log Files" permission — logs exist, we can't read them.
|
|
9
|
-
* - 'unknown' : could not be attributed to either.
|
|
10
|
-
* Both are BLIND for guest-traffic analysis, but the remediation differs (license
|
|
11
|
-
* vs. grant a permission), so the distinction is worth surfacing.
|
|
12
|
-
*/
|
|
13
|
-
export function classifyEventLogAccessError(err) {
|
|
14
|
-
if (isApiError(err)) {
|
|
15
|
-
if (err.statusCode === 403 || /ACCESS|INSUFFICIENT/i.test(err.errorCode))
|
|
16
|
-
return 'no-permission';
|
|
17
|
-
if (/INVALID_TYPE|NOT_FOUND|MALFORMED_QUERY/i.test(err.errorCode) || err.statusCode === 404 || err.statusCode === 400) {
|
|
18
|
-
return 'not-enabled';
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
const msg = (err instanceof Error ? err.message : String(err)).toLowerCase();
|
|
22
|
-
if (msg.includes('insufficient') || msg.includes('permission') || msg.includes('view event log'))
|
|
23
|
-
return 'no-permission';
|
|
24
|
-
if (msg.includes('not supported') ||
|
|
25
|
-
msg.includes('invalid type') ||
|
|
26
|
-
msg.includes("sobject type 'eventlogfile'") ||
|
|
27
|
-
msg.includes('not enabled') ||
|
|
28
|
-
msg.includes('licens')) {
|
|
29
|
-
return 'not-enabled';
|
|
30
|
-
}
|
|
31
|
-
return 'unknown';
|
|
32
|
-
}
|
|
33
|
-
//# sourceMappingURL=eventLogAccess.js.map
|
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
export interface HealthCheckRisk {
|
|
2
|
-
setting: string;
|
|
3
|
-
riskType: string;
|
|
4
|
-
value: string;
|
|
5
|
-
score: number;
|
|
6
|
-
}
|
|
7
|
-
export interface ApexClassBody {
|
|
8
|
-
name: string;
|
|
9
|
-
body: string;
|
|
10
|
-
}
|
|
11
|
-
export interface VfPageBody {
|
|
12
|
-
name: string;
|
|
13
|
-
markup: string;
|
|
14
|
-
}
|
|
15
|
-
export type EventLogAccess = 'no-permission' | 'not-enabled' | 'unknown';
|
|
16
|
-
export interface EventLogSummary {
|
|
17
|
-
earliestDate: string | null;
|
|
18
|
-
totalFiles: number;
|
|
19
|
-
eventTypes: string[];
|
|
20
|
-
accessible?: boolean;
|
|
21
|
-
accessError?: EventLogAccess;
|
|
22
|
-
}
|
|
23
|
-
export type AgentAccess = 'ok' | 'not-enabled' | 'unknown';
|
|
24
|
-
export interface AgentDefinition {
|
|
25
|
-
developerName: string;
|
|
26
|
-
label: string;
|
|
27
|
-
type: 'agent' | 'classic-bot';
|
|
28
|
-
isActive: boolean;
|
|
29
|
-
activeVersion?: number;
|
|
30
|
-
runAsUserId?: string;
|
|
31
|
-
runAsUserActive?: boolean;
|
|
32
|
-
}
|
|
33
|
-
export interface AgentUser {
|
|
34
|
-
userId: string;
|
|
35
|
-
username: string;
|
|
36
|
-
profileName: string;
|
|
37
|
-
isActive: boolean;
|
|
38
|
-
permissionSetIds: string[];
|
|
39
|
-
permissionSetLicenseNames: string[];
|
|
40
|
-
}
|
|
41
|
-
export interface CspTrustedSite {
|
|
42
|
-
developerName: string;
|
|
43
|
-
endpointUrl: string;
|
|
44
|
-
isActive: boolean;
|
|
45
|
-
context?: string;
|
|
46
|
-
}
|
|
47
|
-
export interface MfaRegistration {
|
|
48
|
-
userId: string;
|
|
49
|
-
username: string;
|
|
50
|
-
profileName: string;
|
|
51
|
-
methods: string[];
|
|
52
|
-
}
|
|
53
|
-
export interface EffectivePermissionGrant {
|
|
54
|
-
userId: string;
|
|
55
|
-
username: string;
|
|
56
|
-
name: string;
|
|
57
|
-
profileName: string;
|
|
58
|
-
/** Stable permission keys from DANGEROUS_PERMS held by this user. */
|
|
59
|
-
perms: string[];
|
|
60
|
-
}
|
|
61
|
-
export interface AuditCache {
|
|
62
|
-
healthCheckRisks?: HealthCheckRisk[];
|
|
63
|
-
apexBodies?: ApexClassBody[];
|
|
64
|
-
namedCredentialEndpoints?: string[];
|
|
65
|
-
remoteSiteUrls?: string[];
|
|
66
|
-
healthCloudInstalled?: boolean;
|
|
67
|
-
connectedAppNames?: string[];
|
|
68
|
-
scheduledApexClassNames?: string[];
|
|
69
|
-
eventLogSummary?: EventLogSummary;
|
|
70
|
-
mfaRegistrations?: MfaRegistration[];
|
|
71
|
-
vfPageBodies?: VfPageBody[];
|
|
72
|
-
cspTrustedSites?: CspTrustedSite[];
|
|
73
|
-
effectivePermissions?: EffectivePermissionGrant[];
|
|
74
|
-
agentInventory?: AgentDefinition[];
|
|
75
|
-
agentUsers?: AgentUser[];
|
|
76
|
-
agentAccess?: AgentAccess;
|
|
77
|
-
}
|
|
78
|
-
//# sourceMappingURL=AuditCache.d.ts.map
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import type { SoqlClient } from '../api/SoqlClient.js';
|
|
2
|
-
import type { ToolingClient } from '../api/ToolingClient.js';
|
|
3
|
-
import type { RestClient } from '../api/RestClient.js';
|
|
4
|
-
import type { MetadataClient } from '../api/MetadataClient.js';
|
|
5
|
-
import type { OrgInfo } from './OrgInfo.js';
|
|
6
|
-
import type { AuditCache } from './AuditCache.js';
|
|
7
|
-
export interface AuditOptions {
|
|
8
|
-
resolveDomains?: boolean;
|
|
9
|
-
}
|
|
10
|
-
export interface AuditContext {
|
|
11
|
-
readonly soql: SoqlClient;
|
|
12
|
-
readonly tooling: ToolingClient;
|
|
13
|
-
readonly rest: RestClient;
|
|
14
|
-
readonly metadata?: MetadataClient;
|
|
15
|
-
readonly orgInfo: OrgInfo;
|
|
16
|
-
readonly options?: AuditOptions;
|
|
17
|
-
cache: AuditCache;
|
|
18
|
-
}
|
|
19
|
-
//# sourceMappingURL=AuditContext.d.ts.map
|
package/lib/context/OrgInfo.d.ts
DELETED
package/lib/context/OrgInfo.js
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
export interface OrgMetrics {
|
|
2
|
-
totalActiveUsers: number;
|
|
3
|
-
modifyAllDataUsersCount: number;
|
|
4
|
-
viewAllDataUsersCount: number;
|
|
5
|
-
permissionSetCount: number;
|
|
6
|
-
profileCount: number;
|
|
7
|
-
apexClassCount: number;
|
|
8
|
-
apexTriggerCount: number;
|
|
9
|
-
codeCoveragePercent: number;
|
|
10
|
-
failedLogins30d: number;
|
|
11
|
-
inactiveUsers90d: number;
|
|
12
|
-
connectedAppsCount: number;
|
|
13
|
-
remoteSitesCount: number;
|
|
14
|
-
insecureRemoteSitesCount: number;
|
|
15
|
-
namedCredentialsCount: number;
|
|
16
|
-
unusedNamedCredentialsCount: number;
|
|
17
|
-
healthCheckScore: number;
|
|
18
|
-
}
|
|
19
|
-
export declare const EMPTY_METRICS: OrgMetrics;
|
|
20
|
-
//# sourceMappingURL=OrgMetrics.d.ts.map
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
// Used by scoring.ts to fill any metrics not populated by checks
|
|
2
|
-
export const EMPTY_METRICS = {
|
|
3
|
-
totalActiveUsers: 0,
|
|
4
|
-
modifyAllDataUsersCount: 0,
|
|
5
|
-
viewAllDataUsersCount: 0,
|
|
6
|
-
permissionSetCount: 0,
|
|
7
|
-
profileCount: 0,
|
|
8
|
-
apexClassCount: 0,
|
|
9
|
-
apexTriggerCount: 0,
|
|
10
|
-
codeCoveragePercent: 0,
|
|
11
|
-
failedLogins30d: 0,
|
|
12
|
-
inactiveUsers90d: 0,
|
|
13
|
-
connectedAppsCount: 0,
|
|
14
|
-
remoteSitesCount: 0,
|
|
15
|
-
insecureRemoteSitesCount: 0,
|
|
16
|
-
namedCredentialsCount: 0,
|
|
17
|
-
unusedNamedCredentialsCount: 0,
|
|
18
|
-
healthCheckScore: 0,
|
|
19
|
-
};
|
|
20
|
-
//# sourceMappingURL=OrgMetrics.js.map
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export declare class EventBaselineStore {
|
|
2
|
-
private readonly root;
|
|
3
|
-
constructor(root?: string);
|
|
4
|
-
static defaultRoot(): string;
|
|
5
|
-
/** The per-org base directory logs for this org are stored under. */
|
|
6
|
-
orgDir(orgId: string): string;
|
|
7
|
-
/** Absolute path a given log file is (or would be) stored at. */
|
|
8
|
-
pathFor(orgId: string, eventType: string, logDate: string, id: string): string;
|
|
9
|
-
/** True when this EventLogFile is already on disk — the dedup / idempotency check. */
|
|
10
|
-
has(orgId: string, eventType: string, logDate: string, id: string): boolean;
|
|
11
|
-
/** Write a CSV body verbatim; returns the saved path. Best-effort. */
|
|
12
|
-
save(orgId: string, eventType: string, logDate: string, id: string, body: string): string;
|
|
13
|
-
/** Write a per-run manifest JSON under {root}/{orgId}/_manifests/; returns its path. */
|
|
14
|
-
writeManifest(orgId: string, manifest: unknown): string;
|
|
15
|
-
}
|
|
16
|
-
//# sourceMappingURL=EventBaselineStore.d.ts.map
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
// src/events/EventBaselineStore.ts
|
|
2
|
-
// Local, on-disk archive of free EventLogFile CSVs. Mirrors HistoryStore: writes under
|
|
3
|
-
// ~/.sf/event-baseline/{orgId}/, takes an optional root for testability, and is best-effort
|
|
4
|
-
// (warns rather than throws) so a daily cron run never dies on a filesystem hiccup.
|
|
5
|
-
import * as fs from 'node:fs';
|
|
6
|
-
import * as os from 'node:os';
|
|
7
|
-
import * as path from 'node:path';
|
|
8
|
-
export class EventBaselineStore {
|
|
9
|
-
root;
|
|
10
|
-
constructor(root) {
|
|
11
|
-
this.root = root ?? EventBaselineStore.defaultRoot();
|
|
12
|
-
}
|
|
13
|
-
static defaultRoot() {
|
|
14
|
-
return path.join(os.homedir(), '.sf', 'event-baseline');
|
|
15
|
-
}
|
|
16
|
-
/** The per-org base directory logs for this org are stored under. */
|
|
17
|
-
orgDir(orgId) {
|
|
18
|
-
return path.join(this.root, orgId);
|
|
19
|
-
}
|
|
20
|
-
/** Absolute path a given log file is (or would be) stored at. */
|
|
21
|
-
pathFor(orgId, eventType, logDate, id) {
|
|
22
|
-
return path.join(this.root, orgId, eventType, `${logDate}-${id}.csv`);
|
|
23
|
-
}
|
|
24
|
-
/** True when this EventLogFile is already on disk — the dedup / idempotency check. */
|
|
25
|
-
has(orgId, eventType, logDate, id) {
|
|
26
|
-
return fs.existsSync(this.pathFor(orgId, eventType, logDate, id));
|
|
27
|
-
}
|
|
28
|
-
/** Write a CSV body verbatim; returns the saved path. Best-effort. */
|
|
29
|
-
save(orgId, eventType, logDate, id, body) {
|
|
30
|
-
const filePath = this.pathFor(orgId, eventType, logDate, id);
|
|
31
|
-
try {
|
|
32
|
-
fs.mkdirSync(path.dirname(filePath), { recursive: true });
|
|
33
|
-
fs.writeFileSync(filePath, body, 'utf-8');
|
|
34
|
-
}
|
|
35
|
-
catch (err) {
|
|
36
|
-
process.stderr.write(`[sf-audit] Warning: could not save event log ${id}: ${String(err)}\n`);
|
|
37
|
-
}
|
|
38
|
-
return filePath;
|
|
39
|
-
}
|
|
40
|
-
/** Write a per-run manifest JSON under {root}/{orgId}/_manifests/; returns its path. */
|
|
41
|
-
writeManifest(orgId, manifest) {
|
|
42
|
-
const dir = path.join(this.root, orgId, '_manifests');
|
|
43
|
-
const suffix = Math.random().toString(36).slice(2, 8);
|
|
44
|
-
const filePath = path.join(dir, `manifest-${Date.now()}-${suffix}.json`);
|
|
45
|
-
try {
|
|
46
|
-
fs.mkdirSync(dir, { recursive: true });
|
|
47
|
-
fs.writeFileSync(filePath, JSON.stringify(manifest, null, 2), 'utf-8');
|
|
48
|
-
}
|
|
49
|
-
catch (err) {
|
|
50
|
-
process.stderr.write(`[sf-audit] Warning: could not write event manifest: ${String(err)}\n`);
|
|
51
|
-
}
|
|
52
|
-
return filePath;
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
//# sourceMappingURL=EventBaselineStore.js.map
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
export interface EventLogQueryOptions {
|
|
2
|
-
/** Number of days of LogDate to request (LAST_N_DAYS:N). */
|
|
3
|
-
since: number;
|
|
4
|
-
/** Optional EventType allow-list (already sanitised or not — we sanitise again). */
|
|
5
|
-
types?: string[];
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* Reduce free-form `--types` input to safe EventType tokens. EventTypes are PascalCase
|
|
9
|
-
* identifiers (Login, ApiTotalUsage, LightningError, …), so we strip anything that is not
|
|
10
|
-
* alphanumeric. This doubles as the SOQL-injection guard for the IN clause.
|
|
11
|
-
*/
|
|
12
|
-
export declare function sanitizeTypes(raw: string | undefined): string[];
|
|
13
|
-
/** Normalise a Salesforce LogDate (datetime) to a YYYY-MM-DD string for filenames. */
|
|
14
|
-
export declare function toLogDate(raw: string): string;
|
|
15
|
-
/**
|
|
16
|
-
* Build the read-only EventLogFile discovery query. `Interval = 'Daily'` excludes the paid
|
|
17
|
-
* hourly logs; `LogDate = LAST_N_DAYS:N` bounds the window. `since` is coerced to a
|
|
18
|
-
* non-negative integer and `types` are sanitised, so the interpolated string is injection-safe.
|
|
19
|
-
*/
|
|
20
|
-
export declare function buildEventLogQuery(opts: EventLogQueryOptions): string;
|
|
21
|
-
//# sourceMappingURL=eventLogQuery.d.ts.map
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
// Pure helpers for the `audit events pull` command. Kept free of I/O so they are
|
|
2
|
-
// unit-testable without an org connection or the oclif command harness.
|
|
3
|
-
/**
|
|
4
|
-
* Reduce free-form `--types` input to safe EventType tokens. EventTypes are PascalCase
|
|
5
|
-
* identifiers (Login, ApiTotalUsage, LightningError, …), so we strip anything that is not
|
|
6
|
-
* alphanumeric. This doubles as the SOQL-injection guard for the IN clause.
|
|
7
|
-
*/
|
|
8
|
-
export function sanitizeTypes(raw) {
|
|
9
|
-
if (!raw)
|
|
10
|
-
return [];
|
|
11
|
-
return raw
|
|
12
|
-
.split(',')
|
|
13
|
-
.map((t) => t.replace(/[^A-Za-z0-9]/g, '').trim())
|
|
14
|
-
.filter((t) => t.length > 0);
|
|
15
|
-
}
|
|
16
|
-
/** Normalise a Salesforce LogDate (datetime) to a YYYY-MM-DD string for filenames. */
|
|
17
|
-
export function toLogDate(raw) {
|
|
18
|
-
return String(raw).slice(0, 10);
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Build the read-only EventLogFile discovery query. `Interval = 'Daily'` excludes the paid
|
|
22
|
-
* hourly logs; `LogDate = LAST_N_DAYS:N` bounds the window. `since` is coerced to a
|
|
23
|
-
* non-negative integer and `types` are sanitised, so the interpolated string is injection-safe.
|
|
24
|
-
*/
|
|
25
|
-
export function buildEventLogQuery(opts) {
|
|
26
|
-
const since = Math.max(0, Math.trunc(opts.since));
|
|
27
|
-
const types = (opts.types ?? []).filter((t) => t.length > 0);
|
|
28
|
-
const typeClause = types.length > 0 ? ` AND EventType IN (${types.map((t) => `'${t}'`).join(', ')})` : '';
|
|
29
|
-
return ('SELECT Id, EventType, LogDate, LogFileLength, Interval, LogFileFieldNames ' +
|
|
30
|
-
'FROM EventLogFile ' +
|
|
31
|
-
`WHERE Interval = 'Daily' AND LogDate = LAST_N_DAYS:${since}${typeClause} ` +
|
|
32
|
-
'ORDER BY LogDate');
|
|
33
|
-
}
|
|
34
|
-
//# sourceMappingURL=eventLogQuery.js.map
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import type { SoqlClient } from '../api/SoqlClient.js';
|
|
2
|
-
import type { RestClient } from '../api/RestClient.js';
|
|
3
|
-
import type { EventLogAccess } from '../context/AuditCache.js';
|
|
4
|
-
import { EventBaselineStore } from './EventBaselineStore.js';
|
|
5
|
-
/** The subset of EventLogFile fields the discovery query returns. */
|
|
6
|
-
export interface EventLogFileRow {
|
|
7
|
-
Id: string;
|
|
8
|
-
EventType: string;
|
|
9
|
-
LogDate: string;
|
|
10
|
-
LogFileLength?: number;
|
|
11
|
-
Interval?: string;
|
|
12
|
-
LogFileFieldNames?: string;
|
|
13
|
-
}
|
|
14
|
-
/** Outcome for one EventLogFile row in a run. */
|
|
15
|
-
export interface PulledLog {
|
|
16
|
-
id: string;
|
|
17
|
-
eventType: string;
|
|
18
|
-
logDate: string;
|
|
19
|
-
bytes: number;
|
|
20
|
-
savedPath: string;
|
|
21
|
-
status: 'downloaded' | 'skipped' | 'failed';
|
|
22
|
-
}
|
|
23
|
-
/** Structured result of a pull run — returned by the command. */
|
|
24
|
-
export interface EventsPullResult {
|
|
25
|
-
orgId: string;
|
|
26
|
-
since: number;
|
|
27
|
-
storagePath: string;
|
|
28
|
-
found: number;
|
|
29
|
-
downloaded: number;
|
|
30
|
-
skipped: number;
|
|
31
|
-
failed: number;
|
|
32
|
-
totalBytes: number;
|
|
33
|
-
logs: PulledLog[];
|
|
34
|
-
manifestPath?: string;
|
|
35
|
-
/** Set when the EventLogFile query itself failed (no crash); tells license vs permission apart. */
|
|
36
|
-
accessError?: EventLogAccess;
|
|
37
|
-
}
|
|
38
|
-
export interface PullDeps {
|
|
39
|
-
soql: SoqlClient;
|
|
40
|
-
rest: RestClient;
|
|
41
|
-
store: EventBaselineStore;
|
|
42
|
-
orgId: string;
|
|
43
|
-
}
|
|
44
|
-
export interface PullOptions {
|
|
45
|
-
since: number;
|
|
46
|
-
types?: string[];
|
|
47
|
-
/** Optional sink for non-fatal warnings (per-file download failures). */
|
|
48
|
-
warn?: (msg: string) => void;
|
|
49
|
-
}
|
|
50
|
-
export declare function pullEventLogs(deps: PullDeps, opts: PullOptions): Promise<EventsPullResult>;
|
|
51
|
-
//# sourceMappingURL=pullEventLogs.d.ts.map
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
import { classifyEventLogAccessError } from '../checks/eventLogAccess.js';
|
|
2
|
-
import { buildEventLogQuery, toLogDate } from './eventLogQuery.js';
|
|
3
|
-
export async function pullEventLogs(deps, opts) {
|
|
4
|
-
const { soql, rest, store, orgId } = deps;
|
|
5
|
-
const since = opts.since;
|
|
6
|
-
const storagePath = store.orgDir(orgId);
|
|
7
|
-
const base = {
|
|
8
|
-
orgId,
|
|
9
|
-
since,
|
|
10
|
-
storagePath,
|
|
11
|
-
found: 0,
|
|
12
|
-
downloaded: 0,
|
|
13
|
-
skipped: 0,
|
|
14
|
-
failed: 0,
|
|
15
|
-
totalBytes: 0,
|
|
16
|
-
logs: [],
|
|
17
|
-
};
|
|
18
|
-
let rows;
|
|
19
|
-
try {
|
|
20
|
-
rows = await soql.queryAll(buildEventLogQuery({ since, types: opts.types }));
|
|
21
|
-
}
|
|
22
|
-
catch (err) {
|
|
23
|
-
// Inaccessible EventLogFile (unlicensed / no permission) must not crash the command.
|
|
24
|
-
return { ...base, accessError: classifyEventLogAccessError(err) };
|
|
25
|
-
}
|
|
26
|
-
base.found = rows.length;
|
|
27
|
-
for (const row of rows) {
|
|
28
|
-
const logDate = toLogDate(row.LogDate);
|
|
29
|
-
if (store.has(orgId, row.EventType, logDate, row.Id)) {
|
|
30
|
-
base.skipped += 1;
|
|
31
|
-
base.logs.push({
|
|
32
|
-
id: row.Id,
|
|
33
|
-
eventType: row.EventType,
|
|
34
|
-
logDate,
|
|
35
|
-
bytes: 0,
|
|
36
|
-
savedPath: store.pathFor(orgId, row.EventType, logDate, row.Id),
|
|
37
|
-
status: 'skipped',
|
|
38
|
-
});
|
|
39
|
-
continue;
|
|
40
|
-
}
|
|
41
|
-
try {
|
|
42
|
-
// Stream straight to disk — never buffer the body — so large daily logs don't blow the heap.
|
|
43
|
-
const savedPath = store.pathFor(orgId, row.EventType, logDate, row.Id);
|
|
44
|
-
const bytes = await rest.getRawToFile(`/sobjects/EventLogFile/${row.Id}/LogFile`, savedPath);
|
|
45
|
-
base.downloaded += 1;
|
|
46
|
-
base.totalBytes += bytes;
|
|
47
|
-
base.logs.push({ id: row.Id, eventType: row.EventType, logDate, bytes, savedPath, status: 'downloaded' });
|
|
48
|
-
}
|
|
49
|
-
catch (err) {
|
|
50
|
-
base.failed += 1;
|
|
51
|
-
base.logs.push({
|
|
52
|
-
id: row.Id,
|
|
53
|
-
eventType: row.EventType,
|
|
54
|
-
logDate,
|
|
55
|
-
bytes: 0,
|
|
56
|
-
savedPath: store.pathFor(orgId, row.EventType, logDate, row.Id),
|
|
57
|
-
status: 'failed',
|
|
58
|
-
});
|
|
59
|
-
opts.warn?.(`Failed to download EventLogFile ${row.Id} (${row.EventType} ${logDate}): ${String(err)}`);
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
// Only write a manifest when something was actually captured — a pure all-skipped or
|
|
63
|
-
// empty run leaves no new record to make.
|
|
64
|
-
if (base.downloaded > 0) {
|
|
65
|
-
base.manifestPath = store.writeManifest(orgId, {
|
|
66
|
-
orgId,
|
|
67
|
-
since,
|
|
68
|
-
pulledAt: new Date().toISOString(),
|
|
69
|
-
found: base.found,
|
|
70
|
-
downloaded: base.downloaded,
|
|
71
|
-
skipped: base.skipped,
|
|
72
|
-
failed: base.failed,
|
|
73
|
-
totalBytes: base.totalBytes,
|
|
74
|
-
logs: base.logs,
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
return base;
|
|
78
|
-
}
|
|
79
|
-
//# sourceMappingURL=pullEventLogs.js.map
|