mirror of
https://github.com/LemmyNet/lemmy-ui.git
synced 2024-11-29 08:47:19 +00:00
Allow audio captcha through CSP (#1690)
Co-authored-by: Dessalines <dessalines@users.noreply.github.com>
This commit is contained in:
parent
6b1ea447e5
commit
005135d4f2
|
@ -10,7 +10,7 @@ export function setDefaultCsp({
|
||||||
}) {
|
}) {
|
||||||
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();
|
||||||
|
@ -30,7 +30,7 @@ export function setCacheControl({
|
||||||
next: NextFunction;
|
next: NextFunction;
|
||||||
}) {
|
}) {
|
||||||
const user = UserService.Instance;
|
const user = UserService.Instance;
|
||||||
let caching;
|
let caching: string;
|
||||||
if (user.auth()) {
|
if (user.auth()) {
|
||||||
caching = "private";
|
caching = "private";
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue