1
0
Fork 0
mirror of https://github.com/actions/toolkit synced 2025-05-10 09:03:02 +00:00

Update lerna dependency. (#1149)

* fix audit

* update linter
This commit is contained in:
Thomas Boop 2022-08-08 14:39:23 -04:00 committed by GitHub
parent 4beda9cbc0
commit 30995490f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 6491 additions and 6653 deletions

View file

@ -4,7 +4,7 @@ import {toCommandProperties, toCommandValue} from './utils'
import * as os from 'os'
import * as path from 'path'
import { v4 as uuidv4 } from 'uuid'
import {v4 as uuidv4} from 'uuid'
import {OidcClient} from './oidc-utils'
@ -89,13 +89,17 @@ export function exportVariable(name: string, val: any): void {
if (filePath) {
const delimiter = `ghadelimiter_${uuidv4()}`
// These should realistically never happen, but just in case someone finds a way to exploit uuid generation let's not allow keys or values that contain the delimiter.
// These should realistically never happen, but just in case someone finds a way to exploit uuid generation let's not allow keys or values that contain the delimiter.
if (name.includes(delimiter)) {
throw new Error(`Unexpected input: name should not contain the delimiter "${delimiter}"`)
throw new Error(
`Unexpected input: name should not contain the delimiter "${delimiter}"`
)
}
if (convertedVal.includes(delimiter)) {
throw new Error(`Unexpected input: value should not contain the delimiter "${delimiter}"`)
throw new Error(
`Unexpected input: value should not contain the delimiter "${delimiter}"`
)
}
const commandValue = `${name}<<${delimiter}${os.EOL}${convertedVal}${os.EOL}${delimiter}`