Tweaks to add codes for CSRF