diff --git a/server/app.js b/server/app.js index 4591eae..47d4be1 100644 --- a/server/app.js +++ b/server/app.js @@ -2,6 +2,7 @@ import path from 'path' import fastify from 'fastify' import fastifyStatic from 'fastify-static' import helmet from 'fastify-helmet' +import cors from 'fastify-cors' import hyperid from 'hyperid' import config from './config/server' import { serveIndex, getRealIp } from './util' @@ -49,6 +50,10 @@ app.register(helmet, { } }) +app.register(cors, { + origin: ["https://2024.uiuc.tf", "https://uiuctf-2024-rctf-frontend.pages.dev"] +}) + uploadProviderInit(app) app.register(api, {