fix(build-security): do not expose hostname to build framents (#7491)

Refs #7446
This commit is contained in:
Vladimir Gorej
2021-09-10 13:29:42 +03:00
committed by GitHub
parent 5029b81560
commit fdef4ead7a
2 changed files with 1 additions and 3 deletions

View File

@@ -11,7 +11,7 @@ if (process.env.NODE_ENV !== "production" && typeof window !== "undefined") {
} }
// eslint-disable-next-line no-undef // eslint-disable-next-line no-undef
const { GIT_DIRTY, GIT_COMMIT, PACKAGE_VERSION, HOSTNAME, BUILD_TIME } = buildInfo const { GIT_DIRTY, GIT_COMMIT, PACKAGE_VERSION, BUILD_TIME } = buildInfo
export default function SwaggerUI(opts) { export default function SwaggerUI(opts) {
@@ -21,7 +21,6 @@ export default function SwaggerUI(opts) {
gitRevision: GIT_COMMIT, gitRevision: GIT_COMMIT,
gitDirty: GIT_DIRTY, gitDirty: GIT_DIRTY,
buildTimestamp: BUILD_TIME, buildTimestamp: BUILD_TIME,
machine: HOSTNAME
} }
const defaults = { const defaults = {

View File

@@ -69,7 +69,6 @@ export default function buildConfig(
PACKAGE_VERSION: pkg.version, PACKAGE_VERSION: pkg.version,
GIT_COMMIT: gitInfo.hash, GIT_COMMIT: gitInfo.hash,
GIT_DIRTY: gitInfo.dirty, GIT_DIRTY: gitInfo.dirty,
HOSTNAME: os.hostname(),
BUILD_TIME: new Date().toUTCString(), BUILD_TIME: new Date().toUTCString(),
}), }),
}), }),