@slicedearth/whoisleuth-cli 1.45.0 → 1.47.4
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/DISCLOSURE +7 -3
- package/NOTICE +5 -4
- package/README.md +59 -6
- package/bin/whoisleuth.mjs +5 -3
- package/cli/arguments.mjs +256 -9
- package/cli/artifact-structure.mjs +1833 -0
- package/cli/artifact-verify.mjs +242 -49
- package/cli/bounded-json.mjs +1 -0
- package/cli/bulk-checkpoint.mjs +2 -3
- package/cli/bulk-command-runner.mjs +2 -5
- package/cli/case-pack.mjs +819 -34
- package/cli/command-reference.mjs +48 -24
- package/cli/completion.mjs +16 -8
- package/cli/ct-event-intake.mjs +32 -2
- package/cli/discovery-scan-command-runner.mjs +4 -5
- package/cli/discovery-workflow.mjs +2 -3
- package/cli/doctor.mjs +2 -2
- package/cli/domain-control-monitor.mjs +21 -15
- package/cli/domain-control-observations.mjs +25 -2
- package/cli/evidence-command-runner.mjs +17 -11
- package/cli/evidence-signing.mjs +73 -45
- package/cli/export-evidence.mjs +11 -4
- package/cli/formatters/html.mjs +3 -3
- package/cli/formatters/terminal.mjs +3 -0
- package/cli/input.mjs +57 -0
- package/cli/interchange-report.mjs +226 -0
- package/cli/investigation-manifest.mjs +16 -17
- package/cli/investigation-run.mjs +71 -23
- package/cli/local-mmdb-review.mjs +45 -14
- package/cli/lookup-command-runner.mjs +2 -2
- package/cli/lookup-diff.mjs +9 -0
- package/cli/network-command-runner.mjs +78 -0
- package/cli/offline-evidence-review.mjs +28 -8
- package/cli/page-compare.mjs +8 -5
- package/cli/registry-cohort.mjs +385 -61
- package/cli/registry-support.mjs +2 -1
- package/cli/retained-artifact-diff.mjs +376 -0
- package/cli/risk-calibration.mjs +7 -5
- package/cli/runner.mjs +147 -185
- package/cli/saved-lookup.mjs +26 -3
- package/cli/sharing-review.mjs +12 -6
- package/docs/cli-reference.md +444 -70
- package/docs/cli.md +24 -5
- package/frontend/src/lib/analysis/acquisition-decision-packet.js +4 -4
- package/frontend/src/lib/analysis/artifact-integrity.js +42 -0
- package/frontend/src/lib/analysis/brand-profile-model.js +29 -5
- package/frontend/src/lib/analysis/bulk-domain-comparison.js +25 -5
- package/frontend/src/lib/analysis/bulk-mail-exposure.js +66 -15
- package/frontend/src/lib/analysis/bulk-retry-plan.js +1 -1
- package/frontend/src/lib/analysis/bulk-review-export.js +7 -6
- package/frontend/src/lib/analysis/bulk-review-model.js +3 -2
- package/frontend/src/lib/analysis/bulk-session-model.js +192 -26
- package/frontend/src/lib/analysis/bulk-sort.js +4 -0
- package/frontend/src/lib/analysis/case-brand-profile-references.js +85 -0
- package/frontend/src/lib/analysis/case-evidence-model.js +8 -0
- package/frontend/src/lib/analysis/case-investigation-branch-model.js +134 -0
- package/frontend/src/lib/analysis/case-migration-model.js +83 -31
- package/frontend/src/lib/analysis/case-record-contracts.js +4 -2
- package/frontend/src/lib/analysis/case-record-model.js +2 -0
- package/frontend/src/lib/analysis/case-record-operations.js +42 -12
- package/frontend/src/lib/analysis/case-report.js +39 -6
- package/frontend/src/lib/analysis/case-response-model.js +66 -7
- package/frontend/src/lib/analysis/case-response-packet.js +15 -5
- package/frontend/src/lib/analysis/comparison-ledger-bulk.js +366 -0
- package/frontend/src/lib/analysis/comparison-ledger-contract.js +241 -0
- package/frontend/src/lib/analysis/comparison-ledger-json.js +79 -0
- package/frontend/src/lib/analysis/comparison-ledger-serialization.js +51 -0
- package/frontend/src/lib/analysis/domain-control-manifest-core.js +145 -0
- package/frontend/src/lib/analysis/domain-control-records.js +88 -0
- package/frontend/src/lib/analysis/external-findings-import.js +70 -6
- package/frontend/src/lib/analysis/investigation-capsule.js +47 -13
- package/frontend/src/lib/analysis/investigation-guide.js +52 -10
- package/frontend/src/lib/analysis/investigation-template-model.js +9 -6
- package/frontend/src/lib/analysis/lookup-claim-passport.js +236 -0
- package/frontend/src/lib/analysis/lookup-claim-readiness.js +280 -0
- package/frontend/src/lib/analysis/lookup-decision-support.js +61 -6
- package/frontend/src/lib/analysis/lookup-presentation.js +62 -0
- package/frontend/src/lib/analysis/opaque-reference-id.js +9 -0
- package/frontend/src/lib/analysis/utils.js +26 -3
- package/frontend/src/lib/analysis/visualization-matrix.js +71 -28
- package/frontend/src/lib/analysis/visualization-models.js +63 -94
- package/frontend/src/lib/analysis/visualization-time-series.js +53 -12
- package/frontend/src/lib/analysis/website-snapshot-model.js +6 -0
- package/frontend/src/lib/analysis/workspace-archive.js +104 -14
- package/lib/application-version.mjs +3 -0
- package/lib/availability.mjs +14 -12
- package/lib/bounded-file.mjs +13 -0
- package/lib/bounded-json-response.mjs +17 -4
- package/lib/bounded-json.mjs +249 -0
- package/lib/certificate-extension-profile.mjs +2 -1
- package/lib/cryptographic-assurance.mjs +155 -0
- package/lib/ct-search.mjs +87 -47
- package/lib/dns-intelligence.mjs +3 -2
- package/lib/dns-resolver-selection.mjs +6 -4
- package/lib/dnssec-chain-validation.mjs +1053 -0
- package/lib/dnssec-evidence-validation.mjs +10 -3
- package/lib/domain-change-packet.mjs +7 -5
- package/lib/domain-control-manifest.mjs +17 -129
- package/lib/domain-posture.mjs +7 -4
- package/lib/evidence-export.mjs +751 -78
- package/lib/evidence-report-markdown.mjs +3 -0
- package/lib/evidence-report.mjs +5 -0
- package/lib/favicon.mjs +8 -5
- package/lib/http-evidence-bounds.mjs +3 -0
- package/lib/http-intelligence.mjs +2 -5
- package/lib/interchange-fidelity-registry.mjs +122 -0
- package/lib/local-geoip-evidence.mjs +2 -1
- package/lib/lookup-network-evidence-bounds.mjs +9 -0
- package/lib/lookup-response-contract.mjs +691 -3
- package/lib/lookup.mjs +2 -2
- package/lib/observation.mjs +7 -6
- package/lib/outbound-identity.mjs +2 -3
- package/lib/perceptual-hash.mjs +12 -4
- package/lib/portable-generator.mjs +21 -0
- package/lib/provider-policy-admission.mjs +9 -4
- package/lib/rdap-normalization.mjs +18 -5
- package/lib/rdap-registrar.mjs +5 -1
- package/lib/registry-capabilities.mjs +3 -0
- package/lib/registry-capability-catalogue.mjs +12 -2
- package/lib/registry-comparison.mjs +28 -11
- package/lib/risk-calibration-summary.mjs +338 -0
- package/lib/rpki-evidence.mjs +9 -8
- package/lib/safe-fetch.mjs +59 -10
- package/lib/security-txt.mjs +26 -3
- package/lib/service-binding-dns.mjs +6 -1
- package/lib/smtp-transport-review.mjs +784 -0
- package/lib/sslbl-certificates.generated.mjs +136 -134
- package/lib/threat-intelligence-runtime.mjs +3 -11
- package/lib/threat-intelligence-types.mjs +18 -1
- package/lib/tls-intelligence.mjs +11 -5
- package/lib/tlsa-evidence.mjs +37 -7
- package/package.json +1 -1
- package/third-party-notices.txt +95 -5817
|
@@ -63,6 +63,9 @@ function formatLookupEvidenceMarkdown(document, options = {}) {
|
|
|
63
63
|
lines.push('', '## Limitations', '');
|
|
64
64
|
for (const limitation of report.limitations)
|
|
65
65
|
lines.push(`- ${limitation}`);
|
|
66
|
+
if (report.attribution) {
|
|
67
|
+
lines.push('', '---', '', report.attribution);
|
|
68
|
+
}
|
|
66
69
|
lines.push('');
|
|
67
70
|
return lines.join('\n');
|
|
68
71
|
}
|
package/lib/evidence-report.mjs
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { registryAccessProfileLabel } from "./registry-access.mjs";
|
|
2
|
+
import { buildPortableGeneratorMetadata, portableGeneratorAttribution, } from "./portable-generator.mjs";
|
|
2
3
|
const MAX_REPORT_VALUE_LENGTH = 300;
|
|
3
4
|
const MAX_REPORT_LIST_ITEMS = 50;
|
|
4
5
|
const MAX_REPORT_COMPARISON_FIELDS = 20;
|
|
@@ -90,6 +91,7 @@ function reportField(label, value, fallback = 'Not reported') {
|
|
|
90
91
|
function buildLookupEvidenceReport(document, options = {}) {
|
|
91
92
|
const report = objectOrEmpty(document);
|
|
92
93
|
const application = objectOrEmpty(report.application);
|
|
94
|
+
const generator = buildPortableGeneratorMetadata(application.version);
|
|
93
95
|
const query = objectOrEmpty(report.query);
|
|
94
96
|
const diagnostics = objectOrEmpty(report.diagnostics);
|
|
95
97
|
const rdapDiagnostics = objectOrEmpty(diagnostics.rdap);
|
|
@@ -389,6 +391,9 @@ function buildLookupEvidenceReport(document, options = {}) {
|
|
|
389
391
|
'Registry access constraints describe collection reachability only. They do not decide registration, availability, ownership, safety, or maliciousness.',
|
|
390
392
|
] : []),
|
|
391
393
|
],
|
|
394
|
+
attribution: options.includeAttribution === false
|
|
395
|
+
? null
|
|
396
|
+
: portableGeneratorAttribution(generator),
|
|
392
397
|
};
|
|
393
398
|
}
|
|
394
399
|
export { MAX_REPORT_COMPARISON_FIELDS, MAX_REPORT_LIST_ITEMS, MAX_REPORT_RISK_FACTORS, MAX_REPORT_VALUE_LENGTH, buildLookupEvidenceReport, cleanReportText, };
|
package/lib/favicon.mjs
CHANGED
|
@@ -73,13 +73,13 @@ function decodeDataUri(uri) {
|
|
|
73
73
|
}
|
|
74
74
|
// Returns the favicon bytes for one candidate URL (a real fetch, or an inline
|
|
75
75
|
// data: decode), or null if it can't be retrieved/used.
|
|
76
|
-
async function fetchFaviconBytes(url, headers) {
|
|
76
|
+
async function fetchFaviconBytes(url, headers, fetcher, timeoutMs) {
|
|
77
77
|
if (/^data:/i.test(url))
|
|
78
78
|
return decodeDataUri(url);
|
|
79
79
|
const controller = new AbortController();
|
|
80
|
-
const timeout = setTimeout(() => controller.abort(),
|
|
80
|
+
const timeout = setTimeout(() => controller.abort(), timeoutMs);
|
|
81
81
|
try {
|
|
82
|
-
const res = await
|
|
82
|
+
const res = await fetcher(url, { signal: controller.signal, headers });
|
|
83
83
|
if (!res.ok) {
|
|
84
84
|
// Not reading this body - release it explicitly instead of leaving an
|
|
85
85
|
// unconsumed stream (and the connection it's tied to) open until
|
|
@@ -123,12 +123,15 @@ function buildFaviconCandidates(domain, html = '') {
|
|
|
123
123
|
add(`http://${domain}/favicon.svg`);
|
|
124
124
|
return candidates.slice(0, MAX_FAVICON_CANDIDATES);
|
|
125
125
|
}
|
|
126
|
-
async function fetchFaviconHash(domain, { html = '' } = {}) {
|
|
126
|
+
async function fetchFaviconHash(domain, { html = '', fetcher = safeFetch, timeoutMs = FAVICON_FETCH_TIMEOUT_MS } = {}) {
|
|
127
127
|
const headers = whoisleuthRequestHeaders();
|
|
128
128
|
const candidates = buildFaviconCandidates(domain, html);
|
|
129
|
+
const requestTimeoutMs = Number.isInteger(timeoutMs) && timeoutMs >= 10 && timeoutMs <= FAVICON_FETCH_TIMEOUT_MS
|
|
130
|
+
? timeoutMs
|
|
131
|
+
: FAVICON_FETCH_TIMEOUT_MS;
|
|
129
132
|
for (const url of candidates) {
|
|
130
133
|
// eslint-disable-next-line no-await-in-loop
|
|
131
|
-
const bytes = await fetchFaviconBytes(url, headers);
|
|
134
|
+
const bytes = await fetchFaviconBytes(url, headers, fetcher, requestTimeoutMs);
|
|
132
135
|
if (bytes) {
|
|
133
136
|
return {
|
|
134
137
|
hash: crypto.createHash('sha256').update(bytes).digest('hex'),
|
|
@@ -2,3 +2,6 @@
|
|
|
2
2
|
// browser-local projection. Both producers and consumers import these values
|
|
3
3
|
// so valid retained evidence is not rejected by a stale projection.
|
|
4
4
|
export const MAX_HTTP_EVIDENCE_REDIRECTS = 5;
|
|
5
|
+
export const MAX_HTTP_ATTEMPTS = 2;
|
|
6
|
+
export const MAX_HTTP_PROVENANCE_URL = 2_048;
|
|
7
|
+
export const MAX_HTTP_ERROR_LENGTH = 180;
|
|
@@ -3,11 +3,8 @@
|
|
|
3
3
|
// converts the shared safe-fetch trace and selected response metadata into an
|
|
4
4
|
// additive evidence object suitable for API responses and exports.
|
|
5
5
|
import { createObservation } from "./observation.mjs";
|
|
6
|
-
import { MAX_HTTP_EVIDENCE_REDIRECTS } from "./http-evidence-bounds.mjs";
|
|
7
|
-
const MAX_HTTP_PROVENANCE_URL = 2048;
|
|
6
|
+
import { MAX_HTTP_ATTEMPTS, MAX_HTTP_ERROR_LENGTH, MAX_HTTP_EVIDENCE_REDIRECTS, MAX_HTTP_PROVENANCE_URL, } from "./http-evidence-bounds.mjs";
|
|
8
7
|
const MAX_HTTP_REDIRECTS = MAX_HTTP_EVIDENCE_REDIRECTS;
|
|
9
|
-
const MAX_HTTP_ATTEMPTS = 2;
|
|
10
|
-
const MAX_HTTP_ERROR_LENGTH = 180;
|
|
11
8
|
const MAX_HTTP_HEADER_LENGTH = 1024;
|
|
12
9
|
const MAX_CAPTURED_BODY_BYTES = 5 * 1024 * 1024;
|
|
13
10
|
const OBSERVED_HEADER_MARKER = 'observed';
|
|
@@ -230,4 +227,4 @@ function skippedHttpObservation() {
|
|
|
230
227
|
response: null,
|
|
231
228
|
};
|
|
232
229
|
}
|
|
233
|
-
export { MAX_HTTP_PROVENANCE_URL, MAX_HTTP_REDIRECTS, MAX_HTTP_ATTEMPTS, normalizeProvenanceUrl, buildHttpObservation, failedHttpObservation, skippedHttpObservation, };
|
|
230
|
+
export { MAX_HTTP_ERROR_LENGTH, MAX_HTTP_PROVENANCE_URL, MAX_HTTP_REDIRECTS, MAX_HTTP_ATTEMPTS, normalizeProvenanceUrl, buildHttpObservation, failedHttpObservation, skippedHttpObservation, };
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
const exact = Object.freeze(['domain_identity', 'dns_control_expectations', 'certificate_control_expectations', 'registrar_control_expectations', 'renewal_review']);
|
|
2
|
+
export const INTERCHANGE_ARTIFACT_CONTRACTS = Object.freeze([
|
|
3
|
+
Object.freeze({
|
|
4
|
+
id: 'lookup_claim_passport',
|
|
5
|
+
schema: 'whoisleuth.lookup-claim-passport',
|
|
6
|
+
versions: Object.freeze([1]),
|
|
7
|
+
versionField: 'version',
|
|
8
|
+
nestedSchemaPath: Object.freeze([]),
|
|
9
|
+
browser: Object.freeze({ import: 'unsupported', export: 'supported' }),
|
|
10
|
+
cli: Object.freeze({ read: 'supported', write: 'unsupported', verify: 'supported' }),
|
|
11
|
+
fidelity: 'semantic_exact_after_normalisation',
|
|
12
|
+
requiredAssurance: 'whole_integrity',
|
|
13
|
+
preservedFieldGroups: Object.freeze(['target_identity', 'claim_identity', 'evidence_requirement_ids', 'source_states', 'observation_times', 'model_versions', 'limitations']),
|
|
14
|
+
excludedFieldGroups: Object.freeze(['raw_registry_payloads', 'contacts', 'page_values', 'request_paths', 'credentials', 'browser_local_records', 'signer_authentication']),
|
|
15
|
+
futureVersionBehaviour: 'reject',
|
|
16
|
+
}),
|
|
17
|
+
Object.freeze({
|
|
18
|
+
id: 'lookup_evidence',
|
|
19
|
+
schema: LOOKUP_EVIDENCE_SCHEMA,
|
|
20
|
+
versions: Object.freeze([...SUPPORTED_LOOKUP_EVIDENCE_SCHEMA_VERSIONS]),
|
|
21
|
+
versionField: 'schemaVersion',
|
|
22
|
+
nestedSchemaPath: Object.freeze([]),
|
|
23
|
+
browser: Object.freeze({ import: 'supported', export: 'supported' }),
|
|
24
|
+
cli: Object.freeze({ read: 'supported', write: 'supported', verify: 'supported' }),
|
|
25
|
+
fidelity: 'lossy_by_design',
|
|
26
|
+
requiredAssurance: 'structure',
|
|
27
|
+
preservedFieldGroups: Object.freeze(['query_context', 'generator_metadata', 'source_health', 'normalised_registration_evidence', 'bounded_replay_facts', 'observation_times', 'limitations']),
|
|
28
|
+
excludedFieldGroups: Object.freeze(['browser_local_records', 'case_context', 'brand_profiles', 'credentials', 'session_material', 'request_headers', 'cookies', 'signer_authentication', 'raw_payload_rendering_during_replay']),
|
|
29
|
+
futureVersionBehaviour: 'reject',
|
|
30
|
+
}),
|
|
31
|
+
Object.freeze({
|
|
32
|
+
id: 'domain_control_passport',
|
|
33
|
+
schema: 'whoisleuth.domain-control-manifest',
|
|
34
|
+
versions: Object.freeze([1, 2]),
|
|
35
|
+
versionField: 'version',
|
|
36
|
+
nestedSchemaPath: Object.freeze([]),
|
|
37
|
+
browser: Object.freeze({ import: 'supported', export: 'supported' }),
|
|
38
|
+
cli: Object.freeze({ read: 'supported', write: 'supported', verify: 'supported' }),
|
|
39
|
+
fidelity: 'semantic_exact_after_normalisation',
|
|
40
|
+
requiredAssurance: 'whole_integrity',
|
|
41
|
+
preservedFieldGroups: exact,
|
|
42
|
+
excludedFieldGroups: Object.freeze(['profile_identity', 'brand_context', 'contacts', 'notes', 'observations', 'planning_context', 'suppression_context']),
|
|
43
|
+
futureVersionBehaviour: 'reject',
|
|
44
|
+
}),
|
|
45
|
+
Object.freeze({
|
|
46
|
+
id: 'brand_profiles',
|
|
47
|
+
schema: 'whoisleuth.brand-profiles',
|
|
48
|
+
versions: Object.freeze([2, 3, 4, 5, 6]),
|
|
49
|
+
versionField: 'version',
|
|
50
|
+
nestedSchemaPath: Object.freeze([]),
|
|
51
|
+
browser: Object.freeze({ import: 'supported', export: 'supported' }),
|
|
52
|
+
cli: Object.freeze({ read: 'supported', write: 'unsupported', verify: 'verification_only' }),
|
|
53
|
+
fidelity: 'normalised_merge',
|
|
54
|
+
requiredAssurance: 'structure',
|
|
55
|
+
preservedFieldGroups: Object.freeze(['profile_identity', 'brand_context', 'domain_scope', 'mail_posture', 'desired_posture', 'reviewed_planning', 'retained_observations']),
|
|
56
|
+
excludedFieldGroups: Object.freeze(['login_sessions', 'credentials', 'raw_upstream_payloads']),
|
|
57
|
+
futureVersionBehaviour: 'reject',
|
|
58
|
+
}),
|
|
59
|
+
Object.freeze({
|
|
60
|
+
id: 'workspace',
|
|
61
|
+
schema: 'whoisleuth.workspace-archive',
|
|
62
|
+
versions: Object.freeze([1, 2, 3, 4, 5]),
|
|
63
|
+
versionField: 'version',
|
|
64
|
+
nestedSchemaPath: Object.freeze([]),
|
|
65
|
+
browser: Object.freeze({ import: 'supported', export: 'supported' }),
|
|
66
|
+
cli: Object.freeze({ read: 'verification_only', write: 'unsupported', verify: 'supported' }),
|
|
67
|
+
fidelity: 'normalised_merge',
|
|
68
|
+
requiredAssurance: 'whole_integrity',
|
|
69
|
+
preservedFieldGroups: Object.freeze(['supported_workspace_sections', 'section_versions', 'section_checksums', 'merge_metadata']),
|
|
70
|
+
excludedFieldGroups: Object.freeze(['login_sessions', 'credentials', 'hosted_monitor_keys', 'raw_upstream_payloads', 'tab_state']),
|
|
71
|
+
futureVersionBehaviour: 'reject',
|
|
72
|
+
}),
|
|
73
|
+
Object.freeze({
|
|
74
|
+
id: 'encrypted_workspace',
|
|
75
|
+
schema: 'whoisleuth.encrypted-workspace-archive',
|
|
76
|
+
versions: Object.freeze([1]),
|
|
77
|
+
versionField: 'version',
|
|
78
|
+
nestedSchemaPath: Object.freeze([]),
|
|
79
|
+
browser: Object.freeze({ import: 'supported', export: 'supported' }),
|
|
80
|
+
cli: Object.freeze({ read: 'verification_only', write: 'unsupported', verify: 'supported' }),
|
|
81
|
+
fidelity: 'verification_only',
|
|
82
|
+
requiredAssurance: 'authenticated_whole_integrity',
|
|
83
|
+
preservedFieldGroups: Object.freeze(['encrypted_workspace_envelope', 'authenticated_ciphertext', 'inner_workspace_after_decryption']),
|
|
84
|
+
excludedFieldGroups: Object.freeze(['passphrase', 'derived_key']),
|
|
85
|
+
futureVersionBehaviour: 'reject',
|
|
86
|
+
}),
|
|
87
|
+
Object.freeze({
|
|
88
|
+
id: 'case_pack',
|
|
89
|
+
schema: 'whoisleuth.cli.case-pack',
|
|
90
|
+
versions: Object.freeze([1, 2]),
|
|
91
|
+
versionField: 'version',
|
|
92
|
+
nestedSchemaPath: Object.freeze(['packet']),
|
|
93
|
+
browser: Object.freeze({ import: 'supported', export: 'unsupported' }),
|
|
94
|
+
cli: Object.freeze({ read: 'supported', write: 'supported', verify: 'supported' }),
|
|
95
|
+
fidelity: 'lossy_by_design',
|
|
96
|
+
requiredAssurance: 'whole_integrity',
|
|
97
|
+
preservedFieldGroups: Object.freeze(['redacted_case_collection', 'case_schema_version', 'trusted_internal_case_brand_profile_references']),
|
|
98
|
+
excludedFieldGroups: Object.freeze(['package_reports', 'package_redaction_manifest', 'package_integrity_envelope', 'audience_excluded_case_fields', 'public_audience_case_brand_profile_references']),
|
|
99
|
+
futureVersionBehaviour: 'reject',
|
|
100
|
+
}),
|
|
101
|
+
Object.freeze({
|
|
102
|
+
id: 'legacy_desired_baseline',
|
|
103
|
+
schema: 'whoisleuth.desired-posture-baseline',
|
|
104
|
+
versions: Object.freeze([1]),
|
|
105
|
+
versionField: 'schemaVersion',
|
|
106
|
+
nestedSchemaPath: Object.freeze([]),
|
|
107
|
+
browser: Object.freeze({ import: 'unsupported', export: 'unsupported' }),
|
|
108
|
+
cli: Object.freeze({ read: 'unsupported', write: 'unsupported', verify: 'unsupported' }),
|
|
109
|
+
fidelity: 'unsupported',
|
|
110
|
+
requiredAssurance: 'unsupported',
|
|
111
|
+
preservedFieldGroups: Object.freeze([]),
|
|
112
|
+
excludedFieldGroups: Object.freeze(['entire_legacy_document']),
|
|
113
|
+
futureVersionBehaviour: 'reject',
|
|
114
|
+
}),
|
|
115
|
+
]);
|
|
116
|
+
export function interchangeContractFor(id) {
|
|
117
|
+
const contract = INTERCHANGE_ARTIFACT_CONTRACTS.find((item) => item.id === id);
|
|
118
|
+
if (!contract)
|
|
119
|
+
throw new TypeError('Interchange contract is not registered.');
|
|
120
|
+
return contract;
|
|
121
|
+
}
|
|
122
|
+
import { LOOKUP_EVIDENCE_SCHEMA, SUPPORTED_LOOKUP_EVIDENCE_SCHEMA_VERSIONS, } from "./evidence-export.mjs";
|
|
@@ -64,8 +64,9 @@ function lookupLocalGeoIp(database, address) {
|
|
|
64
64
|
return Object.freeze({ state: 'invalid', address: null, match: null, source: null, limitations: Object.freeze([]) });
|
|
65
65
|
}
|
|
66
66
|
const match = database.records.find((item) => prefixContains(item.parsedNetwork, target)) ?? null;
|
|
67
|
+
const incomplete = database.truncated || database.rejectedCount > 0;
|
|
67
68
|
return Object.freeze({
|
|
68
|
-
state: match ?
|
|
69
|
+
state: match ? incomplete ? 'partial' : 'matched' : incomplete ? 'partial' : 'not_found',
|
|
69
70
|
address: normalized,
|
|
70
71
|
match: match ? Object.freeze({
|
|
71
72
|
network: match.network,
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
// Browser-safe collection bounds shared by the network evidence producers,
|
|
2
|
+
// the Lookup response trust boundary, and the display projection.
|
|
3
|
+
export const MAX_LOOKUP_DNS_RECORDS_PER_TYPE = 16;
|
|
4
|
+
export const MAX_LOOKUP_REVERSE_DNS_PTR_RECORDS = 8;
|
|
5
|
+
export const MAX_LOOKUP_TLS_CHAIN_CERTIFICATES = 8;
|
|
6
|
+
export const MAX_LOOKUP_TLS_ALT_NAMES = 50;
|
|
7
|
+
export const MAX_LOOKUP_TLS_NAME_VALUES = 4;
|
|
8
|
+
export const MAX_LOOKUP_TLS_FINDINGS = 5;
|
|
9
|
+
export const MAX_LOOKUP_TLS_CERTIFICATE_POLICIES = 16;
|