diff --git a/src/components/ViewPresignedUrl/index.tsx b/src/components/ViewPresignedUrl/index.tsx index daec483..b660054 100644 --- a/src/components/ViewPresignedUrl/index.tsx +++ b/src/components/ViewPresignedUrl/index.tsx @@ -67,7 +67,18 @@ export default function ViewPresignedUrl({ presingedUrl }: Props) { } // Return HTML (via iframe) display - if (HTML_FILETYPE_LIST.includes(filetype)) { + + /** **************************** TEMPORARY SOLUTION **************************** + * + * Only allow S3 presigned url that is allowed to be viewed in this tag. + * + * See below 'TEMPORARY SOLUTION' block for details. Change to original solution if the fix has been made. + * + * Current solution: if (HTML_FILETYPE_LIST.includes(filetype) && presingedUrl.startsWith('https://umccr')) { + * Original solution: if (HTML_FILETYPE_LIST.includes(filetype)) { + * + * */ + if (HTML_FILETYPE_LIST.includes(filetype) && presingedUrl.startsWith('https://umccr')) { return (