CSP should allow data urls for media-src or the audio captcha won't work

This commit is contained in:
Dominic Mazzoni 2023-06-25 12:12:32 -07:00
parent dd43827d67
commit 434502c678

View file

@ -3,7 +3,7 @@ import type { NextFunction, Response } from "express";
export default function ({ res, next }: { res: Response; next: NextFunction }) { export default function ({ res, next }: { res: Response; next: NextFunction }) {
res.setHeader( res.setHeader(
"Content-Security-Policy", "Content-Security-Policy",
`default-src 'self'; manifest-src *; connect-src *; img-src * data:; script-src 'self' 'unsafe-inline' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; form-action 'self'; base-uri 'self'; frame-src *; media-src *` `default-src 'self'; manifest-src *; connect-src *; img-src * data:; script-src 'self' 'unsafe-inline' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; form-action 'self'; base-uri 'self'; frame-src *; media-src * data:`
); );
next(); next();