Benign lua Download

changepage 2.0.1-1

“Change the page layout in the middle of a document”

Action declares a main entrypointAction declares a post-job hook
SHA-256b018bf43bdfb651208b15a00457a0a406bd79cbbe7770507a6d0f135c653d40e

Evidence

imports fs lines 1–35
1import * as assert from 'assert'
2import * as core from '@actions/core'
3import * as exec from '@actions/exec'
4import * as fs from 'fs'
5import * as io from '@actions/io'
6import * as os from 'os'
7import * as path from 'path'
8import * as regexpHelper from './regexp-helper'
9import * as stateHelper from './state-helper'
10import * as urlHelper from './url-helper'
11import {v4 as uuid} from 'uuid'
12import {IGitCommandManager} from './git-command-manager'
13import {IGitSourceSettings} from './git-source-settings'
14
15const IS_WINDOWS = process.platform === 'win32'
16const SSH_COMMAND_KEY = 'core.sshCommand'
17
⋯18 lines
Access-token field reference lines 56–63
56:71… origin" is SCHEME://HOSTNAME[:PORT]
57 const basicCredential = Buffer.from(
58 `x-access-token:${this.settings.authToken}`,
59 'utf8'
60 ).toString('base64')
61 core.setSecret(basicCredential)
62 this.tokenPlaceholderConfigValue = `AUTHORIZATION: basic ***`
63 this.tokenConfigValue = `AUTHORIZATION: b …
process.env bracket access for runner vars lines 85–93
85:20… p global config
86 if (this.temporaryHomePath?.length > 0) {
87 return path.join(this.temporaryHomePath, '.gitconfig')
88 }
89 // Create a temp home directory
90 const runnerTemp = process.env['RUNNER_TEMP'] || ''
91 assert.ok(runnerTemp, 'RUNNER_TEMP is not defined')
92 const uniqueId = uuid()
93 this.temporaryHomePath = pa …
Node reads HOME directory environment variable lines 94–102
94:22… .mkdir(this.temporaryHomePath, {recursive: true})
95
96 // Copy the global git config
97 const gitConfigPath = path.join(
98 process.env['HOME'] || os.homedir(),
99 '.gitconfig'
100 )
101 const newGitConfigPath = path.join(this.temporaryHomePath, '.gitconfig')
102 let configExists = …
Node fs.promises asynchronously writes a file lines 106–120
⋯7 lines
113 await io.cp(gitConfigPath, newGitConfigPath)
114 } else {
115 await fs.promises.writeFile(newGitConfigPath, '')
116 }
117
118 // Override HOME
119 core.info(
120 `Temporarily overriding HOME='${this.temporaryHomePath}' …

No evidence locations were recorded for this file. Raw result

Keyboard shortcuts on this page: j for the next sample, k for the previous one, x to go back to the feed, d to download the original bytes, r to re-queue the sample for analysis.