mirror of
				https://github.com/billz/raspap-webgui.git
				synced 2025-03-01 10:31:47 +00:00 
			
		
		
		
	Merge pull request #385 from glaszig/fix/csrf-xhr-race-condition
fix csrf token xhr race condition
This commit is contained in:
		| @@ -59,7 +59,9 @@ function safefilerewrite($fileName, $dataToSave) | ||||
| */ | ||||
| function ensureCSRFSessionToken() | ||||
| { | ||||
|     $_SESSION['csrf_token'] = bin2hex(random_bytes(32)); | ||||
|     if (empty($_SESSION['csrf_token'])) { | ||||
|         $_SESSION['csrf_token'] = bin2hex(random_bytes(32)); | ||||
|     } | ||||
| } | ||||
|  | ||||
| /** | ||||
|   | ||||
		Reference in New Issue
	
	Block a user