From 3c3aba316c556530f4bc83c413599ec478019819 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=80=9Emarianfoo=E2=80=9C?= <13335743+marianfoo@users.noreply.github.com> Date: Tue, 5 Nov 2024 11:58:11 +0100 Subject: [PATCH] fix: dont log passphrase --- .../lib/cookieGetter.js | 24 ++++++++++----- .../lib/cookieGetter.js.map | 2 +- .../src/cookieGetter.ts | 29 +++++++++++++++---- 3 files changed, 42 insertions(+), 13 deletions(-) diff --git a/packages/ui5-middleware-onelogin/lib/cookieGetter.js b/packages/ui5-middleware-onelogin/lib/cookieGetter.js index fe87dfb6..3284c01d 100644 --- a/packages/ui5-middleware-onelogin/lib/cookieGetter.js +++ b/packages/ui5-middleware-onelogin/lib/cookieGetter.js @@ -84,7 +84,6 @@ class CookieGetter { username: process.env.UI5_MIDDLEWARE_ONELOGIN_USERNAME, password: process.env.UI5_MIDDLEWARE_ONELOGIN_PASSWORD, useCertificate: process.env.UI5_MIDDLEWARE_ONELOGIN_USE_CERTIFICATE === "true", - clientCertificate: this.parseJSON(process.env.UI5_MIDDLEWARE_ONELOGIN_CLIENT_CERTIFICATE), debug: process.env.UI5_MIDDLEWARE_ONELOGIN_DEBUG === "true", query: this.parseJSON(process.env.UI5_MIDDLEWARE_ONELOGIN_QUERY), certificateOrigin: process.env.UI5_MIDDLEWARE_ONELOGIN_CERTIFICATE_ORIGIN, @@ -108,15 +107,23 @@ class CookieGetter { effectiveOptions.configuration.certificatePfx; const useClientCertificates = isUseCertificateEnabled && hasCertificateConfig; if (effectiveOptions.configuration.debug) { + const sanitizePassphrase = (obj) => { + var _a; + // eslint-disable-next-line @typescript-eslint/no-unsafe-return + if (!((_a = obj === null || obj === void 0 ? void 0 : obj.configuration) === null || _a === void 0 ? void 0 : _a.certificatePassphrase)) + return obj; + // eslint-disable-next-line @typescript-eslint/no-unsafe-return + return Object.assign(Object.assign({}, obj), { configuration: Object.assign(Object.assign({}, obj.configuration), { certificatePassphrase: "***" }) }); + }; log.info("Default options:"); - log.info(defaultOptions); + log.info(sanitizePassphrase(defaultOptions)); log.info("Env options:"); - log.info(envOptions); + log.info(sanitizePassphrase(envOptions)); log.info("Yaml options:"); - log.info(options); + log.info(sanitizePassphrase(options)); log.info("Effective options:"); - log.info(effectiveOptions); - log.info('Using client certificates: ' + String(useClientCertificates)); + log.info(sanitizePassphrase(effectiveOptions)); + log.info("Using client certificates: " + String(useClientCertificates)); } const attr = { url: effectiveOptions.configuration.path, @@ -168,7 +175,10 @@ class CookieGetter { } if (effectiveOptions.configuration.debug) { log.info("Client certificates configuration:"); - log.info(contextOptions.clientCertificates); + // Create a copy of certificates config without the passphrase for logging + // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-return + const certificatesForLogging = contextOptions.clientCertificates.map((cert) => (Object.assign(Object.assign({}, cert), { passphrase: cert.passphrase ? "***" : undefined }))); + log.info(certificatesForLogging); } const context = yield browser.newContext(contextOptions); const page = yield context.newPage(); diff --git a/packages/ui5-middleware-onelogin/lib/cookieGetter.js.map b/packages/ui5-middleware-onelogin/lib/cookieGetter.js.map index 76aa23af..fe24b03c 100644 --- a/packages/ui5-middleware-onelogin/lib/cookieGetter.js.map +++ b/packages/ui5-middleware-onelogin/lib/cookieGetter.js.map @@ -1 +1 @@ -{"version":3,"file":"cookieGetter.js","sourceRoot":"","sources":["../src/cookieGetter.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,uDAAuD;AACvD,kEAAkC;AAElC,MAAM,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC,CAAC;AACvC,6DAA8D;AAa9D,MAAqB,YAAY;IAChC;;;;OAIG;IACK,cAAc,CAAC,GAAS;QAC/B,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,CAAC,GAAG,EAAE,EAAE;YAChC,IAAI,OAAO,GAAG,CAAC,GAAG,CAAC,KAAK,QAAQ,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,GAAG,C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,CAAC,CAAC;wBACjE,CAAC;oBACF,CAAC;oBACD,IAAI,WAAW,IAAI,gBAAgB,CAAC,aAAa,CAAC,KAAK,EAAE,CAAC;wBACzD,GAAG,CAAC,IAAI,CAAC,qCAAqC,CAAC,CAAC;oBACjD,CAAC;gBACF,CAAC;gBAED,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,OAAO,EAAE,CAAC;gBACxC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;oBAC1B,MAAM,IAAI,KAAK,CAAC,kCAAkC,IAAI,CAAC,GAAG,4FAA4F,CAAC,CAAC;gBACzJ,CAAC;gBACD,OAAO,CAAC,KAAK,EAAE,CAAC;gBAChB,OAAO,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;YAChC,CAAC;YAAC,OAAO,MAAM,EAAE,CAAC;gBACjB,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;gBAClB,MAAM,MAAM,CAAC;YACd,CAAC;QACF,CAAC;KAAA;CACD;AAzRD,+BAyRC"} \ No newline at end of file diff --git a/packages/ui5-middleware-onelogin/src/cookieGetter.ts b/packages/ui5-middleware-onelogin/src/cookieGetter.ts index 0f31cb01..41b93b5e 100644 --- a/packages/ui5-middleware-onelogin/src/cookieGetter.ts +++ b/packages/ui5-middleware-onelogin/src/cookieGetter.ts @@ -108,14 +108,27 @@ export default class CookieGetter { const useClientCertificates = isUseCertificateEnabled && hasCertificateConfig; if (effectiveOptions.configuration.debug) { + const sanitizePassphrase = (obj: any) => { + // eslint-disable-next-line @typescript-eslint/no-unsafe-return + if (!obj?.configuration?.certificatePassphrase) return obj; + // eslint-disable-next-line @typescript-eslint/no-unsafe-return + return { + ...obj, + configuration: { + ...obj.configuration, + certificatePassphrase: "***", + }, + }; + }; + log.info("Default options:"); - log.info(defaultOptions); + log.info(sanitizePassphrase(defaultOptions)); log.info("Env options:"); - log.info(envOptions); + log.info(sanitizePassphrase(envOptions)); log.info("Yaml options:"); - log.info(options); + log.info(sanitizePassphrase(options)); log.info("Effective options:"); - log.info(effectiveOptions); + log.info(sanitizePassphrase(effectiveOptions)); log.info("Using client certificates: " + String(useClientCertificates)); } @@ -174,7 +187,13 @@ export default class CookieGetter { if (effectiveOptions.configuration.debug) { log.info("Client certificates configuration:"); - log.info(contextOptions.clientCertificates); + // Create a copy of certificates config without the passphrase for logging + // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-return + const certificatesForLogging = contextOptions.clientCertificates.map((cert: any) => ({ + ...cert, + passphrase: cert.passphrase ? "***" : undefined, + })); + log.info(certificatesForLogging); } const context = await browser.newContext(contextOptions);