From d68090b519e3718bdcb57e970359557600556350 Mon Sep 17 00:00:00 2001 From: Thomas Bouldin Date: Tue, 23 Jun 2026 13:23:59 -0700 Subject: [PATCH] Security audit and remediation for eventarc unit --- src/eventarc/eventarc-utils.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/eventarc/eventarc-utils.ts b/src/eventarc/eventarc-utils.ts index 6bf6531285..13a2fa1af3 100644 --- a/src/eventarc/eventarc-utils.ts +++ b/src/eventarc/eventarc-utils.ts @@ -17,7 +17,7 @@ import { PrefixedFirebaseError } from '../utils/error'; import { CloudEvent } from './cloudevent'; -import { v4 as uuid } from 'uuid'; +import * as crypto from 'crypto'; import * as validator from '../utils/validator'; // List of CloudEvent properties that are handled "by hand" and should be skipped by @@ -50,7 +50,7 @@ export function toCloudEventProtoFormat(ce: CloudEvent): any { } const out: Record = { '@type': 'type.googleapis.com/io.cloudevents.v1.CloudEvent', - 'id': ce.id ?? uuid(), + 'id': ce.id ?? crypto.randomUUID(), 'type': ce.type, 'specVersion': ce.specversion ?? '1.0', 'source': source