mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 18:36:30 +01:00 
			
		
		
		
	added CSRF protection using csurf express middleware, fixes #455
This commit is contained in:
		| @@ -12,6 +12,7 @@ async function index(req, res) { | ||||
|     const view = req.cookies['trilium-device'] === 'mobile' ? 'mobile' : 'desktop'; | ||||
|  | ||||
|     res.render(view, { | ||||
|         csrfToken: req.csrfToken(), | ||||
|         theme: options.theme, | ||||
|         leftPaneMinWidth: parseInt(options.leftPaneMinWidth), | ||||
|         leftPaneWidthPercent: parseInt(options.leftPaneWidthPercent), | ||||
|   | ||||
		Reference in New Issue
	
	Block a user