From 2aa08ec7c436d2b196c0a51b1a155f663e000115 Mon Sep 17 00:00:00 2001
From: Sameer <142401625+sameer6pre@users.noreply.github.com>
Date: Tue, 24 Jun 2025 12:55:27 +0530
Subject: [PATCH] Update orbit-app/src/components/DownloadFile.jsx in branch
Precogs-fix-9jy70jwa
---
orbit-app/src/components/DownloadFile.jsx | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/orbit-app/src/components/DownloadFile.jsx b/orbit-app/src/components/DownloadFile.jsx
index 2bcc58f..b2118ee 100644
--- a/orbit-app/src/components/DownloadFile.jsx
+++ b/orbit-app/src/components/DownloadFile.jsx
@@ -27,7 +27,15 @@ function DownloadFile() {
setFileId(e.target.value)}
+(e) => {
+ const sanitizedValue = sanitizeInput(e.target.value); // FIX: Sanitize the input
+ setFileId(sanitizedValue);
+}
+
+function sanitizeInput(input) {
+ // Example sanitization function
+ return input.replace(/[^a-zA-Z0-9-_]/g, ''); // Allow only alphanumeric, dash, and underscore
+}
placeholder="Enter File ID"
/>