From 246765b254cd8e1124384598b50ecad4ca11753f Mon Sep 17 00:00:00 2001 From: daz Date: Thu, 13 Jun 2024 13:06:35 -0600 Subject: [PATCH] Update DV access key regex to be more selective This should address the code-scanning alert https://github.com/gradle/actions/security/code-scanning/1 --- sources/src/develocity/short-lived-token.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sources/src/develocity/short-lived-token.ts b/sources/src/develocity/short-lived-token.ts index a0bfdb6..bf92480 100644 --- a/sources/src/develocity/short-lived-token.ts +++ b/sources/src/develocity/short-lived-token.ts @@ -156,7 +156,7 @@ type HostnameAccessKey = { } export class DevelocityAccessCredentials { - static readonly accessKeyRegexp = /^(\S+=\w+)(;\S+=\w+)*$/ + static readonly accessKeyRegexp = /^([^;=\s]+=\w+)(;[^;=\s]+=\w+)*$/ readonly keys: HostnameAccessKey[] private constructor(allKeys: HostnameAccessKey[]) {