@go-to-k/cdkd 0.296.6 → 0.296.7
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/dist/{asg-provider-C1TlpooI.js → asg-provider-BU0YONBp.js} +2 -2
- package/dist/{asg-provider-C1TlpooI.js.map → asg-provider-BU0YONBp.js.map} +1 -1
- package/dist/cli.js +2 -2
- package/dist/{deploy-engine-BPcBCyUE.js → deploy-engine-wyaJUA8V.js} +493 -336
- package/dist/deploy-engine-wyaJUA8V.js.map +1 -0
- package/dist/{iam-role-provider-CVIClaZV.js → iam-role-provider-obY72uH2.js} +117 -6
- package/dist/iam-role-provider-obY72uH2.js.map +1 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/{neptune-provider-CvY6ekmg.js → neptune-provider-C3f-vDOh.js} +2 -2
- package/dist/{neptune-provider-CvY6ekmg.js.map → neptune-provider-C3f-vDOh.js.map} +1 -1
- package/dist/{program-CAlg2KEF.js → program-DEnDp4o0.js} +4 -4
- package/dist/{program-CAlg2KEF.js.map → program-DEnDp4o0.js.map} +1 -1
- package/dist/{provider-classes-oRTqcSCp.js → provider-classes-CsF7Ia5F.js} +61 -110
- package/dist/provider-classes-CsF7Ia5F.js.map +1 -0
- package/dist/{rds-provider-DeGFzOUc.js → rds-provider-Cf5P2so_.js} +2 -2
- package/dist/{rds-provider-DeGFzOUc.js.map → rds-provider-Cf5P2so_.js.map} +1 -1
- package/dist/{version-BgqcIKdb.js → version-LalLOhpQ.js} +2 -2
- package/dist/{version-BgqcIKdb.js.map → version-LalLOhpQ.js.map} +1 -1
- package/package.json +1 -1
- package/dist/deploy-engine-BPcBCyUE.js.map +0 -1
- package/dist/iam-role-provider-CVIClaZV.js.map +0 -1
- package/dist/provider-classes-oRTqcSCp.js.map +0 -1
|
@@ -2,7 +2,7 @@ import { r as getAwsClients, s as __exportAll } from "./aws-clients-CnmtbrxD.js"
|
|
|
2
2
|
import { A as displayIdent, C as withoutGeneratedFallbackName, D as UNRENDERABLE, E as STACK_REF_MAX_CODE_POINTS, F as plainIdentOr, I as safeMsg, M as displayStackName, N as isPasteableIdent, R as truncateCodePoints, S as withStackName, T as SECRET_REF_MAX_CODE_POINTS, _ as generateResourceNameWithFallback, b as looksLikeCdkdGeneratedName, c as installLogLineMaskerSource, g as generateResourceName, h as explicitNamePropertyFor, j as displaySafe, k as displayAwsMessage, l as getLiveRenderer, n as getLogger, p as applyDefaultNameForFallback, r as isStdoutReservedForPayload, s as currentLogLineMasker, v as getCurrentSkipPrefix, x as withSkipPrefix, y as getCurrentStackName } from "./logger-DAaB7GFO.js";
|
|
3
3
|
import { $n as markRedactedCause, $t as LockError, A as isTerminalDeleteFailure, At as CUSTOM_RESOURCE_RESPONSE_PREFIX, Bn as isAmbiguousCcHandlerErrorCode, Bt as clientDefaultsFor, C as refusalTypeShown, Cn as physicalIdShownBesideCommand, Ct as buildForceUnlockCommand, D as ProtectionFlipRegistry, Dn as shellQuote, Dt as formatLockOperation, En as shellBoundedDisplay, Et as formatLockExpiry, Fn as isRecreateRetryableError, Ft as producerRecordKey, Gn as retryClassificationText, H as pasteableAwsCommand, Hn as isIamPropagationError, Ht as AccountIdUnavailableError, In as isReplayedNameCollisionFrom, J as isInterruptedWaitError, Jn as safeStringify$1, Kn as describeAwsFailure, Kt as CrossAccountSecretRefusalError, Lt as withPasteableAwsProfile, M as observeThenDisableProtection, Mn as hasReplayMayCollide, Mt as injectiveKey, N as protectionFlipKey, Nn as isNameCollisionErrorFrom, O as compensateProtectionFlip, On as withheldTargetClause, Ot as formatLockOwner, Pn as isNameCooldownError, Q as canonicalizeRoute53QueryName, Qn as markNonRetryable, R as DELETION_PROTECTION_DOC_POINTER, Rn as markReplayMayCollide, Rt as ambientClientDefaults, S as quotedRemedyLogicalId, Sn as pasteableCommand, St as UNREPRODUCIBLE_LOCK_CLAUSE, T as resolveExplicitPhysicalId, Tn as quotedOrDescribed, U as protectedReplacementAdvice, Un as isRetryableTransientError, Ut as AssetError, Vn as isAmbiguousOutcomeError, Vt as credentialFingerprint, Wn as isTransientServerError, Wt as CdkdError, X as ElapsedBudgetRegistry, Xn as isMarkedNonRetryable, Xt as IntrinsicResolutionRefusalError, Y as startInterruptWatch, Yt as DynamicReferenceRegionAmbiguousError, Z as monotonicNowMs, Zn as isThrottlingError, _n as SHELL_ACTIVE_WHY, _t as hasCreatedBeforeFailure, an as ResourceTimeoutError, at as segmentAfterAnchor, b as isQuotableImportValue, bt as markAuxiliaryFailure, ct as createMaskedRetryLogger, d as prepareRemovalForUpdate, dt as maskerOrIdentity, en as MacroExpansionError, er as wrapMaskedAwsError, et as compositeIdSeparatorRefusal, f as removalWarning, ft as withDerivedNameMasks, g as assertRegionMatch, gn as SHELL_ACTIVE, gt as createdBeforeFailure, h as RESOURCE_NOT_FOUND, i as holdsSecretDerivedEntry, in as ProvisioningError, it as resourceTypeShown, jn as isUpdateUnsupportedError, jt as DEFAULT_STATE_PREFIX, k as deleteWithProtectionCompensation, kt as sanitizeRecoveryValue, l as withUnchangedSecretPrincipalLists, ln as StateError, lt as isSecretDerivedValue, m as withoutInjectedRemovals, mt as carryCreatedBeforeFailure, nt as logicalIdShown, on as ResourceUpdateNotSupportedError, ot as stateOrphanRecordRemedy, pn as normalizeAwsError, pt as RETRY_AUXILIARY_OWNER, qt as DependencyError, st as createMaskedLogSinks, tn as MalformedProducerRecordRefusalError, un as SynthesisError, ut as maskDeep, vn as UNSHOWABLE_VALUE, vt as isAuxiliaryFailure, wn as plainOrDescribed, x as normalizeAwsTagsToCfn, xn as isInertUnquoted, xt as markCreatedBeforeFailure, yn as commandHole, yt as isAuxiliaryMarkOf, zn as formatRetryClassificationSignals, zt as ambientCredentialConfig } from "./iam-policy-targets-td1X_kKN.js";
|
|
4
4
|
import { a as setAssumedRoleCredentials, i as getPreAssumeEnvCredentials, n as awsClientDefaults, o as setPreAssumeEnvCredentials, r as getAssumedRoleCredentials, s as ambientRegion, t as SECOND_ROLE_PUBLISH_REFUSAL } from "./aws-client-defaults-D0q0z4dG.js";
|
|
5
|
-
import { t as getCdkdVersion } from "./version-
|
|
5
|
+
import { t as getCdkdVersion } from "./version-LalLOhpQ.js";
|
|
6
6
|
import { createHash, randomUUID } from "node:crypto";
|
|
7
7
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
8
8
|
import { CreateBucketCommand, DeleteObjectCommand, DeleteObjectsCommand, GetBucketLocationCommand, GetBucketReplicationCommand, GetObjectCommand, HeadBucketCommand, HeadObjectCommand, ListObjectVersionsCommand, ListObjectsV2Command, NoSuchKey, PutBucketEncryptionCommand, PutBucketPolicyCommand, PutObjectCommand, PutPublicAccessBlockCommand, S3Client, S3ServiceException } from "@aws-sdk/client-s3";
|
|
@@ -6822,6 +6822,330 @@ function positionListByCrossStackSource(bag, source, secrets) {
|
|
|
6822
6822
|
return certifiedListForLeaf(secrets, association, bag);
|
|
6823
6823
|
}
|
|
6824
6824
|
|
|
6825
|
+
//#endregion
|
|
6826
|
+
//#region src/deployment/secret-redaction/fresh-noecho.ts
|
|
6827
|
+
function embedsFreshNoEchoValue(text, secrets) {
|
|
6828
|
+
const fresh = freshNoEchoValuesOf.get(secrets);
|
|
6829
|
+
if (fresh === void 0) return false;
|
|
6830
|
+
for (const value of fresh) if (isMaskOnlyPlaintext(secrets, value) && text.includes(value)) return true;
|
|
6831
|
+
return false;
|
|
6832
|
+
}
|
|
6833
|
+
function carriesFreshNoEchoValue(value, secrets) {
|
|
6834
|
+
const isFresh = freshNoEchoLeafTest(secrets);
|
|
6835
|
+
if (isFresh === void 0) return false;
|
|
6836
|
+
const seen = /* @__PURE__ */ new Set();
|
|
6837
|
+
const walk = (node) => {
|
|
6838
|
+
if (typeof node === "string") return isFresh(node);
|
|
6839
|
+
if (node === null || typeof node !== "object") return false;
|
|
6840
|
+
if (seen.has(node)) return false;
|
|
6841
|
+
seen.add(node);
|
|
6842
|
+
if (Array.isArray(node)) return node.some((item) => walk(item));
|
|
6843
|
+
return Object.values(node).some((child) => walk(child));
|
|
6844
|
+
};
|
|
6845
|
+
return walk(value);
|
|
6846
|
+
}
|
|
6847
|
+
function freshNoEchoLeafPositions(value, secrets) {
|
|
6848
|
+
const isFresh = freshNoEchoLeafTest(secrets);
|
|
6849
|
+
if (isFresh === void 0) return [];
|
|
6850
|
+
const leaves = [];
|
|
6851
|
+
const ancestors = /* @__PURE__ */ new Set();
|
|
6852
|
+
const walk = (node, path) => {
|
|
6853
|
+
if (typeof node === "string") {
|
|
6854
|
+
if (isFresh(node)) leaves.push({
|
|
6855
|
+
path,
|
|
6856
|
+
plaintext: node
|
|
6857
|
+
});
|
|
6858
|
+
return;
|
|
6859
|
+
}
|
|
6860
|
+
if (node === null || typeof node !== "object") return;
|
|
6861
|
+
if (ancestors.has(node)) return;
|
|
6862
|
+
ancestors.add(node);
|
|
6863
|
+
if (Array.isArray(node)) node.forEach((item, index) => walk(item, [...path, index]));
|
|
6864
|
+
else for (const [key, child] of Object.entries(node)) walk(child, [...path, key]);
|
|
6865
|
+
ancestors.delete(node);
|
|
6866
|
+
};
|
|
6867
|
+
walk(value, []);
|
|
6868
|
+
return leaves;
|
|
6869
|
+
}
|
|
6870
|
+
function freshNoEchoLeafTest(secrets) {
|
|
6871
|
+
const fresh = freshNoEchoValuesOf.get(secrets);
|
|
6872
|
+
if (fresh === void 0 || fresh.size === 0) return void 0;
|
|
6873
|
+
const needles = containmentNeedlesOf(secrets).filter((needle) => fresh.has(needle));
|
|
6874
|
+
return (leaf) => fresh.has(leaf) && isMaskOnlyPlaintext(secrets, leaf) || leaf !== "***" && embedsNeedleOutsideReferences(leaf, needles, secrets);
|
|
6875
|
+
}
|
|
6876
|
+
function containmentNeedlesOf(secrets) {
|
|
6877
|
+
const values = containmentValuesOf.get(secrets);
|
|
6878
|
+
if (values === void 0 || values.size === 0) return [];
|
|
6879
|
+
const needles = [];
|
|
6880
|
+
for (const value of values) if (value.length >= 4 && isMaskOnlyPlaintext(secrets, value)) needles.push(value);
|
|
6881
|
+
return needles;
|
|
6882
|
+
}
|
|
6883
|
+
function isStrictlyInsideASpan(spans, start, end) {
|
|
6884
|
+
return spans.some((span) => span.start <= start && end <= span.end && (span.start !== start || span.end !== end));
|
|
6885
|
+
}
|
|
6886
|
+
function embedsNeedleOutsideReferences(leaf, needles, secrets) {
|
|
6887
|
+
let spans;
|
|
6888
|
+
for (const needle of needles) for (let at = leaf.indexOf(needle); at >= 0; at = leaf.indexOf(needle, at + 1)) {
|
|
6889
|
+
spans ??= isDynamicReferenceString(leaf) ? resolvableReferenceSpans(leaf, new Set(secrets.values())) : [];
|
|
6890
|
+
if (!isStrictlyInsideASpan(spans, at, at + needle.length)) return true;
|
|
6891
|
+
}
|
|
6892
|
+
return false;
|
|
6893
|
+
}
|
|
6894
|
+
function flattenEmbeddedNoEchoLeaves(value, secrets) {
|
|
6895
|
+
const needles = containmentNeedlesOf(secrets);
|
|
6896
|
+
if (needles.length === 0) return value;
|
|
6897
|
+
const flattens = (leaf) => leaf !== "***" && embedsNeedleOutsideReferences(leaf, needles, secrets);
|
|
6898
|
+
const walk = (node) => {
|
|
6899
|
+
if (typeof node === "string") return flattens(node) ? "***" : node;
|
|
6900
|
+
if (node === null || typeof node !== "object") return node;
|
|
6901
|
+
if (Array.isArray(node)) {
|
|
6902
|
+
let changed = false;
|
|
6903
|
+
const out = node.map((item) => {
|
|
6904
|
+
const next = walk(item);
|
|
6905
|
+
if (next !== item) changed = true;
|
|
6906
|
+
return next;
|
|
6907
|
+
});
|
|
6908
|
+
return changed ? out : node;
|
|
6909
|
+
}
|
|
6910
|
+
if (isOrdinaryDate(node)) {
|
|
6911
|
+
const persisted = node.toJSON();
|
|
6912
|
+
return typeof persisted === "string" && flattens(persisted) ? "***" : node;
|
|
6913
|
+
}
|
|
6914
|
+
let out;
|
|
6915
|
+
for (const [key, child] of Object.entries(node)) {
|
|
6916
|
+
const next = walk(child);
|
|
6917
|
+
if (next === child) continue;
|
|
6918
|
+
out ??= Object.assign(Object.create(null), node);
|
|
6919
|
+
out[key] = next;
|
|
6920
|
+
}
|
|
6921
|
+
return out ?? node;
|
|
6922
|
+
};
|
|
6923
|
+
return walk(value);
|
|
6924
|
+
}
|
|
6925
|
+
function substringNeedlesOf(secrets) {
|
|
6926
|
+
const needles = [];
|
|
6927
|
+
for (const plaintext of secrets.keys()) if (!isMaskOnlyPlaintext(secrets, plaintext)) needles.push(plaintext);
|
|
6928
|
+
return needles;
|
|
6929
|
+
}
|
|
6930
|
+
function recordedExpressionsOf(secrets) {
|
|
6931
|
+
const expressions = /* @__PURE__ */ new Set();
|
|
6932
|
+
for (const [plaintext, expression] of secrets) if (!isMaskOnlyPlaintext(secrets, plaintext)) expressions.add(expression);
|
|
6933
|
+
return expressions;
|
|
6934
|
+
}
|
|
6935
|
+
const recoverableMaskedOutputs = /* @__PURE__ */ new Map();
|
|
6936
|
+
function maskedOutputKey(identity, stackName, region, outputKey) {
|
|
6937
|
+
return `${identity}\u0000${stackName}\u0000${region}\u0000${outputKey}`;
|
|
6938
|
+
}
|
|
6939
|
+
function recordRecoverableMaskedOutput(identity, stackName, region, outputKey, plaintext) {
|
|
6940
|
+
recoverableMaskedOutputs.set(maskedOutputKey(identity, stackName, region, outputKey), plaintext);
|
|
6941
|
+
}
|
|
6942
|
+
function recoverMaskedOutput(identity, stackName, region, outputKey) {
|
|
6943
|
+
return recoverableMaskedOutputs.get(maskedOutputKey(identity, stackName, region, outputKey));
|
|
6944
|
+
}
|
|
6945
|
+
|
|
6946
|
+
//#endregion
|
|
6947
|
+
//#region src/deployment/secret-redaction/nested-stack.ts
|
|
6948
|
+
const NESTED_STACK_RESOURCE_TYPE$4 = "AWS::CloudFormation::Stack";
|
|
6949
|
+
const nestedStackParameterExpressions = /* @__PURE__ */ new WeakMap();
|
|
6950
|
+
const UNFRAMED_SPELLING = Symbol("cdkd.nested-parameter.unframed-spelling");
|
|
6951
|
+
function recordNestedStackParameterExpressions(secrets, resourceType, resolvedProperties, sourceProperties, rules = TEMPLATE_DERIVED_RULES) {
|
|
6952
|
+
if (resourceType !== NESTED_STACK_RESOURCE_TYPE$4) return;
|
|
6953
|
+
if (secrets.size === 0) return;
|
|
6954
|
+
if (!isPlainObject$4(resolvedProperties) || !isPlainObject$4(sourceProperties)) return;
|
|
6955
|
+
if (!Object.hasOwn(resolvedProperties, "Parameters")) return;
|
|
6956
|
+
if (!Object.hasOwn(sourceProperties, "Parameters")) return;
|
|
6957
|
+
const resolvedParameters = resolvedProperties["Parameters"];
|
|
6958
|
+
const sourceParameters = sourceProperties["Parameters"];
|
|
6959
|
+
if (!isPlainObject$4(resolvedParameters) || !isPlainObject$4(sourceParameters)) return;
|
|
6960
|
+
const positioned = redactSecretsForState(markSameGenerationBag({ ...resolvedParameters }), secrets, sourceParameters, rules);
|
|
6961
|
+
let table = nestedStackParameterExpressions.get(secrets);
|
|
6962
|
+
for (const [name, resolvedValue] of Object.entries(resolvedParameters)) {
|
|
6963
|
+
if (typeof resolvedValue !== "string" || !secrets.has(resolvedValue)) continue;
|
|
6964
|
+
const expression = positioned[name];
|
|
6965
|
+
if (typeof expression !== "string") continue;
|
|
6966
|
+
if (!isSingleDynamicReferenceToken(expression)) continue;
|
|
6967
|
+
const sourceLeaf = sourceParameters[name];
|
|
6968
|
+
if (typeof sourceLeaf === "string" && expression !== sourceLeaf) continue;
|
|
6969
|
+
if (expression === resolvedValue) continue;
|
|
6970
|
+
const seenResolvingTo = plaintextIndexOf(secrets).get(expression);
|
|
6971
|
+
if (seenResolvingTo !== void 0 && seenResolvingTo !== resolvedValue) continue;
|
|
6972
|
+
if (typeof sourceLeaf === "string" && resolvedPlaintextOf(secrets, expression) !== resolvedValue) continue;
|
|
6973
|
+
if (table === void 0) {
|
|
6974
|
+
table = /* @__PURE__ */ new Map();
|
|
6975
|
+
nestedStackParameterExpressions.set(secrets, table);
|
|
6976
|
+
}
|
|
6977
|
+
storeAssociation(table, name, expression, resolvedValue);
|
|
6978
|
+
}
|
|
6979
|
+
const framesByValue = /* @__PURE__ */ new Map();
|
|
6980
|
+
const tokensOf = /* @__PURE__ */ new Map();
|
|
6981
|
+
const frameSpellings = /* @__PURE__ */ new Map();
|
|
6982
|
+
const frameSpellingOf = (name) => {
|
|
6983
|
+
if (!frameSpellings.has(name)) frameSpellings.set(name, computeFrameSpelling(name));
|
|
6984
|
+
return frameSpellings.get(name);
|
|
6985
|
+
};
|
|
6986
|
+
const computeFrameSpelling = (name) => {
|
|
6987
|
+
const resolvedValue = resolvedParameters[name];
|
|
6988
|
+
if (typeof resolvedValue !== "string") return void 0;
|
|
6989
|
+
const sourceLeaf = sourceParameters[name];
|
|
6990
|
+
if (typeof sourceLeaf === "string") return sourceLeaf;
|
|
6991
|
+
if (!isPlainObject$4(sourceLeaf)) return void 0;
|
|
6992
|
+
const written = positioned[name];
|
|
6993
|
+
if (typeof written !== "string") return void 0;
|
|
6994
|
+
const rendered = intrinsicSkeletonSegments(sourceLeaf)?.map((s) => s === UNKNOWN_PART ? "\0" : s).join("");
|
|
6995
|
+
const spans = rendered === void 0 ? [] : dynamicReferenceSpans(rendered);
|
|
6996
|
+
if (rendered !== void 0 && spans.length === 1) {
|
|
6997
|
+
const [span] = spans;
|
|
6998
|
+
const ownToken = rendered.slice(span.start, span.end);
|
|
6999
|
+
if (written !== resolvedValue && SPELLED_SECRET_REFERENCE_PREFIXES.some((prefix) => ownToken.startsWith(prefix))) return written;
|
|
7000
|
+
}
|
|
7001
|
+
const substituted = substitutedSpellingOf(secrets, sourceLeaf, resolvedValue);
|
|
7002
|
+
if (substituted === void 0) return void 0;
|
|
7003
|
+
return written === resolvedValue || written === substituted ? substituted : void 0;
|
|
7004
|
+
};
|
|
7005
|
+
const certifiedSpellingOf = (name) => {
|
|
7006
|
+
const sourceLeaf = sourceParameters[name];
|
|
7007
|
+
if (typeof sourceLeaf === "string") return positioned[name] === sourceLeaf ? sourceLeaf : void 0;
|
|
7008
|
+
return frameSpellingOf(name);
|
|
7009
|
+
};
|
|
7010
|
+
const unwrittenValues = /* @__PURE__ */ new Set();
|
|
7011
|
+
for (const [name, resolvedValue] of Object.entries(resolvedParameters)) {
|
|
7012
|
+
if (typeof resolvedValue !== "string") continue;
|
|
7013
|
+
const spelling = frameSpellingOf(name);
|
|
7014
|
+
const frame = spelling === void 0 ? void 0 : singleSpanFrame(resolvedValue, spelling);
|
|
7015
|
+
const frames = framesByValue.get(resolvedValue) ?? /* @__PURE__ */ new Set();
|
|
7016
|
+
const unframed = frame === void 0 || resolvedPlaintextOf(secrets, frame.token) !== frame.middle;
|
|
7017
|
+
frames.add(unframed ? UNFRAMED_SPELLING : `${frame.prefix.length}:${frame.prefix}${frame.suffix}`);
|
|
7018
|
+
framesByValue.set(resolvedValue, frames);
|
|
7019
|
+
if (!unframed) {
|
|
7020
|
+
const tokens = tokensOf.get(resolvedValue) ?? /* @__PURE__ */ new Set();
|
|
7021
|
+
tokens.add(frame.token);
|
|
7022
|
+
tokensOf.set(resolvedValue, tokens);
|
|
7023
|
+
if (typeof sourceParameters[name] !== "string" && positioned[name] !== spelling) unwrittenValues.add(resolvedValue);
|
|
7024
|
+
}
|
|
7025
|
+
}
|
|
7026
|
+
for (const value of unwrittenValues) if (tokensOf.get(value)?.size !== 1) framesByValue.get(value)?.add(UNFRAMED_SPELLING);
|
|
7027
|
+
const rowWithoutParameters = {};
|
|
7028
|
+
for (const [key, value] of Object.entries(resolvedProperties)) if (key !== "Parameters") rowWithoutParameters[key] = value;
|
|
7029
|
+
const outsideLeaves = wholeStringLeavesOf(rowWithoutParameters);
|
|
7030
|
+
const framed = /* @__PURE__ */ new Map();
|
|
7031
|
+
const framedByName = [];
|
|
7032
|
+
for (const [name, resolvedValue] of Object.entries(resolvedParameters)) {
|
|
7033
|
+
if (typeof resolvedValue !== "string") continue;
|
|
7034
|
+
const spelling = certifiedSpellingOf(name);
|
|
7035
|
+
if (spelling === void 0) continue;
|
|
7036
|
+
if (redactSecretsForState(resolvedValue, secrets) !== resolvedValue) continue;
|
|
7037
|
+
const frame = singleSpanFrame(resolvedValue, spelling);
|
|
7038
|
+
if (frame === void 0 || resolvedPlaintextOf(secrets, frame.token) !== frame.middle) continue;
|
|
7039
|
+
if (framesByValue.get(resolvedValue)?.size !== 1) continue;
|
|
7040
|
+
const isNeedle = resolvedValue.length >= 4;
|
|
7041
|
+
const rewrites = (leaf) => leaf === resolvedValue || isNeedle && leaf.includes(resolvedValue);
|
|
7042
|
+
let embedded = false;
|
|
7043
|
+
for (const leaf of outsideLeaves) if (rewrites(leaf)) {
|
|
7044
|
+
embedded = true;
|
|
7045
|
+
break;
|
|
7046
|
+
}
|
|
7047
|
+
for (const other of Object.values(resolvedParameters)) {
|
|
7048
|
+
if (embedded) break;
|
|
7049
|
+
if (typeof other === "string") {
|
|
7050
|
+
if (other !== resolvedValue && rewrites(other)) embedded = true;
|
|
7051
|
+
continue;
|
|
7052
|
+
}
|
|
7053
|
+
for (const leaf of wholeStringLeavesOf(other)) if (rewrites(leaf)) {
|
|
7054
|
+
embedded = true;
|
|
7055
|
+
break;
|
|
7056
|
+
}
|
|
7057
|
+
}
|
|
7058
|
+
if (embedded) continue;
|
|
7059
|
+
framedByName.push([
|
|
7060
|
+
name,
|
|
7061
|
+
spelling,
|
|
7062
|
+
resolvedValue
|
|
7063
|
+
]);
|
|
7064
|
+
if (secrets.get(frame.middle) !== frame.token && tokensOf.get(resolvedValue)?.size !== 1) continue;
|
|
7065
|
+
framed.set(resolvedValue, spelling);
|
|
7066
|
+
}
|
|
7067
|
+
for (const [plaintext, expression] of framed) secrets.set(plaintext, expression);
|
|
7068
|
+
for (const [name, expression, plaintext] of framedByName) {
|
|
7069
|
+
if (table === void 0) {
|
|
7070
|
+
table = /* @__PURE__ */ new Map();
|
|
7071
|
+
nestedStackParameterExpressions.set(secrets, table);
|
|
7072
|
+
}
|
|
7073
|
+
storeAssociation(table, name, expression, plaintext);
|
|
7074
|
+
}
|
|
7075
|
+
}
|
|
7076
|
+
function inheritNestedStackParameterAssociations(childSecrets, parentSecrets) {
|
|
7077
|
+
const table = nestedStackParameterExpressions.get(parentSecrets);
|
|
7078
|
+
if (table === void 0 || table.size === 0) return;
|
|
7079
|
+
let associations = crossStackAssociations.get(childSecrets);
|
|
7080
|
+
for (const [name, association] of table) {
|
|
7081
|
+
const key = crossStackSourceKey({ Ref: name });
|
|
7082
|
+
if (key === void 0) continue;
|
|
7083
|
+
if (associations === void 0) {
|
|
7084
|
+
associations = /* @__PURE__ */ new Map();
|
|
7085
|
+
crossStackAssociations.set(childSecrets, associations);
|
|
7086
|
+
}
|
|
7087
|
+
if (typeof association === "symbol") {
|
|
7088
|
+
associations.set(key, association);
|
|
7089
|
+
continue;
|
|
7090
|
+
}
|
|
7091
|
+
storeAssociation(associations, key, association.expression, association.plaintext);
|
|
7092
|
+
}
|
|
7093
|
+
}
|
|
7094
|
+
function inheritedParameterExpression(parentSecrets, parameterName, resolvedValue) {
|
|
7095
|
+
const association = nestedStackParameterExpressions.get(parentSecrets)?.get(parameterName);
|
|
7096
|
+
if (association === void 0 || typeof association === "symbol") return void 0;
|
|
7097
|
+
if (Array.isArray(resolvedValue)) return certifiedListForLeaf(parentSecrets, association, resolvedValue);
|
|
7098
|
+
return certifiedExpressionForLeaf(parentSecrets, association, resolvedValue);
|
|
7099
|
+
}
|
|
7100
|
+
const inheritedParameterReads = /* @__PURE__ */ new WeakMap();
|
|
7101
|
+
const POISONED_PARAMETER_READS = Symbol("cdkd.inherited-parameter-reads.poisoned");
|
|
7102
|
+
function recordInheritedParameterRead(childSecrets, parentSecrets, parameterName) {
|
|
7103
|
+
const reads = inheritedParameterReads.get(childSecrets);
|
|
7104
|
+
if (reads === void 0) {
|
|
7105
|
+
inheritedParameterReads.set(childSecrets, {
|
|
7106
|
+
parent: parentSecrets,
|
|
7107
|
+
names: /* @__PURE__ */ new Set([parameterName])
|
|
7108
|
+
});
|
|
7109
|
+
return;
|
|
7110
|
+
}
|
|
7111
|
+
if (typeof reads === "symbol") return;
|
|
7112
|
+
if (reads.parent !== parentSecrets) {
|
|
7113
|
+
inheritedParameterReads.set(childSecrets, POISONED_PARAMETER_READS);
|
|
7114
|
+
return;
|
|
7115
|
+
}
|
|
7116
|
+
reads.names.add(parameterName);
|
|
7117
|
+
}
|
|
7118
|
+
function redactInheritedParameterValue(parentSecrets, parameterName, value) {
|
|
7119
|
+
return inheritedParameterExpression(parentSecrets, parameterName, value) ?? redactSecretsForState(value, parentSecrets);
|
|
7120
|
+
}
|
|
7121
|
+
function positionByInheritedParameter(bag, source, secrets) {
|
|
7122
|
+
const keys = Object.keys(source);
|
|
7123
|
+
if (keys.length !== 1 || keys[0] !== "Ref") return void 0;
|
|
7124
|
+
const name = source["Ref"];
|
|
7125
|
+
if (typeof name !== "string") return void 0;
|
|
7126
|
+
const reads = inheritedParameterReads.get(secrets);
|
|
7127
|
+
if (reads === void 0 || typeof reads === "symbol" || !reads.names.has(name)) return;
|
|
7128
|
+
if (typeof bag !== "string" && !Array.isArray(bag)) return void 0;
|
|
7129
|
+
if (carriesChildOnlyPlaintext(bag, secrets, reads.parent)) return void 0;
|
|
7130
|
+
const answer = redactInheritedParameterValue(reads.parent, name, bag);
|
|
7131
|
+
if (!deepEqualJsonValue(redactSecretsForState(answer, secrets), answer)) return void 0;
|
|
7132
|
+
return answer;
|
|
7133
|
+
}
|
|
7134
|
+
function carriesChildOnlyPlaintext(value, childSecrets, parentSecrets) {
|
|
7135
|
+
const parentNeedles = new Set(substringNeedlesOf(parentSecrets));
|
|
7136
|
+
const childNeedles = new Set(substringNeedlesOf(childSecrets));
|
|
7137
|
+
const childOnly = [...childSecrets.keys()].filter((plaintext) => plaintext !== "" && (!parentSecrets.has(plaintext) || childNeedles.has(plaintext) && !parentNeedles.has(plaintext)));
|
|
7138
|
+
for (const needle of parentNeedles) if (needle.length >= 4 && !childSecrets.has(needle)) childOnly.push(needle);
|
|
7139
|
+
if (childOnly.length === 0) return false;
|
|
7140
|
+
const visit = (node) => {
|
|
7141
|
+
if (typeof node === "string") return childOnly.some((plaintext) => node.includes(plaintext));
|
|
7142
|
+
if (Array.isArray(node)) return node.some(visit);
|
|
7143
|
+
if (node !== null && typeof node === "object") return Object.values(node).some(visit);
|
|
7144
|
+
return false;
|
|
7145
|
+
};
|
|
7146
|
+
return visit(value);
|
|
7147
|
+
}
|
|
7148
|
+
|
|
6825
7149
|
//#endregion
|
|
6826
7150
|
//#region src/deployment/secret-redaction/redact-path.ts
|
|
6827
7151
|
function redactByPath(bag, source, secrets, rules, secretExpressions, bagIsSameGeneration) {
|
|
@@ -6835,6 +7159,10 @@ function redactByPath(bag, source, secrets, rules, secretExpressions, bagIsSameG
|
|
|
6835
7159
|
}
|
|
6836
7160
|
return positionByEmbeddedSpan(bag, source, secrets, bagIsSameGeneration);
|
|
6837
7161
|
}
|
|
7162
|
+
if ((typeof bag === "string" || Array.isArray(bag)) && isPlainObject$4(source)) {
|
|
7163
|
+
const inherited = positionByInheritedParameter(bag, source, secrets);
|
|
7164
|
+
if (inherited !== void 0) return inherited;
|
|
7165
|
+
}
|
|
6838
7166
|
if (typeof bag === "string" && isPlainObject$4(source)) {
|
|
6839
7167
|
const certified = positionByCrossStackSource(bag, source, secrets);
|
|
6840
7168
|
if (certified !== void 0) return certified;
|
|
@@ -7189,127 +7517,6 @@ function deriveReadbackNeedles(bag, source, secrets, rules) {
|
|
|
7189
7517
|
};
|
|
7190
7518
|
}
|
|
7191
7519
|
|
|
7192
|
-
//#endregion
|
|
7193
|
-
//#region src/deployment/secret-redaction/fresh-noecho.ts
|
|
7194
|
-
function embedsFreshNoEchoValue(text, secrets) {
|
|
7195
|
-
const fresh = freshNoEchoValuesOf.get(secrets);
|
|
7196
|
-
if (fresh === void 0) return false;
|
|
7197
|
-
for (const value of fresh) if (isMaskOnlyPlaintext(secrets, value) && text.includes(value)) return true;
|
|
7198
|
-
return false;
|
|
7199
|
-
}
|
|
7200
|
-
function carriesFreshNoEchoValue(value, secrets) {
|
|
7201
|
-
const isFresh = freshNoEchoLeafTest(secrets);
|
|
7202
|
-
if (isFresh === void 0) return false;
|
|
7203
|
-
const seen = /* @__PURE__ */ new Set();
|
|
7204
|
-
const walk = (node) => {
|
|
7205
|
-
if (typeof node === "string") return isFresh(node);
|
|
7206
|
-
if (node === null || typeof node !== "object") return false;
|
|
7207
|
-
if (seen.has(node)) return false;
|
|
7208
|
-
seen.add(node);
|
|
7209
|
-
if (Array.isArray(node)) return node.some((item) => walk(item));
|
|
7210
|
-
return Object.values(node).some((child) => walk(child));
|
|
7211
|
-
};
|
|
7212
|
-
return walk(value);
|
|
7213
|
-
}
|
|
7214
|
-
function freshNoEchoLeafPositions(value, secrets) {
|
|
7215
|
-
const isFresh = freshNoEchoLeafTest(secrets);
|
|
7216
|
-
if (isFresh === void 0) return [];
|
|
7217
|
-
const leaves = [];
|
|
7218
|
-
const ancestors = /* @__PURE__ */ new Set();
|
|
7219
|
-
const walk = (node, path) => {
|
|
7220
|
-
if (typeof node === "string") {
|
|
7221
|
-
if (isFresh(node)) leaves.push({
|
|
7222
|
-
path,
|
|
7223
|
-
plaintext: node
|
|
7224
|
-
});
|
|
7225
|
-
return;
|
|
7226
|
-
}
|
|
7227
|
-
if (node === null || typeof node !== "object") return;
|
|
7228
|
-
if (ancestors.has(node)) return;
|
|
7229
|
-
ancestors.add(node);
|
|
7230
|
-
if (Array.isArray(node)) node.forEach((item, index) => walk(item, [...path, index]));
|
|
7231
|
-
else for (const [key, child] of Object.entries(node)) walk(child, [...path, key]);
|
|
7232
|
-
ancestors.delete(node);
|
|
7233
|
-
};
|
|
7234
|
-
walk(value, []);
|
|
7235
|
-
return leaves;
|
|
7236
|
-
}
|
|
7237
|
-
function freshNoEchoLeafTest(secrets) {
|
|
7238
|
-
const fresh = freshNoEchoValuesOf.get(secrets);
|
|
7239
|
-
if (fresh === void 0 || fresh.size === 0) return void 0;
|
|
7240
|
-
const needles = containmentNeedlesOf(secrets).filter((needle) => fresh.has(needle));
|
|
7241
|
-
return (leaf) => fresh.has(leaf) && isMaskOnlyPlaintext(secrets, leaf) || leaf !== "***" && embedsNeedleOutsideReferences(leaf, needles, secrets);
|
|
7242
|
-
}
|
|
7243
|
-
function containmentNeedlesOf(secrets) {
|
|
7244
|
-
const values = containmentValuesOf.get(secrets);
|
|
7245
|
-
if (values === void 0 || values.size === 0) return [];
|
|
7246
|
-
const needles = [];
|
|
7247
|
-
for (const value of values) if (value.length >= 4 && isMaskOnlyPlaintext(secrets, value)) needles.push(value);
|
|
7248
|
-
return needles;
|
|
7249
|
-
}
|
|
7250
|
-
function isStrictlyInsideASpan(spans, start, end) {
|
|
7251
|
-
return spans.some((span) => span.start <= start && end <= span.end && (span.start !== start || span.end !== end));
|
|
7252
|
-
}
|
|
7253
|
-
function embedsNeedleOutsideReferences(leaf, needles, secrets) {
|
|
7254
|
-
let spans;
|
|
7255
|
-
for (const needle of needles) for (let at = leaf.indexOf(needle); at >= 0; at = leaf.indexOf(needle, at + 1)) {
|
|
7256
|
-
spans ??= isDynamicReferenceString(leaf) ? resolvableReferenceSpans(leaf, new Set(secrets.values())) : [];
|
|
7257
|
-
if (!isStrictlyInsideASpan(spans, at, at + needle.length)) return true;
|
|
7258
|
-
}
|
|
7259
|
-
return false;
|
|
7260
|
-
}
|
|
7261
|
-
function flattenEmbeddedNoEchoLeaves(value, secrets) {
|
|
7262
|
-
const needles = containmentNeedlesOf(secrets);
|
|
7263
|
-
if (needles.length === 0) return value;
|
|
7264
|
-
const flattens = (leaf) => leaf !== "***" && embedsNeedleOutsideReferences(leaf, needles, secrets);
|
|
7265
|
-
const walk = (node) => {
|
|
7266
|
-
if (typeof node === "string") return flattens(node) ? "***" : node;
|
|
7267
|
-
if (node === null || typeof node !== "object") return node;
|
|
7268
|
-
if (Array.isArray(node)) {
|
|
7269
|
-
let changed = false;
|
|
7270
|
-
const out = node.map((item) => {
|
|
7271
|
-
const next = walk(item);
|
|
7272
|
-
if (next !== item) changed = true;
|
|
7273
|
-
return next;
|
|
7274
|
-
});
|
|
7275
|
-
return changed ? out : node;
|
|
7276
|
-
}
|
|
7277
|
-
if (isOrdinaryDate(node)) {
|
|
7278
|
-
const persisted = node.toJSON();
|
|
7279
|
-
return typeof persisted === "string" && flattens(persisted) ? "***" : node;
|
|
7280
|
-
}
|
|
7281
|
-
let out;
|
|
7282
|
-
for (const [key, child] of Object.entries(node)) {
|
|
7283
|
-
const next = walk(child);
|
|
7284
|
-
if (next === child) continue;
|
|
7285
|
-
out ??= Object.assign(Object.create(null), node);
|
|
7286
|
-
out[key] = next;
|
|
7287
|
-
}
|
|
7288
|
-
return out ?? node;
|
|
7289
|
-
};
|
|
7290
|
-
return walk(value);
|
|
7291
|
-
}
|
|
7292
|
-
function substringNeedlesOf(secrets) {
|
|
7293
|
-
const needles = [];
|
|
7294
|
-
for (const plaintext of secrets.keys()) if (!isMaskOnlyPlaintext(secrets, plaintext)) needles.push(plaintext);
|
|
7295
|
-
return needles;
|
|
7296
|
-
}
|
|
7297
|
-
function recordedExpressionsOf(secrets) {
|
|
7298
|
-
const expressions = /* @__PURE__ */ new Set();
|
|
7299
|
-
for (const [plaintext, expression] of secrets) if (!isMaskOnlyPlaintext(secrets, plaintext)) expressions.add(expression);
|
|
7300
|
-
return expressions;
|
|
7301
|
-
}
|
|
7302
|
-
const recoverableMaskedOutputs = /* @__PURE__ */ new Map();
|
|
7303
|
-
function maskedOutputKey(identity, stackName, region, outputKey) {
|
|
7304
|
-
return `${identity}\u0000${stackName}\u0000${region}\u0000${outputKey}`;
|
|
7305
|
-
}
|
|
7306
|
-
function recordRecoverableMaskedOutput(identity, stackName, region, outputKey, plaintext) {
|
|
7307
|
-
recoverableMaskedOutputs.set(maskedOutputKey(identity, stackName, region, outputKey), plaintext);
|
|
7308
|
-
}
|
|
7309
|
-
function recoverMaskedOutput(identity, stackName, region, outputKey) {
|
|
7310
|
-
return recoverableMaskedOutputs.get(maskedOutputKey(identity, stackName, region, outputKey));
|
|
7311
|
-
}
|
|
7312
|
-
|
|
7313
7520
|
//#endregion
|
|
7314
7521
|
//#region src/deployment/secret-redaction/redact-state.ts
|
|
7315
7522
|
function redactSecretsForState(bag, secrets, source, rules = TEMPLATE_DERIVED_RULES) {
|
|
@@ -8023,161 +8230,6 @@ function hasMaskableValues(secrets) {
|
|
|
8023
8230
|
return logOnly !== void 0 && logOnly.size > 0;
|
|
8024
8231
|
}
|
|
8025
8232
|
|
|
8026
|
-
//#endregion
|
|
8027
|
-
//#region src/deployment/secret-redaction/nested-stack.ts
|
|
8028
|
-
const NESTED_STACK_RESOURCE_TYPE$4 = "AWS::CloudFormation::Stack";
|
|
8029
|
-
const nestedStackParameterExpressions = /* @__PURE__ */ new WeakMap();
|
|
8030
|
-
const UNFRAMED_SPELLING = Symbol("cdkd.nested-parameter.unframed-spelling");
|
|
8031
|
-
function recordNestedStackParameterExpressions(secrets, resourceType, resolvedProperties, sourceProperties, rules = TEMPLATE_DERIVED_RULES) {
|
|
8032
|
-
if (resourceType !== NESTED_STACK_RESOURCE_TYPE$4) return;
|
|
8033
|
-
if (secrets.size === 0) return;
|
|
8034
|
-
if (!isPlainObject$4(resolvedProperties) || !isPlainObject$4(sourceProperties)) return;
|
|
8035
|
-
if (!Object.hasOwn(resolvedProperties, "Parameters")) return;
|
|
8036
|
-
if (!Object.hasOwn(sourceProperties, "Parameters")) return;
|
|
8037
|
-
const resolvedParameters = resolvedProperties["Parameters"];
|
|
8038
|
-
const sourceParameters = sourceProperties["Parameters"];
|
|
8039
|
-
if (!isPlainObject$4(resolvedParameters) || !isPlainObject$4(sourceParameters)) return;
|
|
8040
|
-
const positioned = redactSecretsForState(markSameGenerationBag({ ...resolvedParameters }), secrets, sourceParameters, rules);
|
|
8041
|
-
let table = nestedStackParameterExpressions.get(secrets);
|
|
8042
|
-
for (const [name, resolvedValue] of Object.entries(resolvedParameters)) {
|
|
8043
|
-
if (typeof resolvedValue !== "string" || !secrets.has(resolvedValue)) continue;
|
|
8044
|
-
const expression = positioned[name];
|
|
8045
|
-
if (typeof expression !== "string") continue;
|
|
8046
|
-
if (!isSingleDynamicReferenceToken(expression)) continue;
|
|
8047
|
-
const sourceLeaf = sourceParameters[name];
|
|
8048
|
-
if (typeof sourceLeaf === "string" && expression !== sourceLeaf) continue;
|
|
8049
|
-
if (expression === resolvedValue) continue;
|
|
8050
|
-
const seenResolvingTo = plaintextIndexOf(secrets).get(expression);
|
|
8051
|
-
if (seenResolvingTo !== void 0 && seenResolvingTo !== resolvedValue) continue;
|
|
8052
|
-
if (typeof sourceLeaf === "string" && resolvedPlaintextOf(secrets, expression) !== resolvedValue) continue;
|
|
8053
|
-
if (table === void 0) {
|
|
8054
|
-
table = /* @__PURE__ */ new Map();
|
|
8055
|
-
nestedStackParameterExpressions.set(secrets, table);
|
|
8056
|
-
}
|
|
8057
|
-
storeAssociation(table, name, expression, resolvedValue);
|
|
8058
|
-
}
|
|
8059
|
-
const framesByValue = /* @__PURE__ */ new Map();
|
|
8060
|
-
const tokensOf = /* @__PURE__ */ new Map();
|
|
8061
|
-
const frameSpellings = /* @__PURE__ */ new Map();
|
|
8062
|
-
const frameSpellingOf = (name) => {
|
|
8063
|
-
if (!frameSpellings.has(name)) frameSpellings.set(name, computeFrameSpelling(name));
|
|
8064
|
-
return frameSpellings.get(name);
|
|
8065
|
-
};
|
|
8066
|
-
const computeFrameSpelling = (name) => {
|
|
8067
|
-
const resolvedValue = resolvedParameters[name];
|
|
8068
|
-
if (typeof resolvedValue !== "string") return void 0;
|
|
8069
|
-
const sourceLeaf = sourceParameters[name];
|
|
8070
|
-
if (typeof sourceLeaf === "string") return sourceLeaf;
|
|
8071
|
-
if (!isPlainObject$4(sourceLeaf)) return void 0;
|
|
8072
|
-
const written = positioned[name];
|
|
8073
|
-
if (typeof written !== "string") return void 0;
|
|
8074
|
-
const rendered = intrinsicSkeletonSegments(sourceLeaf)?.map((s) => s === UNKNOWN_PART ? "\0" : s).join("");
|
|
8075
|
-
const spans = rendered === void 0 ? [] : dynamicReferenceSpans(rendered);
|
|
8076
|
-
if (rendered !== void 0 && spans.length === 1) {
|
|
8077
|
-
const [span] = spans;
|
|
8078
|
-
const ownToken = rendered.slice(span.start, span.end);
|
|
8079
|
-
if (written !== resolvedValue && SPELLED_SECRET_REFERENCE_PREFIXES.some((prefix) => ownToken.startsWith(prefix))) return written;
|
|
8080
|
-
}
|
|
8081
|
-
const substituted = substitutedSpellingOf(secrets, sourceLeaf, resolvedValue);
|
|
8082
|
-
if (substituted === void 0) return void 0;
|
|
8083
|
-
return written === resolvedValue || written === substituted ? substituted : void 0;
|
|
8084
|
-
};
|
|
8085
|
-
const certifiedSpellingOf = (name) => {
|
|
8086
|
-
const sourceLeaf = sourceParameters[name];
|
|
8087
|
-
if (typeof sourceLeaf === "string") return positioned[name] === sourceLeaf ? sourceLeaf : void 0;
|
|
8088
|
-
return frameSpellingOf(name);
|
|
8089
|
-
};
|
|
8090
|
-
const unwrittenValues = /* @__PURE__ */ new Set();
|
|
8091
|
-
for (const [name, resolvedValue] of Object.entries(resolvedParameters)) {
|
|
8092
|
-
if (typeof resolvedValue !== "string") continue;
|
|
8093
|
-
const spelling = frameSpellingOf(name);
|
|
8094
|
-
const frame = spelling === void 0 ? void 0 : singleSpanFrame(resolvedValue, spelling);
|
|
8095
|
-
const frames = framesByValue.get(resolvedValue) ?? /* @__PURE__ */ new Set();
|
|
8096
|
-
const unframed = frame === void 0 || resolvedPlaintextOf(secrets, frame.token) !== frame.middle;
|
|
8097
|
-
frames.add(unframed ? UNFRAMED_SPELLING : `${frame.prefix.length}:${frame.prefix}${frame.suffix}`);
|
|
8098
|
-
framesByValue.set(resolvedValue, frames);
|
|
8099
|
-
if (!unframed) {
|
|
8100
|
-
const tokens = tokensOf.get(resolvedValue) ?? /* @__PURE__ */ new Set();
|
|
8101
|
-
tokens.add(frame.token);
|
|
8102
|
-
tokensOf.set(resolvedValue, tokens);
|
|
8103
|
-
if (typeof sourceParameters[name] !== "string" && positioned[name] !== spelling) unwrittenValues.add(resolvedValue);
|
|
8104
|
-
}
|
|
8105
|
-
}
|
|
8106
|
-
for (const value of unwrittenValues) if (tokensOf.get(value)?.size !== 1) framesByValue.get(value)?.add(UNFRAMED_SPELLING);
|
|
8107
|
-
const rowWithoutParameters = {};
|
|
8108
|
-
for (const [key, value] of Object.entries(resolvedProperties)) if (key !== "Parameters") rowWithoutParameters[key] = value;
|
|
8109
|
-
const outsideLeaves = wholeStringLeavesOf(rowWithoutParameters);
|
|
8110
|
-
const framed = /* @__PURE__ */ new Map();
|
|
8111
|
-
const framedByName = [];
|
|
8112
|
-
for (const [name, resolvedValue] of Object.entries(resolvedParameters)) {
|
|
8113
|
-
if (typeof resolvedValue !== "string") continue;
|
|
8114
|
-
const spelling = certifiedSpellingOf(name);
|
|
8115
|
-
if (spelling === void 0) continue;
|
|
8116
|
-
if (redactSecretsForState(resolvedValue, secrets) !== resolvedValue) continue;
|
|
8117
|
-
const frame = singleSpanFrame(resolvedValue, spelling);
|
|
8118
|
-
if (frame === void 0 || resolvedPlaintextOf(secrets, frame.token) !== frame.middle) continue;
|
|
8119
|
-
if (framesByValue.get(resolvedValue)?.size !== 1) continue;
|
|
8120
|
-
const isNeedle = resolvedValue.length >= 4;
|
|
8121
|
-
const rewrites = (leaf) => leaf === resolvedValue || isNeedle && leaf.includes(resolvedValue);
|
|
8122
|
-
let embedded = false;
|
|
8123
|
-
for (const leaf of outsideLeaves) if (rewrites(leaf)) {
|
|
8124
|
-
embedded = true;
|
|
8125
|
-
break;
|
|
8126
|
-
}
|
|
8127
|
-
for (const other of Object.values(resolvedParameters)) {
|
|
8128
|
-
if (embedded) break;
|
|
8129
|
-
if (typeof other === "string") {
|
|
8130
|
-
if (other !== resolvedValue && rewrites(other)) embedded = true;
|
|
8131
|
-
continue;
|
|
8132
|
-
}
|
|
8133
|
-
for (const leaf of wholeStringLeavesOf(other)) if (rewrites(leaf)) {
|
|
8134
|
-
embedded = true;
|
|
8135
|
-
break;
|
|
8136
|
-
}
|
|
8137
|
-
}
|
|
8138
|
-
if (embedded) continue;
|
|
8139
|
-
framedByName.push([
|
|
8140
|
-
name,
|
|
8141
|
-
spelling,
|
|
8142
|
-
resolvedValue
|
|
8143
|
-
]);
|
|
8144
|
-
if (secrets.get(frame.middle) !== frame.token && tokensOf.get(resolvedValue)?.size !== 1) continue;
|
|
8145
|
-
framed.set(resolvedValue, spelling);
|
|
8146
|
-
}
|
|
8147
|
-
for (const [plaintext, expression] of framed) secrets.set(plaintext, expression);
|
|
8148
|
-
for (const [name, expression, plaintext] of framedByName) {
|
|
8149
|
-
if (table === void 0) {
|
|
8150
|
-
table = /* @__PURE__ */ new Map();
|
|
8151
|
-
nestedStackParameterExpressions.set(secrets, table);
|
|
8152
|
-
}
|
|
8153
|
-
storeAssociation(table, name, expression, plaintext);
|
|
8154
|
-
}
|
|
8155
|
-
}
|
|
8156
|
-
function inheritNestedStackParameterAssociations(childSecrets, parentSecrets) {
|
|
8157
|
-
const table = nestedStackParameterExpressions.get(parentSecrets);
|
|
8158
|
-
if (table === void 0 || table.size === 0) return;
|
|
8159
|
-
let associations = crossStackAssociations.get(childSecrets);
|
|
8160
|
-
for (const [name, association] of table) {
|
|
8161
|
-
const key = crossStackSourceKey({ Ref: name });
|
|
8162
|
-
if (key === void 0) continue;
|
|
8163
|
-
if (associations === void 0) {
|
|
8164
|
-
associations = /* @__PURE__ */ new Map();
|
|
8165
|
-
crossStackAssociations.set(childSecrets, associations);
|
|
8166
|
-
}
|
|
8167
|
-
if (typeof association === "symbol") {
|
|
8168
|
-
associations.set(key, association);
|
|
8169
|
-
continue;
|
|
8170
|
-
}
|
|
8171
|
-
storeAssociation(associations, key, association.expression, association.plaintext);
|
|
8172
|
-
}
|
|
8173
|
-
}
|
|
8174
|
-
function inheritedParameterExpression(parentSecrets, parameterName, resolvedValue) {
|
|
8175
|
-
const association = nestedStackParameterExpressions.get(parentSecrets)?.get(parameterName);
|
|
8176
|
-
if (association === void 0 || typeof association === "symbol") return void 0;
|
|
8177
|
-
if (Array.isArray(resolvedValue)) return certifiedListForLeaf(parentSecrets, association, resolvedValue);
|
|
8178
|
-
return certifiedExpressionForLeaf(parentSecrets, association, resolvedValue);
|
|
8179
|
-
}
|
|
8180
|
-
|
|
8181
8233
|
//#endregion
|
|
8182
8234
|
//#region src/deployment/secret-redaction/unresolved-token-frame.ts
|
|
8183
8235
|
function liveMatchesUnresolvedTokenFrame(send, live, unresolvedTokens, secrets) {
|
|
@@ -17993,7 +18045,7 @@ async function resolveGetAtt(getAtt, context) {
|
|
|
17993
18045
|
const [rawLogicalId, rawAttributeName] = getAtt;
|
|
17994
18046
|
logicalId = rawLogicalId;
|
|
17995
18047
|
const resolvedAttributeName = await this.resolveValue(rawAttributeName, context);
|
|
17996
|
-
if (typeof resolvedAttributeName !== "string") throw new Error(`Fn::GetAtt attribute name for ${this.displayMasked(logicalId, context)} must resolve to a string, got ${typeof resolvedAttributeName}: ${stringifyValue(this.maskValueLeaves(resolvedAttributeName, context))}`);
|
|
18048
|
+
if (typeof resolvedAttributeName !== "string") throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetAtt attribute name for ${this.displayMasked(logicalId, context)} must resolve to a string, got ${typeof resolvedAttributeName}: ${stringifyValue(this.maskValueLeaves(resolvedAttributeName, context))}`));
|
|
17997
18049
|
attributeName = resolvedAttributeName;
|
|
17998
18050
|
} else {
|
|
17999
18051
|
const split = splitGetAttStringForm(getAtt);
|
|
@@ -18335,8 +18387,8 @@ function pinSecretVerdict(expression, secret, scope) {
|
|
|
18335
18387
|
async function resolveImportValue(importValueArg, context) {
|
|
18336
18388
|
const sourceKey = crossStackSourceKey({ "Fn::ImportValue": importValueArg });
|
|
18337
18389
|
const exportName = await this.resolveValue(importValueArg, context);
|
|
18338
|
-
if (typeof exportName !== "string") throw new Error(`Fn::ImportValue: export name must resolve to a string, got ${typeof exportName}`);
|
|
18339
|
-
if (!context.stateBackend) throw new Error("Fn::ImportValue: state backend is required for cross-stack references");
|
|
18390
|
+
if (typeof exportName !== "string") throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::ImportValue: export name must resolve to a string, got ${typeof exportName}`));
|
|
18391
|
+
if (!context.stateBackend) throw markNonRetryable(/* @__PURE__ */ new Error("Fn::ImportValue: state backend is required for cross-stack references"));
|
|
18340
18392
|
const loggedExportName = this.displayMasked(exportName, context);
|
|
18341
18393
|
this.logger.debug(`Resolving Fn::ImportValue: ${loggedExportName}`);
|
|
18342
18394
|
if (context.exportIndex) {
|
|
@@ -18516,32 +18568,32 @@ function getCfnClient(region) {
|
|
|
18516
18568
|
//#endregion
|
|
18517
18569
|
//#region src/deployment/intrinsic-resolver/stack-output.ts
|
|
18518
18570
|
async function resolveGetStackOutput(arg, context) {
|
|
18519
|
-
if (!arg || typeof arg !== "object" || Array.isArray(arg)) throw new Error(`Fn::GetStackOutput: argument must be an object with StackName/OutputName/Region/RoleArn, got ${arg === null ? "null" : Array.isArray(arg) ? "array" : typeof arg}`);
|
|
18571
|
+
if (!arg || typeof arg !== "object" || Array.isArray(arg)) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: argument must be an object with StackName/OutputName/Region/RoleArn, got ${arg === null ? "null" : Array.isArray(arg) ? "array" : typeof arg}`));
|
|
18520
18572
|
const args = arg;
|
|
18521
|
-
if (!("StackName" in args)) throw new Error("Fn::GetStackOutput: StackName is required");
|
|
18522
|
-
if (!("OutputName" in args)) throw new Error("Fn::GetStackOutput: OutputName is required");
|
|
18573
|
+
if (!("StackName" in args)) throw markNonRetryable(/* @__PURE__ */ new Error("Fn::GetStackOutput: StackName is required"));
|
|
18574
|
+
if (!("OutputName" in args)) throw markNonRetryable(/* @__PURE__ */ new Error("Fn::GetStackOutput: OutputName is required"));
|
|
18523
18575
|
const sourceKey = crossStackSourceKey({ "Fn::GetStackOutput": args });
|
|
18524
18576
|
const stackName = await this.resolveValue(args["StackName"], context);
|
|
18525
|
-
if (typeof stackName !== "string" || stackName === "") throw new Error(`Fn::GetStackOutput: StackName must resolve to a non-empty string, got ${typeof stackName}`);
|
|
18577
|
+
if (typeof stackName !== "string" || stackName === "") throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: StackName must resolve to a non-empty string, got ${typeof stackName}`));
|
|
18526
18578
|
const outputName = await this.resolveValue(args["OutputName"], context);
|
|
18527
|
-
if (typeof outputName !== "string" || outputName === "") throw new Error(`Fn::GetStackOutput: OutputName must resolve to a non-empty string, got ${typeof outputName}`);
|
|
18579
|
+
if (typeof outputName !== "string" || outputName === "") throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: OutputName must resolve to a non-empty string, got ${typeof outputName}`));
|
|
18528
18580
|
let region = this.resolverRegion;
|
|
18529
18581
|
let loggedRegionText = this.logTextOfLeaf(region, context);
|
|
18530
18582
|
if ("Region" in args && args["Region"] !== void 0 && args["Region"] !== null) {
|
|
18531
18583
|
const resolvedRegion = await this.resolveValue(args["Region"], context);
|
|
18532
|
-
if (typeof resolvedRegion !== "string" || resolvedRegion === "") throw new Error(`Fn::GetStackOutput: Region must resolve to a non-empty string, got ${typeof resolvedRegion}`);
|
|
18584
|
+
if (typeof resolvedRegion !== "string" || resolvedRegion === "") throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: Region must resolve to a non-empty string, got ${typeof resolvedRegion}`));
|
|
18533
18585
|
const requestedRegion = canonicalizeRegion(resolvedRegion);
|
|
18534
|
-
if (!isClientSafeRegion(requestedRegion)) throw new Error(`Fn::GetStackOutput: ${this.displayMaskedIdent(this.logTextOfLeaf(resolvedRegion, context) !== resolvedRegion ? "***" : resolvedRegion, context, 64)} is not a valid AWS region name. The region selects both the AWS endpoint and the state-file key, so cdkd will not use it.`);
|
|
18586
|
+
if (!isClientSafeRegion(requestedRegion)) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: ${this.displayMaskedIdent(this.logTextOfLeaf(resolvedRegion, context) !== resolvedRegion ? "***" : resolvedRegion, context, 64)} is not a valid AWS region name. The region selects both the AWS endpoint and the state-file key, so cdkd will not use it.`));
|
|
18535
18587
|
region = requestedRegion;
|
|
18536
18588
|
loggedRegionText = this.regionLogText(resolvedRegion, context);
|
|
18537
18589
|
}
|
|
18538
18590
|
let roleArn;
|
|
18539
18591
|
if ("RoleArn" in args && args["RoleArn"] !== void 0 && args["RoleArn"] !== null) {
|
|
18540
18592
|
const raw = args["RoleArn"];
|
|
18541
|
-
if (typeof raw !== "string" || raw === "") throw new Error(`Fn::GetStackOutput: RoleArn must be a literal string in the template (no Ref / Fn::GetAtt / Fn::Sub allowed for cross-account references). Got ${raw === null ? "null" : Array.isArray(raw) ? "array" : typeof raw}${typeof raw === "object" ? ` (intrinsic shape: ${this.displayMasked(JSON.stringify(raw).slice(0, 80), context)})` : ""}.`);
|
|
18593
|
+
if (typeof raw !== "string" || raw === "") throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: RoleArn must be a literal string in the template (no Ref / Fn::GetAtt / Fn::Sub allowed for cross-account references). Got ${raw === null ? "null" : Array.isArray(raw) ? "array" : typeof raw}${typeof raw === "object" ? ` (intrinsic shape: ${this.displayMasked(JSON.stringify(raw).slice(0, 80), context)})` : ""}.`));
|
|
18542
18594
|
roleArn = raw;
|
|
18543
18595
|
}
|
|
18544
|
-
if (!roleArn && context.stackName && context.stackName === stackName && canonicalizeRegion(region) === canonicalizeRegion(this.resolverRegion)) throw new Error(`Fn::GetStackOutput: cannot reference own stack ${this.displayMaskedIdent(stackName, context, STACK_REF_MAX_CODE_POINTS)} in the same region ${this.displayMaskedIdent(loggedRegionText, context)}`);
|
|
18596
|
+
if (!roleArn && context.stackName && context.stackName === stackName && canonicalizeRegion(region) === canonicalizeRegion(this.resolverRegion)) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: cannot reference own stack ${this.displayMaskedIdent(stackName, context, STACK_REF_MAX_CODE_POINTS)} in the same region ${this.displayMaskedIdent(loggedRegionText, context)}`));
|
|
18545
18597
|
const loggedStackName = this.displayMaskedIdent(stackName, context, STACK_REF_MAX_CODE_POINTS);
|
|
18546
18598
|
const loggedOutputName = this.displayMaskedIdent(outputName, context);
|
|
18547
18599
|
const loggedRegion = this.displayMasked(loggedRegionText, context);
|
|
@@ -18559,7 +18611,7 @@ async function resolveGetStackOutput(arg, context) {
|
|
|
18559
18611
|
if (cfnOutputs) {
|
|
18560
18612
|
if (!Object.hasOwn(cfnOutputs, outputName)) {
|
|
18561
18613
|
const available = this.describeAvailableOutputs(Object.keys(cfnOutputs), context);
|
|
18562
|
-
throw new Error(`Fn::GetStackOutput: output ${loggedOutputName} not found in CloudFormation stack ${loggedStackName} (${displayIdent(loggedRegion)}). Available outputs: ${available}`);
|
|
18614
|
+
throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: output ${loggedOutputName} not found in CloudFormation stack ${loggedStackName} (${displayIdent(loggedRegion)}). Available outputs: ${available}`));
|
|
18563
18615
|
}
|
|
18564
18616
|
const value = cfnOutputs[outputName];
|
|
18565
18617
|
this.logger.info(`Resolved Fn::GetStackOutput: StackName=${loggedStackName}, Region=${loggedRegion}, OutputName=${loggedOutputName} (from CloudFormation stack outputs; weak reference — producer is not cdkd-managed)`);
|
|
@@ -18572,7 +18624,7 @@ async function resolveGetStackOutput(arg, context) {
|
|
|
18572
18624
|
const outputs = stateData.state.outputs ?? {};
|
|
18573
18625
|
if (!Object.hasOwn(outputs, outputName)) {
|
|
18574
18626
|
const available = this.describeAvailableOutputs(Object.keys(outputs), context);
|
|
18575
|
-
throw new Error(`Fn::GetStackOutput: output ${loggedOutputName} not found in stack ${loggedStackName} (${displayIdent(loggedRegion)}). Available outputs: ${available}`);
|
|
18627
|
+
throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: output ${loggedOutputName} not found in stack ${loggedStackName} (${displayIdent(loggedRegion)}). Available outputs: ${available}`));
|
|
18576
18628
|
}
|
|
18577
18629
|
const value = outputs[outputName];
|
|
18578
18630
|
this.logger.info(`Resolved Fn::GetStackOutput: StackName=${loggedStackName}, Region=${loggedRegion}, OutputName=${loggedOutputName}${roleArn ? `, RoleArn=${shownRoleArn}` : ""} (${carriesDynamicReference(value) ? "redacted dynamic reference" : "literal value"})`);
|
|
@@ -18825,7 +18877,7 @@ async function applyRoleArnIfSet(opts) {
|
|
|
18825
18877
|
//#endregion
|
|
18826
18878
|
//#region src/deployment/intrinsic-resolver/stack-state.ts
|
|
18827
18879
|
async function getSameAccountStackState(stackName, region, context) {
|
|
18828
|
-
if (!context.stateBackend) throw new Error("Fn::GetStackOutput: state backend is required for cross-stack references");
|
|
18880
|
+
if (!context.stateBackend) throw markNonRetryable(/* @__PURE__ */ new Error("Fn::GetStackOutput: state backend is required for cross-stack references"));
|
|
18829
18881
|
return context.stateBackend.getState(stackName, region);
|
|
18830
18882
|
}
|
|
18831
18883
|
async function getCrossAccountStackState(roleArn, stackName, region, context) {
|
|
@@ -18834,7 +18886,7 @@ async function getCrossAccountStackState(roleArn, stackName, region, context) {
|
|
|
18834
18886
|
const shownRoleArn = displayIdent(roleArn, { maxCodePoints: 613 });
|
|
18835
18887
|
const bounded = !/\s/.test(roleArn) && shownRoleArn === roleArn ? `'${shownRoleArn}'` : shellBoundedDisplay(shownRoleArn);
|
|
18836
18888
|
const subject = bounded === "a value that cannot be shown safely here" ? `the RoleArn argument (${UNSHOWABLE_VALUE})` : `RoleArn ${bounded}`;
|
|
18837
|
-
throw new Error(`Fn::GetStackOutput: ${subject} is not a valid IAM role ARN. Expected shape: arn:<partition>:iam::<12-digit-account-id>:role/<role-name> (e.g. arn:aws:iam::123456789012:role/MyRole, arn:aws-us-gov:iam::...).`);
|
|
18889
|
+
throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetStackOutput: ${subject} is not a valid IAM role ARN. Expected shape: arn:<partition>:iam::<12-digit-account-id>:role/<role-name> (e.g. arn:aws:iam::123456789012:role/MyRole, arn:aws-us-gov:iam::...).`));
|
|
18838
18890
|
}
|
|
18839
18891
|
const credentials = await assumeRoleForCrossAccountStateRead(roleArn);
|
|
18840
18892
|
const { bucket, region: bucketRegion } = await resolveCrossAccountStateBucket(parsed.accountId, credentials);
|
|
@@ -19139,7 +19191,7 @@ async function resolveSecretsManagerReference(inner, context, nameLogText) {
|
|
|
19139
19191
|
versionId = remainingParts[2] || "";
|
|
19140
19192
|
} else secretId = afterService;
|
|
19141
19193
|
if (!versionStage) versionStage = "AWSCURRENT";
|
|
19142
|
-
if (!secretId) throw new Error("Dynamic reference: secretsmanager SECRET_ID is required");
|
|
19194
|
+
if (!secretId) throw markNonRetryable(/* @__PURE__ */ new Error("Dynamic reference: secretsmanager SECRET_ID is required"));
|
|
19143
19195
|
const loggedSecretId = this.displayMasked(nameLogText(secretId), context);
|
|
19144
19196
|
const loggedJsonKey = this.displayMasked(nameLogText(jsonKey), context);
|
|
19145
19197
|
this.logger.debug(`Resolving dynamic reference: secretsmanager:${loggedSecretId}:SecretString:${loggedJsonKey}:${this.displayMasked(nameLogText(versionStage), context)}:${this.displayMasked(nameLogText(versionId), context)}`);
|
|
@@ -19154,14 +19206,14 @@ async function resolveSecretsManagerReference(inner, context, nameLogText) {
|
|
|
19154
19206
|
[versionStage, this.displayMasked(nameLogText(versionStage), context)],
|
|
19155
19207
|
[versionId, this.displayMasked(nameLogText(versionId), context)]
|
|
19156
19208
|
], context))).SecretString;
|
|
19157
|
-
if (!secretString) throw new Error(`Dynamic reference: secret ${quotedRender(loggedSecretId, "'")} does not contain a SecretString value`);
|
|
19209
|
+
if (!secretString) throw markNonRetryable(/* @__PURE__ */ new Error(`Dynamic reference: secret ${quotedRender(loggedSecretId, "'")} does not contain a SecretString value`));
|
|
19158
19210
|
if (jsonKey) try {
|
|
19159
19211
|
const parsed = JSON.parse(secretString);
|
|
19160
19212
|
const keyValue = Object.hasOwn(parsed, jsonKey) ? parsed[jsonKey] : void 0;
|
|
19161
|
-
if (keyValue === void 0) throw new Error(`Dynamic reference: key ${quotedRender(loggedJsonKey, "'")} not found in secret ${quotedRender(loggedSecretId, "'")}`);
|
|
19213
|
+
if (keyValue === void 0) throw markNonRetryable(/* @__PURE__ */ new Error(`Dynamic reference: key ${quotedRender(loggedJsonKey, "'")} not found in secret ${quotedRender(loggedSecretId, "'")}`));
|
|
19162
19214
|
return stringifyValue(keyValue);
|
|
19163
19215
|
} catch (error) {
|
|
19164
|
-
if (error instanceof SyntaxError) throw new Error(`Dynamic reference: secret ${quotedRender(loggedSecretId, "'")} is not valid JSON but JSON_KEY ${quotedRender(loggedJsonKey, "'")} was specified`);
|
|
19216
|
+
if (error instanceof SyntaxError) throw markNonRetryable(/* @__PURE__ */ new Error(`Dynamic reference: secret ${quotedRender(loggedSecretId, "'")} is not valid JSON but JSON_KEY ${quotedRender(loggedJsonKey, "'")} was specified`));
|
|
19165
19217
|
throw error;
|
|
19166
19218
|
}
|
|
19167
19219
|
return secretString;
|
|
@@ -19180,7 +19232,7 @@ async function sendWithThrottleRetry(operation, label, masks) {
|
|
|
19180
19232
|
}
|
|
19181
19233
|
async function resolveSSMReference(parts, decrypt, service, context, nameLogText) {
|
|
19182
19234
|
const parameterName = parts.slice(1).join(":");
|
|
19183
|
-
if (!parameterName) throw new Error(`Dynamic reference: ${service} PARAMETER_NAME is required`);
|
|
19235
|
+
if (!parameterName) throw markNonRetryable(/* @__PURE__ */ new Error(`Dynamic reference: ${service} PARAMETER_NAME is required`));
|
|
19184
19236
|
const loggedParameterName = this.displayMasked(nameLogText(parameterName), context);
|
|
19185
19237
|
this.logger.debug(`Resolving dynamic reference: ${service}:${loggedParameterName}`);
|
|
19186
19238
|
const client = this.clientsForRegion(this.explicitRegion).ssm;
|
|
@@ -19190,7 +19242,7 @@ async function resolveSSMReference(parts, decrypt, service, context, nameLogText
|
|
|
19190
19242
|
});
|
|
19191
19243
|
const response = await this.sendWithThrottleRetry(() => client.send(command), `${service}:${loggedParameterName}`, this.namedRequestMasks([[parameterName, loggedParameterName]], context));
|
|
19192
19244
|
const paramValue = response.Parameter?.Value;
|
|
19193
|
-
if (paramValue === void 0 || paramValue === null) throw new Error(`Dynamic reference: SSM parameter ${quotedRender(loggedParameterName, "'")} not found or has no value`);
|
|
19245
|
+
if (paramValue === void 0 || paramValue === null) throw markNonRetryable(/* @__PURE__ */ new Error(`Dynamic reference: SSM parameter ${quotedRender(loggedParameterName, "'")} not found or has no value`));
|
|
19194
19246
|
const paramType = response.Parameter?.Type;
|
|
19195
19247
|
const secure = paramType !== "String" && paramType !== "StringList";
|
|
19196
19248
|
if (secure && paramType !== "SecureString" && !this.warnedUnrecognizedSsmTypes.has(injectiveKey(parameterName, String(paramType)))) {
|
|
@@ -19234,7 +19286,7 @@ async function resolveJoin(joinArgs, context, source) {
|
|
|
19234
19286
|
const [delimiter, rawValues] = joinArgs;
|
|
19235
19287
|
let values = rawValues;
|
|
19236
19288
|
if (!Array.isArray(values)) values = await this.resolveValue(values, context);
|
|
19237
|
-
if (!Array.isArray(values)) throw new Error(`Fn::Join's second argument must be a list (an array literal or a list-returning intrinsic such as Fn::Cidr / Fn::GetAZs / Fn::Split / a Ref to a list-typed parameter — any List<...> type or CommaDelimitedList), but resolved to ${typeof values}`);
|
|
19289
|
+
if (!Array.isArray(values)) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::Join's second argument must be a list (an array literal or a list-returning intrinsic such as Fn::Cidr / Fn::GetAZs / Fn::Split / a Ref to a list-typed parameter — any List<...> type or CommaDelimitedList), but resolved to ${typeof values}`));
|
|
19238
19290
|
const literalList = Array.isArray(rawValues);
|
|
19239
19291
|
const resolvedParts = await allSettledKeepingFirstRejection(() => values.map(async (v) => {
|
|
19240
19292
|
if (typeof v === "string") {
|
|
@@ -19317,7 +19369,7 @@ async function resolveSelect(selectArgs, context) {
|
|
|
19317
19369
|
throw markNonRetryable(new IntrinsicResolutionRefusalError(`Fn::Select: the index${sourceClause} must resolve to a non-negative integer (a number, or its decimal string with no leading zero), got ${this.describeOperandShape(resolvedIndex, context)}. Use a literal, a Ref to a parameter or an Fn::FindInMap that yields one.`));
|
|
19318
19370
|
}
|
|
19319
19371
|
const resolvedList = await this.resolveValue(list, context);
|
|
19320
|
-
if (!Array.isArray(resolvedList)) throw new Error(`Fn::Select: list must be an array, got ${typeof resolvedList}`);
|
|
19372
|
+
if (!Array.isArray(resolvedList)) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::Select: list must be an array, got ${typeof resolvedList}`));
|
|
19321
19373
|
const loggedPosition = this.displayMasked(String(position), context);
|
|
19322
19374
|
if (position >= resolvedList.length) {
|
|
19323
19375
|
if (loggedPosition !== String(position)) throw markNonRetryable(new IntrinsicResolutionRefusalError(`Fn::Select: the index ${loggedPosition} is out of bounds (array length: ${resolvedList.length}), and it resolves from a secret value, so cdkd will not write it into the OutOfBounds placeholder.`));
|
|
@@ -19653,7 +19705,7 @@ async function resolveConditionReference(conditionName, context) {
|
|
|
19653
19705
|
return false;
|
|
19654
19706
|
}
|
|
19655
19707
|
async function resolveAnd(conditions, context) {
|
|
19656
|
-
if (!Array.isArray(conditions) || conditions.length < 2 || conditions.length > 10) throw new Error(`Fn::And requires between 2 and 10 conditions, got ${conditions.length}`);
|
|
19708
|
+
if (!Array.isArray(conditions) || conditions.length < 2 || conditions.length > 10) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::And requires between 2 and 10 conditions, got ${conditions.length}`));
|
|
19657
19709
|
const results = [];
|
|
19658
19710
|
for (const condition of conditions) {
|
|
19659
19711
|
const resolved = await this.resolveValue(condition, context);
|
|
@@ -19664,7 +19716,7 @@ async function resolveAnd(conditions, context) {
|
|
|
19664
19716
|
return result;
|
|
19665
19717
|
}
|
|
19666
19718
|
async function resolveOr(conditions, context) {
|
|
19667
|
-
if (!Array.isArray(conditions) || conditions.length < 2 || conditions.length > 10) throw new Error(`Fn::Or requires between 2 and 10 conditions, got ${conditions.length}`);
|
|
19719
|
+
if (!Array.isArray(conditions) || conditions.length < 2 || conditions.length > 10) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::Or requires between 2 and 10 conditions, got ${conditions.length}`));
|
|
19668
19720
|
const results = [];
|
|
19669
19721
|
for (const condition of conditions) {
|
|
19670
19722
|
const resolved = await this.resolveValue(condition, context);
|
|
@@ -19675,7 +19727,7 @@ async function resolveOr(conditions, context) {
|
|
|
19675
19727
|
return result;
|
|
19676
19728
|
}
|
|
19677
19729
|
async function resolveNot(notArgs, context) {
|
|
19678
|
-
if (!Array.isArray(notArgs) || notArgs.length !== 1) throw new Error(`Fn::Not requires exactly one condition, got ${Array.isArray(notArgs) ? notArgs.length : 0}`);
|
|
19730
|
+
if (!Array.isArray(notArgs) || notArgs.length !== 1) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::Not requires exactly one condition, got ${Array.isArray(notArgs) ? notArgs.length : 0}`));
|
|
19679
19731
|
const [condition] = notArgs;
|
|
19680
19732
|
const resolved = await this.resolveValue(condition, context);
|
|
19681
19733
|
const result = !resolved;
|
|
@@ -19693,20 +19745,20 @@ async function resolveFindInMap(findInMapArgs, context) {
|
|
|
19693
19745
|
const map = mappings != null && Object.hasOwn(mappings, mapName) ? mappings[mapName] : void 0;
|
|
19694
19746
|
if (!mappings) {
|
|
19695
19747
|
if (hasDefaultValue) return await resolveDefault();
|
|
19696
|
-
throw new Error(`Fn::FindInMap: no Mappings section found in template`);
|
|
19748
|
+
throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::FindInMap: no Mappings section found in template`));
|
|
19697
19749
|
}
|
|
19698
19750
|
if (!map) {
|
|
19699
19751
|
if (hasDefaultValue) return await resolveDefault();
|
|
19700
|
-
throw new Error(`Fn::FindInMap: mapping ${quotedRender(this.displayMasked(mapName, context), "'")} not found in Mappings section`);
|
|
19752
|
+
throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::FindInMap: mapping ${quotedRender(this.displayMasked(mapName, context), "'")} not found in Mappings section`));
|
|
19701
19753
|
}
|
|
19702
19754
|
const topLevel = Object.hasOwn(map, topLevelKey) ? map[topLevelKey] : void 0;
|
|
19703
19755
|
if (!topLevel || typeof topLevel !== "object") {
|
|
19704
19756
|
if (hasDefaultValue) return await resolveDefault();
|
|
19705
|
-
throw new Error(`Fn::FindInMap: top-level key ${quotedRender(this.displayMasked(topLevelKey, context), "'")} not found in mapping ${quotedRender(this.displayMasked(mapName, context), "'")}`);
|
|
19757
|
+
throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::FindInMap: top-level key ${quotedRender(this.displayMasked(topLevelKey, context), "'")} not found in mapping ${quotedRender(this.displayMasked(mapName, context), "'")}`));
|
|
19706
19758
|
}
|
|
19707
19759
|
if (!Object.hasOwn(topLevel, secondLevelKey)) {
|
|
19708
19760
|
if (hasDefaultValue) return await resolveDefault();
|
|
19709
|
-
throw new Error(`Fn::FindInMap: second-level key ${quotedRender(this.displayMasked(secondLevelKey, context), "'")} not found in mapping ${quotedRender(this.displayMasked(mapName, context), "'")} under top-level key ${quotedRender(this.displayMasked(topLevelKey, context), "'")}`);
|
|
19761
|
+
throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::FindInMap: second-level key ${quotedRender(this.displayMasked(secondLevelKey, context), "'")} not found in mapping ${quotedRender(this.displayMasked(mapName, context), "'")} under top-level key ${quotedRender(this.displayMasked(topLevelKey, context), "'")}`));
|
|
19710
19762
|
}
|
|
19711
19763
|
const result = topLevel[secondLevelKey];
|
|
19712
19764
|
this.logger.debug(`Resolved Fn::FindInMap: ${this.logRender(mapName, context)}.${this.logRender(topLevelKey, context)}.${this.logRender(secondLevelKey, context)} resolved to ${this.logRender(JSON.stringify(this.maskValueLeaves(result, context)), context, { structured: true })}`);
|
|
@@ -19714,7 +19766,7 @@ async function resolveFindInMap(findInMapArgs, context) {
|
|
|
19714
19766
|
}
|
|
19715
19767
|
async function resolveBase64(value, context) {
|
|
19716
19768
|
const resolvedValue = await this.resolveValue(value, context);
|
|
19717
|
-
if (typeof resolvedValue !== "string") throw new Error(`Fn::Base64: value must resolve to a string, got ${typeof resolvedValue}`);
|
|
19769
|
+
if (typeof resolvedValue !== "string") throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::Base64: value must resolve to a string, got ${typeof resolvedValue}`));
|
|
19718
19770
|
if (context.skipDynamicReferences === true && keepsSecretReferenceToken(resolvedValue) && !(context.recordedSecretValues !== void 0 && embedsFreshNoEchoValue(resolvedValue, context.recordedSecretValues))) {
|
|
19719
19771
|
this.logger.debug(safeMsg`Resolved Fn::Base64: ${this.logRender(this.logTextOfLeaf(resolvedValue, context), context)} resolved to ${"***"} (an unresolved secret reference, compared as the mask the deploy persists)`);
|
|
19720
19772
|
return "***";
|
|
@@ -19742,7 +19794,7 @@ async function resolveGetAZs(value, context) {
|
|
|
19742
19794
|
let loggedRegionText;
|
|
19743
19795
|
if (typeof resolvedValue === "string" && resolvedValue !== "") {
|
|
19744
19796
|
const requested = canonicalizeRegion(resolvedValue);
|
|
19745
|
-
if (!isClientSafeRegion(requested)) throw new Error(`Fn::GetAZs: the value ${quotedRender(this.displayMasked(this.logTextOfLeaf(resolvedValue, context) !== resolvedValue ? "***" : resolvedValue, context).slice(0, 64), "'")} is not a valid AWS region name. A region is substituted into the AWS service hostname, so cdkd will not build a client from it.`);
|
|
19797
|
+
if (!isClientSafeRegion(requested)) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetAZs: the value ${quotedRender(this.displayMasked(this.logTextOfLeaf(resolvedValue, context) !== resolvedValue ? "***" : resolvedValue, context).slice(0, 64), "'")} is not a valid AWS region name. A region is substituted into the AWS service hostname, so cdkd will not build a client from it.`));
|
|
19746
19798
|
region = requested;
|
|
19747
19799
|
clientRegion = requested;
|
|
19748
19800
|
loggedRegionText = this.regionLogText(resolvedValue, context);
|
|
@@ -19771,7 +19823,7 @@ async function resolveGetAZs(value, context) {
|
|
|
19771
19823
|
const masks = this.namedRequestMasks([[region, loggedRegion]], context);
|
|
19772
19824
|
throw new Error(`Fn::GetAZs: failed to describe availability zones for region ${quotedRender(loggedRegion, "'")}: ${masks.text(error instanceof Error ? error.message : String(error))}`);
|
|
19773
19825
|
}
|
|
19774
|
-
if (azNames.length === 0) throw new Error(`Fn::GetAZs: no availability zones returned for region ${quotedRender(this.displayMasked(loggedRegionText ?? region, context), "'")}. Either the region is not enabled on this account (opt-in regions must be enabled before use), or the request was answered by a different region's endpoint.`);
|
|
19826
|
+
if (azNames.length === 0) throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::GetAZs: no availability zones returned for region ${quotedRender(this.displayMasked(loggedRegionText ?? region, context), "'")}. Either the region is not enabled on this account (opt-in regions must be enabled before use), or the request was answered by a different region's endpoint.`));
|
|
19775
19827
|
cachedAvailabilityZones.set(azCacheKey, azNames);
|
|
19776
19828
|
this.logger.debug(`Resolved Fn::GetAZs: ${this.logRender(loggedRegionText ?? region, context)} resolved to ${this.logRender(JSON.stringify(this.maskValueLeaves(azNames, context)), context, { structured: true })}`);
|
|
19777
19829
|
return azNames;
|
|
@@ -19797,7 +19849,7 @@ async function resolveCidr(args, context) {
|
|
|
19797
19849
|
const ipBlock = await this.resolveValue(rawIpBlock, context);
|
|
19798
19850
|
const count = Number(await this.resolveValue(rawCount, context));
|
|
19799
19851
|
const cidrBits = Number(await this.resolveValue(rawCidrBits, context));
|
|
19800
|
-
if (!ipBlock || typeof ipBlock !== "string") throw new Error(`Fn::Cidr: ipBlock must be a string, got ${typeof ipBlock}: ${JSON.stringify(this.maskValueLeaves(ipBlock, context))}`);
|
|
19852
|
+
if (!ipBlock || typeof ipBlock !== "string") throw markNonRetryable(/* @__PURE__ */ new Error(`Fn::Cidr: ipBlock must be a string, got ${typeof ipBlock}: ${JSON.stringify(this.maskValueLeaves(ipBlock, context))}`));
|
|
19801
19853
|
this.logger.debug(`Resolving Fn::Cidr: ipBlock=${this.displayMasked(JSON.stringify(this.maskValueLeaves(ipBlock, context)), context)}, count=${this.displayMasked(String(count), context)}, cidrBits=${this.displayMasked(String(cidrBits), context)}`);
|
|
19802
19854
|
const isIpv6 = ipBlock.includes(":");
|
|
19803
19855
|
const results = [];
|
|
@@ -20095,7 +20147,7 @@ async function resolveParameters(template, userParameters, options) {
|
|
|
20095
20147
|
let referencedNames;
|
|
20096
20148
|
for (const [name, definition] of Object.entries(templateParameters)) {
|
|
20097
20149
|
const paramDef = definition;
|
|
20098
|
-
if (isUnboundTemplateParameter(name, template, userParameters)) throw new Error(`Parameter ${maskInherited(name)} is required but no value was provided and no default exists`);
|
|
20150
|
+
if (isUnboundTemplateParameter(name, template, userParameters)) throw markNonRetryable(/* @__PURE__ */ new Error(`Parameter ${maskInherited(name)} is required but no value was provided and no default exists`));
|
|
20099
20151
|
if (userParameters && Object.hasOwn(userParameters, name)) {
|
|
20100
20152
|
const userValue = userParameters[name];
|
|
20101
20153
|
if (userValue !== void 0) {
|
|
@@ -20197,6 +20249,7 @@ function recordInheritedParameterSecrets(parameterName, value, context) {
|
|
|
20197
20249
|
for (const [plaintext, expression] of inheritedSecretsCarriedBy(value, inherited)) {
|
|
20198
20250
|
const own = inheritedParameterExpression(inherited, parameterName, plaintext);
|
|
20199
20251
|
recorded.set(plaintext, typeof own === "string" ? own : expression);
|
|
20252
|
+
recordInheritedParameterRead(recorded, inherited, parameterName);
|
|
20200
20253
|
carryFreshNoEchoMark(inherited, recorded, plaintext);
|
|
20201
20254
|
}
|
|
20202
20255
|
}
|
|
@@ -20420,7 +20473,7 @@ var IntrinsicFunctionResolver = class IntrinsicFunctionResolver {
|
|
|
20420
20473
|
if ("Fn::GetAZs" in obj) return await this.resolveGetAZs(obj["Fn::GetAZs"], context);
|
|
20421
20474
|
if ("Fn::Cidr" in obj) return await this.resolveCidr(obj["Fn::Cidr"], context);
|
|
20422
20475
|
const unknownIntrinsicKey = detectUnknownIntrinsicKey(obj);
|
|
20423
|
-
if (unknownIntrinsicKey !== void 0) throw buildUnknownIntrinsicError(unknownIntrinsicKey);
|
|
20476
|
+
if (unknownIntrinsicKey !== void 0) throw markNonRetryable(buildUnknownIntrinsicError(unknownIntrinsicKey));
|
|
20424
20477
|
const resolved = {};
|
|
20425
20478
|
for (const [key, val] of Object.entries(obj)) {
|
|
20426
20479
|
const resolvedVal = context.abandonedResolutions === void 0 ? await this.resolveValue(val, context) : await this.resolveKeyUnit(key, val, context, context.abandonedResolutions);
|
|
@@ -22050,7 +22103,7 @@ var CloudControlProvider = class {
|
|
|
22050
22103
|
const indeterminateGuard = await this.confirmDeleteTargetIdentity(logicalId, resourceType, physicalId, context);
|
|
22051
22104
|
if (context?.removeProtection === true && resourceType === "AWS::AutoScaling::AutoScalingGroup") {
|
|
22052
22105
|
this.logger.debug(`Delegating protected AutoScalingGroup ${logicalId} delete to the SDK ASGProvider (Cloud Control cannot force-delete a protected ASG)`);
|
|
22053
|
-
const { ASGProvider } = await import("./asg-provider-
|
|
22106
|
+
const { ASGProvider } = await import("./asg-provider-BU0YONBp.js");
|
|
22054
22107
|
const delegateRegion = ambientRegion();
|
|
22055
22108
|
let asgProvider = this.asgDeleteDelegates.get(delegateRegion);
|
|
22056
22109
|
if (asgProvider === void 0) {
|
|
@@ -22156,7 +22209,7 @@ var CloudControlProvider = class {
|
|
|
22156
22209
|
const family = SDK_DELETE_FAMILIES.get(resourceType);
|
|
22157
22210
|
const cached = this.sdkDeleteDelegates.get(family);
|
|
22158
22211
|
if (cached !== void 0 && cached.region === ccRegion) return cached.provider;
|
|
22159
|
-
const provider = family === "rds" ? new (await (import("./rds-provider-
|
|
22212
|
+
const provider = family === "rds" ? new (await (import("./rds-provider-Cf5P2so_.js"))).RDSProvider({ region: ccRegion }) : new (await (import("./neptune-provider-C3f-vDOh.js"))).NeptuneProvider({ region: ccRegion });
|
|
22160
22213
|
this.sdkDeleteDelegates.set(family, {
|
|
22161
22214
|
region: ccRegion,
|
|
22162
22215
|
provider
|
|
@@ -27827,6 +27880,24 @@ function recordRollbackSkip(scope, op, reason) {
|
|
|
27827
27880
|
reason: scope.mask(reason)
|
|
27828
27881
|
});
|
|
27829
27882
|
}
|
|
27883
|
+
function rollbackCannotAddress(record, opResourceType, route, physicalId) {
|
|
27884
|
+
return !(record?.resourceType === "AWS::CloudFormation::Stack" && opResourceType === "AWS::CloudFormation::Stack" && record.provisionedBy !== "cc-api" && route !== "cc-api") && !hasAddressablePhysicalId({ physicalId });
|
|
27885
|
+
}
|
|
27886
|
+
function retainedSurvivorId(record, op) {
|
|
27887
|
+
if (hasAddressablePhysicalId(record)) return record.physicalId;
|
|
27888
|
+
if (hasAddressablePhysicalId(op)) return op.physicalId;
|
|
27889
|
+
}
|
|
27890
|
+
const UNADDRESSABLE_SKIP_CAUSE = "Its recorded 'physicalId' is not a non-empty string, so cdkd cannot address the resource in AWS and sent nothing for it; the rollback left it and its state record exactly as they are.";
|
|
27891
|
+
const UNADDRESSABLE_JOURNAL_SKIP_CAUSE = "Its rollback-journal entry's 'physicalId' is not a non-empty string and no state record holds the resource, so cdkd cannot address it in AWS and sent nothing for it; if it was created in AWS, delete it manually.";
|
|
27892
|
+
function skipUnaddressableReplay(scope, logger, op, what, source = "record") {
|
|
27893
|
+
if (source === "journal") {
|
|
27894
|
+
logger.warn(safeMsg` Rollback: Cannot ${what} ${shownLogicalId(op.logicalId)} (${refusalResourceType(op.resourceType)}) ` + "— its rollback journal entry has no non-empty string 'physicalId' and no state record holds it, so cdkd cannot address it in AWS and sent nothing for it. If it was created in AWS, delete it manually.");
|
|
27895
|
+
recordRollbackSkip(scope, op, UNADDRESSABLE_JOURNAL_SKIP_CAUSE);
|
|
27896
|
+
return;
|
|
27897
|
+
}
|
|
27898
|
+
logger.warn(safeMsg` Rollback: Cannot ${what} ${shownLogicalId(op.logicalId)} (${refusalResourceType(op.resourceType)}) ` + "— its state record has no non-empty string 'physicalId', so cdkd cannot address it in AWS and sent nothing for it. The resource and its state record are left exactly as they are. Repair the record's 'physicalId' (inspect it with `cdkd state show`), then re-converge it with `cdkd deploy`.");
|
|
27899
|
+
recordRollbackSkip(scope, op, UNADDRESSABLE_SKIP_CAUSE);
|
|
27900
|
+
}
|
|
27830
27901
|
function effectiveProvisionedBy(record, fallbackProvisionedBy) {
|
|
27831
27902
|
return record?.provisionedBy ?? fallbackProvisionedBy;
|
|
27832
27903
|
}
|
|
@@ -28565,6 +28636,15 @@ function classifyRollbackOp(op, stateResources, orphanLogicalIds) {
|
|
|
28565
28636
|
oldProperties: op.previousState.properties,
|
|
28566
28637
|
newProperties: current.properties
|
|
28567
28638
|
})) return "skip-already-done";
|
|
28639
|
+
const retainedOld = op.oldResourceRetained ?? op.previousState.updateReplacePolicy === "Retain";
|
|
28640
|
+
if (rollbackCannotAddress(current, op.resourceType, current.provisionedBy ?? op.provisionedBy, current.physicalId)) {
|
|
28641
|
+
if (!resolveReplacementOldType(op).ok) return "refuse-replacement-routing";
|
|
28642
|
+
return retainedOld ? "reverse-replacement-readopt" : "reverse-replacement";
|
|
28643
|
+
}
|
|
28644
|
+
if (retainedOld && op.physicalId !== void 0 && !hasAddressablePhysicalId(op)) {
|
|
28645
|
+
if (!resolveReplacementOldType(op).ok) return "refuse-replacement-routing";
|
|
28646
|
+
return "reverse-replacement-readopt";
|
|
28647
|
+
}
|
|
28568
28648
|
if (op.physicalId !== void 0 && current.physicalId !== op.physicalId) {
|
|
28569
28649
|
if (sameTypeAsOld && deepEqual$1(current.properties, op.previousState.properties)) return "skip-already-done";
|
|
28570
28650
|
return "skip-mismatch";
|
|
@@ -28584,7 +28664,7 @@ function classifyFailedOp(op, stateResources, siblings = []) {
|
|
|
28584
28664
|
if (op.physicalIdRecoveredFromError === true) {
|
|
28585
28665
|
if (current) {
|
|
28586
28666
|
if (current.physicalId === op.physicalId) return "skip-failed-noop";
|
|
28587
|
-
if (!isReplacedRecord(op, current)) return "skip-failed-mismatch";
|
|
28667
|
+
if (!isReplacedRecord(op, current) && !isProvenDistinctRecord(op, current)) return "skip-failed-mismatch";
|
|
28588
28668
|
}
|
|
28589
28669
|
if (stateHoldsPhysicalId(stateResources, op.resourceType, op.physicalId)) return "skip-failed-noop";
|
|
28590
28670
|
const orphanPolicy = effectiveDeletionPolicy(op.resourceType, op.deletionPolicy, op.attemptedProperties);
|
|
@@ -28611,7 +28691,21 @@ function isReplacedRecord(op, record) {
|
|
|
28611
28691
|
return isReplacementOrphan(op) && record !== void 0 && record.physicalId === op.replacedPhysicalId && record.resourceType === op.replacedResourceType;
|
|
28612
28692
|
}
|
|
28613
28693
|
function failedOpOwnRecord(op, stateResources) {
|
|
28614
|
-
return
|
|
28694
|
+
return recordUnderIdIsNotOwn(op, stateResources) ? void 0 : stateResources[op.logicalId];
|
|
28695
|
+
}
|
|
28696
|
+
const provenDistinctFrom = /* @__PURE__ */ new WeakMap();
|
|
28697
|
+
function markProvenDistinctFromRecord(op, record) {
|
|
28698
|
+
provenDistinctFrom.set(op, {
|
|
28699
|
+
physicalId: record.physicalId,
|
|
28700
|
+
resourceType: record.resourceType
|
|
28701
|
+
});
|
|
28702
|
+
}
|
|
28703
|
+
function isProvenDistinctRecord(op, record) {
|
|
28704
|
+
const verdict = provenDistinctFrom.get(op);
|
|
28705
|
+
return verdict !== void 0 && record !== void 0 && record.physicalId === verdict.physicalId && record.resourceType === verdict.resourceType;
|
|
28706
|
+
}
|
|
28707
|
+
function recordUnderIdIsNotOwn(op, stateResources) {
|
|
28708
|
+
return isReplacementOrphan(op) || isProvenDistinctRecord(op, Object.hasOwn(stateResources, op.logicalId) ? stateResources[op.logicalId] : void 0);
|
|
28615
28709
|
}
|
|
28616
28710
|
function replacementNeverSwapped(op, siblings) {
|
|
28617
28711
|
return siblings.some((s) => s !== op && isReplacementOrphan(s) && s.logicalId === op.logicalId && s.replacedPhysicalId === op.physicalId);
|
|
@@ -28892,6 +28986,10 @@ async function replayDelete(s) {
|
|
|
28892
28986
|
return;
|
|
28893
28987
|
}
|
|
28894
28988
|
const deleteProvisionedBy = effectiveProvisionedBy(stateResources[op.logicalId], op.provisionedBy);
|
|
28989
|
+
if (rollbackCannotAddress(stateResources[op.logicalId], op.resourceType, deleteProvisionedBy, op.physicalId)) {
|
|
28990
|
+
skipUnaddressableReplay(s, logger, op, "delete created resource");
|
|
28991
|
+
return;
|
|
28992
|
+
}
|
|
28895
28993
|
s.createRollbackRoute = deleteProvisionedBy;
|
|
28896
28994
|
const snapshotPolicy = action === "delete-with-final-snapshot";
|
|
28897
28995
|
const takeFinalSnapshot = snapshotPolicy && ctx.skipFinalSnapshot !== true;
|
|
@@ -28937,10 +29035,24 @@ async function replayReadopt(s) {
|
|
|
28937
29035
|
const { op, stateResources, stackName, ctx, result, inlinePolicyWriters, afterOp, logger, mask } = s;
|
|
28938
29036
|
const current = stateResources[op.logicalId];
|
|
28939
29037
|
const prev = op.previousState;
|
|
29038
|
+
const oldShown = hasAddressablePhysicalId({ physicalId: prev.physicalId }) ? displaySafe(mask(prev.physicalId)) : "no recorded id";
|
|
29039
|
+
const unprovenCopyRefusal = (reason) => {
|
|
29040
|
+
const remedy = orphanRemedy(op.logicalId, ctx);
|
|
29041
|
+
return ownRemedyError(markNonRetryable(new CdkdError(safeMsg`Cannot reverse the replacement of ${shownLogicalId(op.logicalId)} (${refusalResourceType(op.resourceType)}): ` + reason + ` The retained old resource (${oldShown}) is named only by the rollback journal, so the JOURNAL is kept. Check both resources by hand.` + (remedy.offered ? ` To leave this one as it is, re-run ${rerunRollbackPhrase(ctx, "`cdkd rollback`")} with the command below; that also drops the journal's only record of the retained old resource (${oldShown}), so note that id first.` : ` No repair of the state record makes this op succeed on a re-run.`) + remedy.clause + remedy.line, STATE_RESOURCES_MALFORMED)));
|
|
29042
|
+
};
|
|
29043
|
+
const opIdUnusable = op.physicalId !== void 0 && !hasAddressablePhysicalId(op);
|
|
29044
|
+
if (!rollbackRetainsNewResource(current) && rollbackCannotAddress(current, op.resourceType, current.provisionedBy ?? op.provisionedBy, current.physicalId)) {
|
|
29045
|
+
if (opIdUnusable) throw unprovenCopyRefusal("neither its state record nor its rollback journal entry has a non-empty string 'physicalId' for the replacement's new resource, so cdkd cannot address that resource in AWS or tell which resource it is, and sent nothing.");
|
|
29046
|
+
const target = op.physicalId === void 0 ? void 0 : refusalPhysicalId(mask(String(op.physicalId)));
|
|
29047
|
+
const repair = target === void 0 ? `Repair the record's 'physicalId' to the id of the replacement's NEW resource (inspect it with \`cdkd state show\`): the journal does not record that id, and the re-run DELETES the resource the repaired record names as the new copy, so name the right one. Then re-run ${rerunRollbackPhrase(ctx, "`cdkd rollback`")}.` : `Repair the record's 'physicalId' to ${target}, the replacement's new resource the journal records (inspect it with \`cdkd state show\`); the re-run deletes it and re-adopts the old one. Any other id stops the revert and drops the journal's only record of the retained old resource (${oldShown}). Then re-run ${rerunRollbackPhrase(ctx, "`cdkd rollback`")}.` + (describedPhysicalIdPointer(target) !== "" ? " That id is left out of the prose above: it is not a plain identifier — read it from the rollback journal." : target.includes("***") ? ` That id is shown masked — read the full value from the rollback journal.` : "");
|
|
29048
|
+
throw new CdkdError(safeMsg`Cannot reverse the replacement of ${shownLogicalId(op.logicalId)} (${refusalResourceType(op.resourceType)}): ` + `its state record has no non-empty string 'physicalId', so cdkd cannot address the new resource in AWS to delete it, and sent nothing. The retained old resource (${oldShown}) is named only by the rollback journal, so the JOURNAL is kept. ` + repair, STATE_RESOURCES_MALFORMED);
|
|
29049
|
+
}
|
|
29050
|
+
if (!rollbackRetainsNewResource(current) && opIdUnusable && current.physicalId !== op.physicalId) throw unprovenCopyRefusal("its rollback journal entry has no non-empty string 'physicalId' for the replacement's new resource, so cdkd cannot tell whether the resource state records under this id is that one, and did not delete it; nothing was sent.");
|
|
28940
29051
|
logger.info(` Rollback: Reversing replacement of ${safe(op.logicalId)} (${safe(op.resourceType)}) — deleting the new resource and re-adopting the retained old one (${displaySafe(mask(prev.physicalId))})`);
|
|
28941
29052
|
let survivorReason;
|
|
29053
|
+
const survivorId = retainedSurvivorId(current, op);
|
|
28942
29054
|
if (rollbackRetainsNewResource(current)) {
|
|
28943
|
-
const survivorMessages = retainedSurvivorMessages(op.logicalId, op.resourceType,
|
|
29055
|
+
const survivorMessages = retainedSurvivorMessages(op.logicalId, op.resourceType, survivorId ?? "no recorded id", `State is restored to the old resource (${prev.physicalId}).`, mask);
|
|
28944
29056
|
logger.warn(survivorMessages.warn);
|
|
28945
29057
|
survivorReason = survivorMessages.reason;
|
|
28946
29058
|
result.warnings++;
|
|
@@ -28978,7 +29090,7 @@ async function replayReadopt(s) {
|
|
|
28978
29090
|
resourceType: op.resourceType,
|
|
28979
29091
|
...op.provisionedBy && { provisionedBy: op.provisionedBy },
|
|
28980
29092
|
...survivorReason !== void 0 && {
|
|
28981
|
-
physicalId:
|
|
29093
|
+
...survivorId !== void 0 && { physicalId: survivorId },
|
|
28982
29094
|
reason: mask(survivorReason),
|
|
28983
29095
|
...survivorProvisionedBy && { provisionedBy: survivorProvisionedBy }
|
|
28984
29096
|
}
|
|
@@ -29007,6 +29119,10 @@ async function replayRevert(s) {
|
|
|
29007
29119
|
recordRollbackSkip(s, op, ABSENT_BASELINE_SKIP_CAUSE);
|
|
29008
29120
|
return;
|
|
29009
29121
|
}
|
|
29122
|
+
if (rollbackCannotAddress(current, op.resourceType, op.provisionedBy, current.physicalId)) {
|
|
29123
|
+
skipUnaddressableReplay(s, logger, op, "restore");
|
|
29124
|
+
return;
|
|
29125
|
+
}
|
|
29010
29126
|
logger.info(` Rollback: Restoring ${safe(op.logicalId)} (${safe(op.resourceType)}) to previous state`);
|
|
29011
29127
|
const { provider, provisionedBy: revertVia } = ctx.providerRegistry.getProviderFor({
|
|
29012
29128
|
resourceType: op.resourceType,
|
|
@@ -29086,6 +29202,10 @@ async function replayReverseReplacement(s) {
|
|
|
29086
29202
|
recordRollbackSkip(s, op, ABSENT_BASELINE_SKIP_CAUSE);
|
|
29087
29203
|
return;
|
|
29088
29204
|
}
|
|
29205
|
+
if (!rollbackRetainsNewResource(current) && rollbackCannotAddress(current, op.resourceType, current.provisionedBy ?? op.provisionedBy, current.physicalId)) {
|
|
29206
|
+
skipUnaddressableReplay(s, logger, op, "reverse the replacement of");
|
|
29207
|
+
return;
|
|
29208
|
+
}
|
|
29089
29209
|
const resolvedPrevProps = await resolveReplayProps(prev.properties, resolver, secrets, ctx, op.logicalId) ?? {};
|
|
29090
29210
|
refuseMaskedReplayBaseline(resolvedPrevProps, op.logicalId);
|
|
29091
29211
|
opMasker.addNamed({
|
|
@@ -29228,8 +29348,9 @@ async function replayReverseReplacement(s) {
|
|
|
29228
29348
|
if (!adoptedLiveNewResource) inlinePolicyWriters.record(op.logicalId, "create", stateResources[op.logicalId], false, createProvisionedBy);
|
|
29229
29349
|
await afterOp?.(op.logicalId);
|
|
29230
29350
|
let survivorReason;
|
|
29351
|
+
const survivorId = retainedSurvivorId(current, op);
|
|
29231
29352
|
if (!deletedNewFirst && !adoptedLiveNewResource && rollbackRetainsNewResource(current)) {
|
|
29232
|
-
const survivorMessages = retainedSurvivorMessages(op.logicalId, op.resourceType,
|
|
29353
|
+
const survivorMessages = retainedSurvivorMessages(op.logicalId, op.resourceType, survivorId ?? "no recorded id", `State records the re-created old resource (${stateResources[op.logicalId]?.physicalId ?? prev.physicalId}).`, mask);
|
|
29233
29354
|
logger.warn(survivorMessages.warn);
|
|
29234
29355
|
survivorReason = survivorMessages.reason;
|
|
29235
29356
|
result.warnings++;
|
|
@@ -29261,7 +29382,7 @@ async function replayReverseReplacement(s) {
|
|
|
29261
29382
|
resourceType: op.resourceType,
|
|
29262
29383
|
...op.provisionedBy && { provisionedBy: op.provisionedBy },
|
|
29263
29384
|
...survivorReason !== void 0 && {
|
|
29264
|
-
physicalId:
|
|
29385
|
+
...survivorId !== void 0 && { physicalId: survivorId },
|
|
29265
29386
|
reason: mask(survivorReason),
|
|
29266
29387
|
...survivorProvisionedBy && { provisionedBy: survivorProvisionedBy }
|
|
29267
29388
|
},
|
|
@@ -29548,7 +29669,7 @@ async function replayFailedOperationsUnbound(failedOps, stateResources, stackNam
|
|
|
29548
29669
|
result.orphaned.push(orphaned);
|
|
29549
29670
|
options.onOrphan?.(orphaned);
|
|
29550
29671
|
}
|
|
29551
|
-
if (!
|
|
29672
|
+
if (!recordUnderIdIsNotOwn(op, stateResources)) delete stateResources[op.logicalId];
|
|
29552
29673
|
await noteRetainedResource(op.resourceType, op.logicalId);
|
|
29553
29674
|
logger.info(` Rollback: leaving partially-created ${safe(op.logicalId)} (${safe(op.resourceType)}) in AWS (DeletionPolicy: Retain)` + (failedCreateRecord ? " — removed from state" : " — it was never in state"));
|
|
29554
29675
|
await options.afterOp?.(op.logicalId);
|
|
@@ -29566,6 +29687,10 @@ async function replayFailedOperationsUnbound(failedOps, stateResources, stackNam
|
|
|
29566
29687
|
case "delete-failed-create-with-final-snapshot": {
|
|
29567
29688
|
const failedCreateRecord = failedOpOwnRecord(op, stateResources);
|
|
29568
29689
|
const deleteProvisionedBy = effectiveProvisionedBy(failedCreateRecord, op.provisionedBy);
|
|
29690
|
+
if (rollbackCannotAddress(failedCreateRecord, op.resourceType, deleteProvisionedBy, op.physicalId)) {
|
|
29691
|
+
skipUnaddressableReplay(skipScope, logger, op, "delete partially-created resource", failedCreateRecord ? "record" : "journal");
|
|
29692
|
+
break;
|
|
29693
|
+
}
|
|
29569
29694
|
createRollbackRoute = deleteProvisionedBy;
|
|
29570
29695
|
const snapshotPolicy = action === "delete-failed-create-with-final-snapshot";
|
|
29571
29696
|
const takeFinalSnapshot = snapshotPolicy && ctx.skipFinalSnapshot !== true;
|
|
@@ -29603,7 +29728,7 @@ async function replayFailedOperationsUnbound(failedOps, stateResources, stackNam
|
|
|
29603
29728
|
result.warnings++;
|
|
29604
29729
|
result.leftInPlace++;
|
|
29605
29730
|
}
|
|
29606
|
-
if (!
|
|
29731
|
+
if (!recordUnderIdIsNotOwn(op, stateResources)) delete stateResources[op.logicalId];
|
|
29607
29732
|
await options.afterOp?.(op.logicalId);
|
|
29608
29733
|
ctx.recordEvent?.({
|
|
29609
29734
|
eventType: "ROLLBACK_RESOURCE_SUCCEEDED",
|
|
@@ -29627,6 +29752,10 @@ async function replayFailedOperationsUnbound(failedOps, stateResources, stackNam
|
|
|
29627
29752
|
recordRollbackSkip(skipScope, op, ABSENT_BASELINE_SKIP_CAUSE);
|
|
29628
29753
|
break;
|
|
29629
29754
|
}
|
|
29755
|
+
if (rollbackCannotAddress(current, op.resourceType, op.provisionedBy ?? current.provisionedBy, current.physicalId)) {
|
|
29756
|
+
skipUnaddressableReplay(skipScope, logger, op, "force-revert failed UPDATE of");
|
|
29757
|
+
break;
|
|
29758
|
+
}
|
|
29630
29759
|
logger.info(` Rollback: force-reverting failed UPDATE of ${safe(op.logicalId)} (${safe(op.resourceType)}) to its pre-deploy properties (--revert-failed; remote state is unknown)`);
|
|
29631
29760
|
const { provider, provisionedBy: revertVia } = ctx.providerRegistry.getProviderFor({
|
|
29632
29761
|
resourceType: op.resourceType,
|
|
@@ -29703,7 +29832,7 @@ async function replayFailedOperationsUnbound(failedOps, stateResources, stackNam
|
|
|
29703
29832
|
error: maskedRollbackEventError(revertError, mask)
|
|
29704
29833
|
});
|
|
29705
29834
|
}
|
|
29706
|
-
inlinePolicyWriters.noteOutcome(op, action === "skip-failed-noop" || action === "skip-failed-mismatch" || action === "skip-failed-superseded" || action === "skip-failed-replaced-deleted" || ownRecord(stateResources, op.logicalId) !== recordBefore ||
|
|
29835
|
+
inlinePolicyWriters.noteOutcome(op, action === "skip-failed-noop" || action === "skip-failed-mismatch" || action === "skip-failed-superseded" || action === "skip-failed-replaced-deleted" || ownRecord(stateResources, op.logicalId) !== recordBefore || recordUnderIdIsNotOwn(op, stateResources) && !pending.has(op) && (action === "delete-failed-create" || action === "delete-failed-create-with-final-snapshot" || action === "orphan-failed-create-retain"));
|
|
29707
29836
|
}
|
|
29708
29837
|
if (result.interrupted) await restoreHeldInlinePolicies(inlinePolicyWriters, stateResources, stackName, ctx, result, { refuseAll: true });
|
|
29709
29838
|
if (emitEnvelope) ctx.recordEvent?.({
|
|
@@ -30313,7 +30442,7 @@ async function settleJournaledOrphansOnSuccess(args) {
|
|
|
30313
30442
|
logger.info(safeMsg`The rollback journal of stack ${stack} records ${all.length} resource(s) a failed deploy ` + `created that no state record holds; acting on them per their DeletionPolicy before the journal is removed:`);
|
|
30314
30443
|
for (const line of journaledOrphanLines(orphans, logger)) logger.info(line);
|
|
30315
30444
|
try {
|
|
30316
|
-
const { unreadable, tracked } = await applySuccessRule(orphans, stateResources, orphans.deployLogicalIds ?? /* @__PURE__ */ new Set(), args.foreignHolder, stack, logger, args.isInterrupted);
|
|
30445
|
+
const { unreadable, tracked } = await applySuccessRule(orphans, stateResources, orphans.deployLogicalIds ?? /* @__PURE__ */ new Set(), args.foreignHolder, stack, logger, args.isInterrupted, ctx);
|
|
30317
30446
|
const acting = {
|
|
30318
30447
|
segments: orphans.segments.map(({ segment, ops }) => ({
|
|
30319
30448
|
segment,
|
|
@@ -30372,7 +30501,7 @@ async function settleJournaledOrphansOnSuccess(args) {
|
|
|
30372
30501
|
keepJournal: true
|
|
30373
30502
|
};
|
|
30374
30503
|
}
|
|
30375
|
-
async function applySuccessRule(orphans, stateResources, deployLogicalIds, foreignHolder, stack, logger, isInterrupted) {
|
|
30504
|
+
async function applySuccessRule(orphans, stateResources, deployLogicalIds, foreignHolder, stack, logger, isInterrupted, identityCtx) {
|
|
30376
30505
|
const unreadable = /* @__PURE__ */ new Set();
|
|
30377
30506
|
const tracked = /* @__PURE__ */ new Set();
|
|
30378
30507
|
let interrupted = false;
|
|
@@ -30387,9 +30516,20 @@ async function applySuccessRule(orphans, stateResources, deployLogicalIds, forei
|
|
|
30387
30516
|
tracked.add(op);
|
|
30388
30517
|
continue;
|
|
30389
30518
|
}
|
|
30390
|
-
|
|
30391
|
-
|
|
30392
|
-
|
|
30519
|
+
const hasRecord = Object.prototype.hasOwnProperty.call(stateResources, op.logicalId);
|
|
30520
|
+
const record = hasRecord ? stateResources[op.logicalId] : void 0;
|
|
30521
|
+
const recordUnderId = hasRecord && !isReplacedRecord(op, record);
|
|
30522
|
+
if (recordUnderId || deployLogicalIds.has(op.logicalId)) {
|
|
30523
|
+
const verdict = recordUnderId ? await recordIdentity(op, record, identityCtx, logger) : "unknown";
|
|
30524
|
+
if (verdict === "same") {
|
|
30525
|
+
tracked.add(op);
|
|
30526
|
+
continue;
|
|
30527
|
+
}
|
|
30528
|
+
if (verdict !== "different") {
|
|
30529
|
+
op.physicalIdRecoveredFromError = false;
|
|
30530
|
+
continue;
|
|
30531
|
+
}
|
|
30532
|
+
markProvenDistinctFromRecord(op, record);
|
|
30393
30533
|
}
|
|
30394
30534
|
const holding = await foreignHolder(op.resourceType, op.physicalId);
|
|
30395
30535
|
if (holding === void 0) continue;
|
|
@@ -30406,6 +30546,23 @@ async function applySuccessRule(orphans, stateResources, deployLogicalIds, forei
|
|
|
30406
30546
|
tracked
|
|
30407
30547
|
};
|
|
30408
30548
|
}
|
|
30549
|
+
async function recordIdentity(op, record, ctx, logger) {
|
|
30550
|
+
if (typeof record !== "object" || record === null || record.resourceType !== op.resourceType || typeof record.physicalId !== "string" || record.physicalId === "" || !op.physicalId) return "unknown";
|
|
30551
|
+
try {
|
|
30552
|
+
const { provider } = ctx.providerRegistry.getProviderFor({
|
|
30553
|
+
resourceType: op.resourceType,
|
|
30554
|
+
provisionedBy: op.provisionedBy
|
|
30555
|
+
});
|
|
30556
|
+
if (typeof provider.isSameResource !== "function") return "unknown";
|
|
30557
|
+
return await provider.isSameResource(op.physicalId, {
|
|
30558
|
+
physicalId: record.physicalId,
|
|
30559
|
+
...record.provisionedBy !== void 0 && { provisionedBy: record.provisionedBy }
|
|
30560
|
+
}, op.resourceType, { expectedRegion: ctx.region });
|
|
30561
|
+
} catch (err) {
|
|
30562
|
+
logger.debug(safeMsg`Could not compare ${logicalIdShown(op.logicalId)}'s journaled resource with its state record (${displaySafe(err instanceof Error ? err.name : typeof err)}).`);
|
|
30563
|
+
return "unknown";
|
|
30564
|
+
}
|
|
30565
|
+
}
|
|
30409
30566
|
function makeForeignHolderScan(stateBackend) {
|
|
30410
30567
|
let scan;
|
|
30411
30568
|
const key = (type, id) => JSON.stringify([type, id]);
|
|
@@ -31307,7 +31464,7 @@ function redactParametersForDiff(parameterValues) {
|
|
|
31307
31464
|
const inherited = this.options.inheritedSecrets;
|
|
31308
31465
|
if (!inherited || inherited.size === 0) return parameterValues;
|
|
31309
31466
|
const out = Object.create(null);
|
|
31310
|
-
for (const [name, value] of Object.entries(parameterValues)) out[name] =
|
|
31467
|
+
for (const [name, value] of Object.entries(parameterValues)) out[name] = redactInheritedParameterValue(inherited, name, value);
|
|
31311
31468
|
return out;
|
|
31312
31469
|
}
|
|
31313
31470
|
function rememberRecoverableMaskedOutputs(stackName, resolved, redacted) {
|
|
@@ -31527,7 +31684,7 @@ async function replaceDeleteFirstAndRecreate(logicalId, resourceType, oldResourc
|
|
|
31527
31684
|
recordedAttributes: currentResource.attributes
|
|
31528
31685
|
});
|
|
31529
31686
|
} catch (deleteError) {
|
|
31530
|
-
throw new Error(maskSecretsInText(`Failed to delete old resource ${logicalId} (${currentResource.physicalId}) during the --replace delete-first fallback: ${deleteError instanceof Error ? deleteError.message : String(deleteError)}`, secrets));
|
|
31687
|
+
throw new Error(maskSecretsInText(`Failed to delete old resource ${logicalId} (${currentResource.physicalId}) during the --replace delete-first fallback: ${deleteError instanceof Error ? deleteError.message : String(deleteError)}`, secrets), { cause: deleteError instanceof Error ? maskSecretsInError(deleteError, secrets) : void 0 });
|
|
31531
31688
|
}
|
|
31532
31689
|
reportDeleteGuards(deleteResult, {
|
|
31533
31690
|
physicalId: currentResource.physicalId,
|
|
@@ -31550,7 +31707,7 @@ async function replaceDeleteFirstAndRecreate(logicalId, resourceType, oldResourc
|
|
|
31550
31707
|
isRetryable: isRecreateRetryableError
|
|
31551
31708
|
});
|
|
31552
31709
|
} catch (recreateError) {
|
|
31553
|
-
throw new Error(maskSecretsInText(`Failed to re-create ${logicalId} after the --replace delete-first fallback already deleted the old resource (${currentResource.physicalId}): ${recreateError instanceof Error ? recreateError.message : String(recreateError)}. Re-run the deploy to create it fresh.`, secrets), { cause: recreateError instanceof Error ? recreateError : void 0 });
|
|
31710
|
+
throw new Error(maskSecretsInText(`Failed to re-create ${logicalId} after the --replace delete-first fallback already deleted the old resource (${currentResource.physicalId}): ${recreateError instanceof Error ? recreateError.message : String(recreateError)}. Re-run the deploy to create it fresh.`, secrets), { cause: recreateError instanceof Error ? maskSecretsInError(recreateError, secrets) : void 0 });
|
|
31554
31711
|
}
|
|
31555
31712
|
}
|
|
31556
31713
|
function typeChangeNameQuestion(resourceType, input) {
|
|
@@ -35234,7 +35391,7 @@ async function updateByReplacement({ change, counts, currentProps, currentResour
|
|
|
35234
35391
|
recordedAttributes: currentResource.attributes
|
|
35235
35392
|
});
|
|
35236
35393
|
} catch (deleteError) {
|
|
35237
|
-
throw new Error(`Failed to destroy old resource ${logicalId} (${currentResource.physicalId}) during ${recreateFlagName}: ${deleteError instanceof Error ? deleteError.message : String(deleteError)}
|
|
35394
|
+
throw new Error(maskSecretsInText(`Failed to destroy old resource ${logicalId} (${currentResource.physicalId}) during ${recreateFlagName}: ${deleteError instanceof Error ? deleteError.message : String(deleteError)}`, updateSecrets), { cause: deleteError instanceof Error ? maskSecretsInError(deleteError, updateSecrets) : void 0 });
|
|
35238
35395
|
}
|
|
35239
35396
|
reportDeleteGuards(recreateDeleteResult, {
|
|
35240
35397
|
physicalId: currentResource.physicalId,
|
|
@@ -37947,5 +38104,5 @@ DeployEngine.prototype.replacementNameOrigin = replacementNameOrigin;
|
|
|
37947
38104
|
DeployEngine.prototype.orphanedNameCollisionAdvice = orphanedNameCollisionAdvice;
|
|
37948
38105
|
|
|
37949
38106
|
//#endregion
|
|
37950
|
-
export { resourcesNamingDeclaredParameter as $, createSecretMasker as $a, repairMalformedResourceEntriesForReadOnly as $i, deleteSkipReason as $n, ensureAssetStorage as $o, deployRefusesOrphanRowsReason as $r, derivePartitionAndUrlSuffix as $s, effectiveDeletionPolicy as $t, resolveDynamoDbDeleteBudgetClock as A, requireConfigObject as Aa, refuseMalformedOrphans as Ai, acquireIdempotencyToken as An, acceptedCreateOnlyDropsOf as Ao, s3BucketWebsiteUrl as Ar, getDefaultStateBucketName as As, planRollback as At, getPriorAttempts as B, TemplateParser as Ba, refuseMalformedResourceEntriesForImportSave as Bi, CC_BROKEN_REASON as Bn, orphansCarriedFrom as Bo, AWS_NO_VALUE as Br, stateBucketExistenceConfirmed as Bs, updatePartialMessage as Bt, perType as C, coerceCfnInteger as Ca, malformedScrubResourceEntriesRefusalMessage as Ci, findDestructiveChanges as Cn, WHOLE_DYNAMIC_REFERENCE_PATTERN as Co, callerEnvCredentials as Cr, warnFinchArgvExposure as Cs, getStackRecords as Ct, beginDeleteWait as D, readConfigString as Da, refuseMalformedNestedChildOutputs as Di, ledgerForStack as Dn, S3StateBackend as Do, s3BucketDomainName as Dr, getDockerImageBySourceHash as Ds, isJournaledOrphan as Dt, DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS as E, configStringRefusal as Ea, refuseDivergentRecordRegionForDestroy as Ei, earliestDefined as En, isLockInfoExpired as Eo, s3BucketArn as Er, AssetManifestLoader as Es, demoteSupersededOrphans as Et, waitForIndexesSettled as F, withRetry as Fa, refuseMalformedResourceAttributesForOrphan as Fi, refuseMalformedDesiredTags as Fn, hasUnverifiableParameterRefusal as Fo, isImpossibleEmptyStoredAttribute as Fr, resolveCaptureObservedState as Fs, inheritProducerRegions as Ft, cyan as G, createUnionSecretMasker as Ga, refuseMalformedResourcePropertiesForOrphan as Gi, getCurrentResourceSecrets as Gn, WorkGraph as Go, withSharedDrainBudget as Gr, MIGRATE_TMP_PREFIX as Gs, orphanRecordsPrintingBag as Gt, formatResourceLine as H, inheritNestedStackParameterAssociations as Ha, refuseMalformedResourcePropertiesForDestroy as Hi, ccBrokenReason as Hn, AssetPublisher as Ho, isStalePlaceholderArnAttribute as Hr, ssmResolvedValueType as Hs, completedReplayEntries as Ht, ECR_AUTO_DELETE_IMAGES_TAG as I, canonicalLambdaFunctionName as Ia, refuseMalformedResourceEntries as Ii, tagMapAsList as In, importableOutputKeys as Io, carriesDynamicReference as Ir, resolveSkipPrefix as Is, REDACTED_DELETE_ADDRESS_SKIP_REASON as It, red as J, logOnlyValueCount as Ja, refuseMalformedResourcesForExport as Ji, slowCcOperationTimeoutMs as Jn, loadPublishableAssetManifest as Jo, JSON_LISTING_HOLE_VALUE as Jr, CUSTOM_RESOURCE_RESPONSE_OBJECT_DESCRIPTION as Js, ATOMIC_FINAL_SNAPSHOT_TYPES as Jt, gray as K, hasMaskableValues as Ka, refuseMalformedResourcesForDeploy as Ki, withPrintingSecrets as Kn, buildAssetRedirectMap as Ko, parameterInputsFor as Kr, findLargeInlineResources as Ks, secretNamePrintingBag as Kt, S3_AUTO_DELETE_OBJECTS_TAG as L, lambdaFunctionNameForMask as La, refuseMalformedResourceEntriesForDeploy as Li, tagPlanWarning as Ln, importableOutputs as Lo, carriesFetchableDynamicReference as Lr, resolveStateBucketWithDefault as Ls, isRedactedRecordedValue as Lt, DELETE_INDEX_WAIT_PROCEED_NOTE as M, prefetchCreateOnlyPropertyPaths as Ma, refuseMalformedOrphansForOrphan as Mi, DBPROXY_TAG_OPTIONS as Mn, exportNamesCarriedFrom as Mo, isUnboundTemplateParameter as Mr, loadCdkJson as Ms, resolveReplacementOldType as Mt, INDEX_SETTLE_POLL_INTERVAL_MS as N, templateResourceTypes as Na, refuseMalformedOutputs as Ni, planTagDiff as Nn, hasReadableExportSet as No, parameterTypeMayLoseSecretIdentity as Nr, resolveApp as Ns, findNestedStackTypeChanges as Nt, compensateRemovedDeletionProtection as O, replayWarn as Oa, refuseMalformedOrphanRecords as Oi, reserveStackCreateToken as On, rebuildClientForBucketRegion as Oo, s3BucketDualStackDomainName as Or, Synthesizer as Os, isReplacementOrphan as Ot, deleteTableWithIndexBusyRetry as P, describeTypeWithThrottleRetry as Pa, refuseMalformedOutputsForDestroy as Pi, readTagList as Pn, hasReasonlessBaselineRefusal as Po, getAccountInfo as Pr, resolveAutoAssetStorage as Ps, getCurrentProducerRegions as Pt, reachableDivergentParameters as Q, shareLogOnlyValues as Qa, repairMalformedOutputsForReadOnly as Qi, deleteIndeterminateGuards as Qn, assertAssetBucketRegion as Qo, UNREADABLE_RESOURCES_MAP_ROW as Qr, canonicalizeRegion as Qs, createPreDeleteFinalSnapshot as Qt, hasCdkAutoDeleteTag as R, sameLambdaFunctionAddress as Ra, refuseMalformedResourceEntriesForDestroy as Ri, definedAttributes as Rn, isReadableBag as Ro, isNamelessDynamicReferenceError as Rr, resolveStateBucketWithDefaultAndSource as Rs, redactedDeleteAddressFields as Rt, isProtectionValueActive as S, coerceCfnBoolean as Sa, malformedResourcesWarning as Si, constructPathOf as Sn, TEMPLATE_SOURCED_RULES as So, applyCallerIdentityCredentials as Sr, runDockerStreaming as Ss, destroyStackRecordsView as St, DynamoDBGlobalTableProvider as T, configIntegerRefusal as Ta, previewableOrphanRecords as Ti, RollbackInlinePolicyWriters as Tn, LockManager as To, isSettledInstanceState as Tr, stripControlChars as Ts, recordAfterRollbackUpdate as Tt, createReadOnlyAttributeHealerFactory as U, recordNestedStackParameterExpressions as Ua, refuseMalformedResourcePropertiesForDrift as Ui, wouldReturnToSdkProvider as Un, isSensitiveAttributeName as Uo, refStateLookupFromResource as Ur, CFN_TEMPLATE_BODY_LIMIT as Us, journaledOrphanPrintingBag as Ut, markRefusedBeforeApplying as V, liveMatchesUnresolvedTokenFrame as Va, refuseMalformedResourceEntriesForOrphan as Vi, ProviderRegistry as Vn, shouldRetainResource as Vo, cfnRefValueFromPhysicalId as Vr, warnDeprecatedNoPrefixCliFlag as Vs, updatePartialReason as Vt, bold as W, carryLogOnlyValues as Wa, refuseMalformedResourcePropertiesForExport as Wi, isCustomResourceType as Wn, stringifyValue as Wo, parseWebACLArn as Wr, CFN_TEMPLATE_URL_LIMIT as Ws, maskEventTextWithBoundBags as Wt, computeParameterTaint as X, recordLogOnlyParameterValue as Xa, repairMalformedOrphanRecordsForReadOnly as Xi, unchangedBehindSecretReference as Xn, AssetModeResolver as Xo, STATE_RESOURCES_MALFORMED as Xr, expectedOwnerParam as Xs, buildFinalSnapshotIdentifier as Xt, yellow as Y, printingCorpusOf as Ya, refuseMalformedState as Yi, ccProtectionRegistryTypes as Yn, rewriteTemplateAssetReferences as Yo, STATE_REGION_DIVERGED as Yr, decodeListingKey as Ys, PRE_DELETE_SNAPSHOT_TYPES as Yt, namesAnyDeclaredParameter as Z, recordLogOnlyValue as Za, repairMalformedOrphansForReadOnly as Zi, UNSPECIFIED_SKIP_REASON as Zn, BOOTSTRAP_MARKER_PREFIX as Zo, UNREADABLE_ORPHANS_CONTAINER_ROW as Zr, PARTITION_TABLE as Zs, ccRoutedFinalSnapshotError as Zt, makeCanonicalizePropertiesFn as _, WARM_THROUGHPUT_MEMBERS as _a, malformedOutputsRefusalMessage as _i, isExportAliasCollision as _n, recordProvenPublicExpression as _o, assertSendableRoleArn as _r, isMalformedEnvKey as _s, getCurrentNestedStackContext as _t, findNestedTemplateTreeDefect as a, findActionableSilentDrops as aa, hasPlainPrototype$1 as ac, isReadableResourceEntry as ai, extractDeploymentEventError as an, scrubResourceRecord as ao, isTerminationProtectionPropagationError as ar, validateContainerRepoName as as, makeSiblingClaimReader as at, recordedProtectionNote as b, toCfnInteger as ba, malformedResourceEntriesWarning as bi, DEFAULT_RESOURCE_WARN_AFTER_MS as bn, STATE_SOURCED_CROSS_GENERATION_RULES as bo, sendableAssumeRoleCommand as br, redactedDockerCause as bs, replayRollback as bt, renderNestedTemplateTreeDefect as c, withoutSilentDropProperties as ca, absoluteAssemblyPathEscape as cc, malformedExportSourceWarning as ci, exportAliasCollisionScrubWarning as cn, dynamicReferenceTokens as co, reEnableInstanceApiTermination as cr, resolveDockerContextDirectory as cs, displacedOpClause as ct, conditionInputsFrom as d, findReplacedReadersOfRecreateTargets as da, renderAssemblyPathEscape as dc, malformedLocalResourcesWarning as di, secretSafeKeyDisplay as dn, identityKeyFor as do, IntrinsicFunctionResolver as dr, describeDockerFailure as ds, getNestedRevertRun as dt, repairMalformedResourcePropertiesForReadOnly as ea, AssemblyReader as ec, displayLogicalId as ei, isFinalSnapshotError as en, errorCauseChain as eo, withIndeterminateGuard as er, getBootstrapMarkerKey as es, deleteJournaledOrphans as et, parentSuppliedValues as f, shownType as fa, resolveAssemblyPath as fc, malformedOrphanRecordsRefusalMessage as fi, exportNameSecretExposure as fn, carriesSecretMask as fo, classifyReplaySecretRegion as fr, dockerSpawnEnvWithSensitive as fs, nestedChildStackName as ft, mergeNoChangeOutputs as g, renderStatefulReason as ga, malformedOrphansWarning as gi, collectPublishedOutputNames as gn, recordNoEchoAttributeValues as go, assertFlagRoleArn as gr, isDockerClientEnvKey as gs, withNestedRevertRun as gt, keptWholeReasonText as h, isStatefulRecreateTargetSync as ha, malformedOrphansRefusalMessage as hi, collectDeclaredOutputNames as hn, recordMaskOnlyValuesIn as ho, applyRoleArnIfSet as hr, getDockerCmd as hs, revertedNestedRowIds as ht, childTemplateLoader as i, unreadableResourceEntries as ia, hasOwnKey as ic, isReadableOrphanRecord as ii, DeploymentEventsStore as in, redactSecretsForState as io, ec2InstanceProtectionSite as ir, validateAssetBucketName as is, sameJournaledOrphans as it, resolveDynamoDbDeleteBudgetMs as j, requireConfigString as ja, refuseMalformedOrphansForDestroy as ji, DBPROXY_TAGS_WHAT as jn, describeRegionValueKind as jo, coerceParameterTypedValue as jr, getLegacyStateBucketName as js, replacementNeverSwapped as jt, deleteBudgetKey as k, requireConfigArray as ka, refuseMalformedOrphanRecordsForDestroy as ki, withCreateTokenLedger as kn, splitImportedOps as ko, s3BucketRegionalDomainName as kr, synthesisStatusMessage as ks, planFailedOps as kt, templateIdentity as l, NO_CC_HANDLERS_REASON as la, describeFileReadFailure as lc, malformedLocalOutputsWarning as li, secretBearing as ln, isUncertifiedBaselineMaskPosition as lo, DiffCalculator as lr, describeDockerCapturedOutput as ls, displacedPhysicalIdShown as lt, isSecretBearingReferenceString as m, isStatefulRecreateTargetForReplace as ma, resolveBucketRegion as mc, malformedOrphanRowsKeptWarning as mi, noEchoParameterValueSeed as mn, recordMaskOnlyValue as mo, regionLessSecretName as mr, formatDockerLoginError as ms, revertNestedChildFromJournal as mt, IMPLICIT_DELETE_DEPENDENCIES as n, unpreviewableOrphanRecords as na, processStackMessages as nc, hasReadableOutputs as ni, unsupportedFinalSnapshotError as nn, maskSecretsInText as no, markWaitAbandoned as nr, parseBootstrapMarker as ns, journaledOrphanLines as nt, isAbsoluteAssetPath as o, findSilentDropProperties as oa, nullPrototypeRecord as oc, malformedDriftResourcePropertiesWarning as oi, WITHHELD_NAME_DISPLAY as on, recoverMaskedOutput as oo, observeThenDisableInstanceApiTermination as or, buildDenyExternalAccessPolicy as os, planOrphanAdoption as ot, readRecordedConditionVerdicts as p, MULTI_REGION_RECREATE_BLOCKED_TYPES as pa, clearBucketRegionCache as pc, malformedOrphanRecordsWarning as pi, isWholeDynamicReferenceValue as pn, provenPublicValue as po, producerRegionsFromState as pr, finchSecretArgvRefusal as ps, recordDisplacedSkips as pt, green as q, literalSplitDelimitersOf as qa, refuseMalformedResourcesForDestroy as qi, CloudControlProvider as qn, createAssetRedirectResolver as qo, passedParameterClassesOf as qr, uploadCfnTemplate as qs, stateSecretNameNeedles as qt, computeImplicitDeleteEdges as r, unreadableOrphanRecords as ra, defineOwnKey as rc, hasReadableResources as ri, DeploymentEventsReader as rn, markSameGenerationBag as ro, disableInstanceApiTermination as rr, readBootstrapMarkerBody as rs, loadJournaledOrphans as rt, listNestedTemplateRows as s, unwrittenCreateOnlyReplacement as sa, ownValue as sc, malformedExportNamesWarning as si, displayTextOrWithheld as sn, DYNAMIC_REFERENCE_TOKEN_SCAN as so, reDisableInstanceApiTermination as sr, buildDockerImage as ss, NESTED_PENDING_PARENT_REASON as st, DeployEngine as t, repairMalformedResourcesForReadOnly as ta, StageLoadError as tc, hasReadableOrphans as ti, refusesFinalSnapshot as tn, maskSecretsInError as to, isWaitAbandonedError as tr, isCrossRegionRedirect as ts, isHandledOrphan as tt, conditionFingerprint as u, hasNoCloudControlHandlers as ua, displayAssemblyPath as uc, malformedLocalResourceEntriesWarning as ui, secretBearingStateKeyWarning as un, pathCrossesDottedKey as uo, INTRINSIC_KEYS as ur, describeDockerExecFailure as us, dropSettledNestedJournals as ut, withResourceDeadline as v, coerceWarmThroughput as va, malformedOutputsWarning as vi, bindingSkippedOutputs as vn, wholeStringLeavesOf as vo, explicitRoleArnOrThrow as vr, partitionSensitiveEnv as vs, withNestedStackContext as vt, readProtection as w, configBooleanRefusal as wa, malformedStateRefusalMessage as wi, formatDestructiveChange as wn, isSingleDynamicReferenceToken as wo, envCredentialsAreAssumedRole as wr, escapeRegExp$3 as ws, withStackRecords as wt, PROTECTION_PROPERTY_BY_TYPE as x, toFiniteNumber as xa, malformedResourcePropertiesWarning as xi, maskingRetryLogger as xn, STATE_SOURCED_READBACK_RULES as xo, AWS_CREDENTIAL_ENV_KEYS as xr, runDockerForeground as xs, awaitInFlightSibling as xt, recordedProtectionEvidence as y, isWarmThroughputDecrease as ya, malformedRenderedContainersWarning as yi, DEFAULT_RESOURCE_TIMEOUT_MS as yn, STATE_SOURCED_BASELINE_RULES as yo, isIamRoleArn as yr, redactDockerArgvValues as ys, replayFailedOperations as yt, isTruthyCfnBoolean as z, DagBuilder as za, refuseMalformedResourceEntriesForImport as zi, stringifyIfAssigned as zn, orphansAfterRollback as zo, keepsSecretReferenceToken as zr, resolveUseCdkBootstrapAssets as zs, redactedDeleteAddressSkip as zt };
|
|
37951
|
-
//# sourceMappingURL=deploy-engine-
|
|
38107
|
+
export { resourcesNamingDeclaredParameter as $, maskSecretsInError as $a, repairMalformedResourceEntriesForReadOnly as $i, deleteSkipReason as $n, ensureAssetStorage as $o, deployRefusesOrphanRowsReason as $r, derivePartitionAndUrlSuffix as $s, effectiveDeletionPolicy as $t, resolveDynamoDbDeleteBudgetClock as A, requireConfigObject as Aa, refuseMalformedOrphans as Ai, acquireIdempotencyToken as An, acceptedCreateOnlyDropsOf as Ao, s3BucketWebsiteUrl as Ar, getDefaultStateBucketName as As, planRollback as At, getPriorAttempts as B, TemplateParser as Ba, refuseMalformedResourceEntriesForImportSave as Bi, CC_BROKEN_REASON as Bn, orphansCarriedFrom as Bo, AWS_NO_VALUE as Br, stateBucketExistenceConfirmed as Bs, updatePartialMessage as Bt, perType as C, coerceCfnInteger as Ca, malformedScrubResourceEntriesRefusalMessage as Ci, findDestructiveChanges as Cn, WHOLE_DYNAMIC_REFERENCE_PATTERN as Co, callerEnvCredentials as Cr, warnFinchArgvExposure as Cs, getStackRecords as Ct, beginDeleteWait as D, readConfigString as Da, refuseMalformedNestedChildOutputs as Di, ledgerForStack as Dn, S3StateBackend as Do, s3BucketDomainName as Dr, getDockerImageBySourceHash as Ds, isJournaledOrphan as Dt, DYNAMODB_DELETE_MIN_RESOURCE_TIMEOUT_MS as E, configStringRefusal as Ea, refuseDivergentRecordRegionForDestroy as Ei, earliestDefined as En, isLockInfoExpired as Eo, s3BucketArn as Er, AssetManifestLoader as Es, demoteSupersededOrphans as Et, waitForIndexesSettled as F, withRetry as Fa, refuseMalformedResourceAttributesForOrphan as Fi, refuseMalformedDesiredTags as Fn, hasUnverifiableParameterRefusal as Fo, isImpossibleEmptyStoredAttribute as Fr, resolveCaptureObservedState as Fs, inheritProducerRegions as Ft, cyan as G, literalSplitDelimitersOf as Ga, refuseMalformedResourcePropertiesForOrphan as Gi, getCurrentResourceSecrets as Gn, WorkGraph as Go, withSharedDrainBudget as Gr, MIGRATE_TMP_PREFIX as Gs, orphanRecordsPrintingBag as Gt, formatResourceLine as H, carryLogOnlyValues as Ha, refuseMalformedResourcePropertiesForDestroy as Hi, ccBrokenReason as Hn, AssetPublisher as Ho, isStalePlaceholderArnAttribute as Hr, ssmResolvedValueType as Hs, completedReplayEntries as Ht, ECR_AUTO_DELETE_IMAGES_TAG as I, canonicalLambdaFunctionName as Ia, refuseMalformedResourceEntries as Ii, tagMapAsList as In, importableOutputKeys as Io, carriesDynamicReference as Ir, resolveSkipPrefix as Is, REDACTED_DELETE_ADDRESS_SKIP_REASON as It, red as J, recordLogOnlyParameterValue as Ja, refuseMalformedResourcesForExport as Ji, slowCcOperationTimeoutMs as Jn, loadPublishableAssetManifest as Jo, JSON_LISTING_HOLE_VALUE as Jr, CUSTOM_RESOURCE_RESPONSE_OBJECT_DESCRIPTION as Js, ATOMIC_FINAL_SNAPSHOT_TYPES as Jt, gray as K, logOnlyValueCount as Ka, refuseMalformedResourcesForDeploy as Ki, withPrintingSecrets as Kn, buildAssetRedirectMap as Ko, parameterInputsFor as Kr, findLargeInlineResources as Ks, secretNamePrintingBag as Kt, S3_AUTO_DELETE_OBJECTS_TAG as L, lambdaFunctionNameForMask as La, refuseMalformedResourceEntriesForDeploy as Li, tagPlanWarning as Ln, importableOutputs as Lo, carriesFetchableDynamicReference as Lr, resolveStateBucketWithDefault as Ls, isRedactedRecordedValue as Lt, DELETE_INDEX_WAIT_PROCEED_NOTE as M, prefetchCreateOnlyPropertyPaths as Ma, refuseMalformedOrphansForOrphan as Mi, DBPROXY_TAG_OPTIONS as Mn, exportNamesCarriedFrom as Mo, isUnboundTemplateParameter as Mr, loadCdkJson as Ms, resolveReplacementOldType as Mt, INDEX_SETTLE_POLL_INTERVAL_MS as N, templateResourceTypes as Na, refuseMalformedOutputs as Ni, planTagDiff as Nn, hasReadableExportSet as No, parameterTypeMayLoseSecretIdentity as Nr, resolveApp as Ns, findNestedStackTypeChanges as Nt, compensateRemovedDeletionProtection as O, replayWarn as Oa, refuseMalformedOrphanRecords as Oi, reserveStackCreateToken as On, rebuildClientForBucketRegion as Oo, s3BucketDualStackDomainName as Or, Synthesizer as Os, isReplacementOrphan as Ot, deleteTableWithIndexBusyRetry as P, describeTypeWithThrottleRetry as Pa, refuseMalformedOutputsForDestroy as Pi, readTagList as Pn, hasReasonlessBaselineRefusal as Po, getAccountInfo as Pr, resolveAutoAssetStorage as Ps, getCurrentProducerRegions as Pt, reachableDivergentParameters as Q, errorCauseChain as Qa, repairMalformedOutputsForReadOnly as Qi, deleteIndeterminateGuards as Qn, assertAssetBucketRegion as Qo, UNREADABLE_RESOURCES_MAP_ROW as Qr, canonicalizeRegion as Qs, createPreDeleteFinalSnapshot as Qt, hasCdkAutoDeleteTag as R, sameLambdaFunctionAddress as Ra, refuseMalformedResourceEntriesForDestroy as Ri, definedAttributes as Rn, isReadableBag as Ro, isNamelessDynamicReferenceError as Rr, resolveStateBucketWithDefaultAndSource as Rs, redactedDeleteAddressFields as Rt, isProtectionValueActive as S, coerceCfnBoolean as Sa, malformedResourcesWarning as Si, constructPathOf as Sn, TEMPLATE_SOURCED_RULES as So, applyCallerIdentityCredentials as Sr, runDockerStreaming as Ss, destroyStackRecordsView as St, DynamoDBGlobalTableProvider as T, configIntegerRefusal as Ta, previewableOrphanRecords as Ti, RollbackInlinePolicyWriters as Tn, LockManager as To, isSettledInstanceState as Tr, stripControlChars as Ts, recordAfterRollbackUpdate as Tt, createReadOnlyAttributeHealerFactory as U, createUnionSecretMasker as Ua, refuseMalformedResourcePropertiesForDrift as Ui, wouldReturnToSdkProvider as Un, isSensitiveAttributeName as Uo, refStateLookupFromResource as Ur, CFN_TEMPLATE_BODY_LIMIT as Us, journaledOrphanPrintingBag as Ut, markRefusedBeforeApplying as V, liveMatchesUnresolvedTokenFrame as Va, refuseMalformedResourceEntriesForOrphan as Vi, ProviderRegistry as Vn, shouldRetainResource as Vo, cfnRefValueFromPhysicalId as Vr, warnDeprecatedNoPrefixCliFlag as Vs, updatePartialReason as Vt, bold as W, hasMaskableValues as Wa, refuseMalformedResourcePropertiesForExport as Wi, isCustomResourceType as Wn, stringifyValue as Wo, parseWebACLArn as Wr, CFN_TEMPLATE_URL_LIMIT as Ws, maskEventTextWithBoundBags as Wt, computeParameterTaint as X, shareLogOnlyValues as Xa, repairMalformedOrphanRecordsForReadOnly as Xi, unchangedBehindSecretReference as Xn, AssetModeResolver as Xo, STATE_RESOURCES_MALFORMED as Xr, expectedOwnerParam as Xs, buildFinalSnapshotIdentifier as Xt, yellow as Y, recordLogOnlyValue as Ya, refuseMalformedState as Yi, ccProtectionRegistryTypes as Yn, rewriteTemplateAssetReferences as Yo, STATE_REGION_DIVERGED as Yr, decodeListingKey as Ys, PRE_DELETE_SNAPSHOT_TYPES as Yt, namesAnyDeclaredParameter as Z, createSecretMasker as Za, repairMalformedOrphansForReadOnly as Zi, UNSPECIFIED_SKIP_REASON as Zn, BOOTSTRAP_MARKER_PREFIX as Zo, UNREADABLE_ORPHANS_CONTAINER_ROW as Zr, PARTITION_TABLE as Zs, ccRoutedFinalSnapshotError as Zt, makeCanonicalizePropertiesFn as _, WARM_THROUGHPUT_MEMBERS as _a, malformedOutputsRefusalMessage as _i, isExportAliasCollision as _n, recordProvenPublicExpression as _o, assertSendableRoleArn as _r, isMalformedEnvKey as _s, getCurrentNestedStackContext as _t, findNestedTemplateTreeDefect as a, findActionableSilentDrops as aa, hasPlainPrototype$1 as ac, isReadableResourceEntry as ai, extractDeploymentEventError as an, dynamicReferenceTokens as ao, isTerminationProtectionPropagationError as ar, validateContainerRepoName as as, makeSiblingClaimReader as at, recordedProtectionNote as b, toCfnInteger as ba, malformedResourceEntriesWarning as bi, DEFAULT_RESOURCE_WARN_AFTER_MS as bn, STATE_SOURCED_CROSS_GENERATION_RULES as bo, sendableAssumeRoleCommand as br, redactedDockerCause as bs, replayRollback as bt, renderNestedTemplateTreeDefect as c, withoutSilentDropProperties as ca, absoluteAssemblyPathEscape as cc, malformedExportSourceWarning as ci, exportAliasCollisionScrubWarning as cn, inheritNestedStackParameterAssociations as co, reEnableInstanceApiTermination as cr, resolveDockerContextDirectory as cs, displacedOpClause as ct, conditionInputsFrom as d, findReplacedReadersOfRecreateTargets as da, renderAssemblyPathEscape as dc, malformedLocalResourcesWarning as di, secretSafeKeyDisplay as dn, identityKeyFor as do, IntrinsicFunctionResolver as dr, describeDockerFailure as ds, getNestedRevertRun as dt, repairMalformedResourcePropertiesForReadOnly as ea, AssemblyReader as ec, displayLogicalId as ei, isFinalSnapshotError as en, maskSecretsInText as eo, withIndeterminateGuard as er, getBootstrapMarkerKey as es, deleteJournaledOrphans as et, parentSuppliedValues as f, shownType as fa, resolveAssemblyPath as fc, malformedOrphanRecordsRefusalMessage as fi, exportNameSecretExposure as fn, carriesSecretMask as fo, classifyReplaySecretRegion as fr, dockerSpawnEnvWithSensitive as fs, nestedChildStackName as ft, mergeNoChangeOutputs as g, renderStatefulReason as ga, malformedOrphansWarning as gi, collectPublishedOutputNames as gn, recordNoEchoAttributeValues as go, assertFlagRoleArn as gr, isDockerClientEnvKey as gs, withNestedRevertRun as gt, keptWholeReasonText as h, isStatefulRecreateTargetSync as ha, malformedOrphansRefusalMessage as hi, collectDeclaredOutputNames as hn, recordMaskOnlyValuesIn as ho, applyRoleArnIfSet as hr, getDockerCmd as hs, revertedNestedRowIds as ht, childTemplateLoader as i, unreadableResourceEntries as ia, hasOwnKey as ic, isReadableOrphanRecord as ii, DeploymentEventsStore as in, DYNAMIC_REFERENCE_TOKEN_SCAN as io, ec2InstanceProtectionSite as ir, validateAssetBucketName as is, sameJournaledOrphans as it, resolveDynamoDbDeleteBudgetMs as j, requireConfigString as ja, refuseMalformedOrphansForDestroy as ji, DBPROXY_TAGS_WHAT as jn, describeRegionValueKind as jo, coerceParameterTypedValue as jr, getLegacyStateBucketName as js, replacementNeverSwapped as jt, deleteBudgetKey as k, requireConfigArray as ka, refuseMalformedOrphanRecordsForDestroy as ki, withCreateTokenLedger as kn, splitImportedOps as ko, s3BucketRegionalDomainName as kr, synthesisStatusMessage as ks, planFailedOps as kt, templateIdentity as l, NO_CC_HANDLERS_REASON as la, describeFileReadFailure as lc, malformedLocalOutputsWarning as li, secretBearing as ln, recordNestedStackParameterExpressions as lo, DiffCalculator as lr, describeDockerCapturedOutput as ls, displacedPhysicalIdShown as lt, isSecretBearingReferenceString as m, isStatefulRecreateTargetForReplace as ma, resolveBucketRegion as mc, malformedOrphanRowsKeptWarning as mi, noEchoParameterValueSeed as mn, recordMaskOnlyValue as mo, regionLessSecretName as mr, formatDockerLoginError as ms, revertNestedChildFromJournal as mt, IMPLICIT_DELETE_DEPENDENCIES as n, unpreviewableOrphanRecords as na, processStackMessages as nc, hasReadableOutputs as ni, unsupportedFinalSnapshotError as nn, redactSecretsForState as no, markWaitAbandoned as nr, parseBootstrapMarker as ns, journaledOrphanLines as nt, isAbsoluteAssetPath as o, findSilentDropProperties as oa, nullPrototypeRecord as oc, malformedDriftResourcePropertiesWarning as oi, WITHHELD_NAME_DISPLAY as on, isUncertifiedBaselineMaskPosition as oo, observeThenDisableInstanceApiTermination as or, buildDenyExternalAccessPolicy as os, planOrphanAdoption as ot, readRecordedConditionVerdicts as p, MULTI_REGION_RECREATE_BLOCKED_TYPES as pa, clearBucketRegionCache as pc, malformedOrphanRecordsWarning as pi, isWholeDynamicReferenceValue as pn, provenPublicValue as po, producerRegionsFromState as pr, finchSecretArgvRefusal as ps, recordDisplacedSkips as pt, green as q, printingCorpusOf as qa, refuseMalformedResourcesForDestroy as qi, CloudControlProvider as qn, createAssetRedirectResolver as qo, passedParameterClassesOf as qr, uploadCfnTemplate as qs, stateSecretNameNeedles as qt, computeImplicitDeleteEdges as r, unreadableOrphanRecords as ra, defineOwnKey as rc, hasReadableResources as ri, DeploymentEventsReader as rn, scrubResourceRecord as ro, disableInstanceApiTermination as rr, readBootstrapMarkerBody as rs, loadJournaledOrphans as rt, listNestedTemplateRows as s, unwrittenCreateOnlyReplacement as sa, ownValue as sc, malformedExportNamesWarning as si, displayTextOrWithheld as sn, pathCrossesDottedKey as so, reDisableInstanceApiTermination as sr, buildDockerImage as ss, NESTED_PENDING_PARENT_REASON as st, DeployEngine as t, repairMalformedResourcesForReadOnly as ta, StageLoadError as tc, hasReadableOrphans as ti, refusesFinalSnapshot as tn, markSameGenerationBag as to, isWaitAbandonedError as tr, isCrossRegionRedirect as ts, isHandledOrphan as tt, conditionFingerprint as u, hasNoCloudControlHandlers as ua, displayAssemblyPath as uc, malformedLocalResourceEntriesWarning as ui, secretBearingStateKeyWarning as un, recoverMaskedOutput as uo, INTRINSIC_KEYS as ur, describeDockerExecFailure as us, dropSettledNestedJournals as ut, withResourceDeadline as v, coerceWarmThroughput as va, malformedOutputsWarning as vi, bindingSkippedOutputs as vn, wholeStringLeavesOf as vo, explicitRoleArnOrThrow as vr, partitionSensitiveEnv as vs, withNestedStackContext as vt, readProtection as w, configBooleanRefusal as wa, malformedStateRefusalMessage as wi, formatDestructiveChange as wn, isSingleDynamicReferenceToken as wo, envCredentialsAreAssumedRole as wr, escapeRegExp$3 as ws, withStackRecords as wt, PROTECTION_PROPERTY_BY_TYPE as x, toFiniteNumber as xa, malformedResourcePropertiesWarning as xi, maskingRetryLogger as xn, STATE_SOURCED_READBACK_RULES as xo, AWS_CREDENTIAL_ENV_KEYS as xr, runDockerForeground as xs, awaitInFlightSibling as xt, recordedProtectionEvidence as y, isWarmThroughputDecrease as ya, malformedRenderedContainersWarning as yi, DEFAULT_RESOURCE_TIMEOUT_MS as yn, STATE_SOURCED_BASELINE_RULES as yo, isIamRoleArn as yr, redactDockerArgvValues as ys, replayFailedOperations as yt, isTruthyCfnBoolean as z, DagBuilder as za, refuseMalformedResourceEntriesForImport as zi, stringifyIfAssigned as zn, orphansAfterRollback as zo, keepsSecretReferenceToken as zr, resolveUseCdkBootstrapAssets as zs, redactedDeleteAddressSkip as zt };
|
|
38108
|
+
//# sourceMappingURL=deploy-engine-wyaJUA8V.js.map
|