From 1bf2c641fdb52bd91d13263507eeb1923fd60192 Mon Sep 17 00:00:00 2001 From: dominik003 Date: Tue, 7 Nov 2023 18:10:58 +0100 Subject: [PATCH] fix(back): Properly validate repository name --- .../settings/modelsources/t4c/repositories/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/capellacollab/settings/modelsources/t4c/repositories/models.py b/backend/capellacollab/settings/modelsources/t4c/repositories/models.py index e15201c16d..8f02cce72b 100644 --- a/backend/capellacollab/settings/modelsources/t4c/repositories/models.py +++ b/backend/capellacollab/settings/modelsources/t4c/repositories/models.py @@ -44,7 +44,7 @@ class DatabaseT4CRepository(database.Base): class CreateT4CRepository(pydantic.BaseModel): - name: str + name: str = pydantic.Field(pattern="/^[-a-zA-Z0-9_]+$/") class T4CRepositoryStatus(str, enum.Enum):