mirror of
https://github.com/Sonny93/my-links.git
synced 2025-12-08 22:53:25 +00:00
51 lines
874 B
TypeScript
51 lines
874 B
TypeScript
import { defineConfig } from '@adonisjs/shield';
|
|
|
|
const shieldConfig = defineConfig({
|
|
/**
|
|
* Configure CSP policies for your app. Refer documentation
|
|
* to learn more
|
|
*/
|
|
csp: {
|
|
enabled: false,
|
|
directives: {},
|
|
reportOnly: false,
|
|
},
|
|
|
|
/**
|
|
* Configure CSRF protection options. Refer documentation
|
|
* to learn more
|
|
*/
|
|
csrf: {
|
|
enabled: false,
|
|
exceptRoutes: [],
|
|
enableXsrfCookie: true,
|
|
methods: ['POST', 'PUT', 'PATCH', 'DELETE'],
|
|
},
|
|
|
|
/**
|
|
* Control how your website should be embedded inside
|
|
* iFrames
|
|
*/
|
|
xFrame: {
|
|
enabled: false,
|
|
},
|
|
|
|
/**
|
|
* Force browser to always use HTTPS
|
|
*/
|
|
hsts: {
|
|
enabled: true,
|
|
maxAge: '180 days',
|
|
},
|
|
|
|
/**
|
|
* Disable browsers from sniffing the content type of a
|
|
* response and always rely on the "content-type" header.
|
|
*/
|
|
contentTypeSniffing: {
|
|
enabled: true,
|
|
},
|
|
});
|
|
|
|
export default shieldConfig;
|