redo ant csrf token
ensure anti csrf token and session is only created after login
This commit is contained in:
@ -146,6 +146,7 @@
|
||||
</div>
|
||||
<script>
|
||||
const allUsers = <%- JSON.stringify(allUsers) %>;
|
||||
|
||||
</script>
|
||||
|
||||
<script src="https://code.jquery.com/jquery-3.6.4.min.js"></script>
|
||||
|
@ -1,6 +1,5 @@
|
||||
|
||||
|
||||
|
||||
$(document).ready(function () {
|
||||
$('#resetPasswordLink').on('click', function () {
|
||||
$('#resetPasswordFormContainer').show();
|
||||
@ -429,5 +428,7 @@ $('#resetPasswordForm').on('submit', function (e) {
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -86,7 +86,6 @@ button:hover {
|
||||
|
||||
<label for="password">Password</label>
|
||||
<input type="password" id="password" name="password" placeholder="Enter your password" required>
|
||||
<input type="hidden" name="csrf_token" value="<%= csrfToken %>">
|
||||
<button type="submit">Login</button>
|
||||
</form>
|
||||
|
||||
|
@ -69,7 +69,7 @@
|
||||
<label for="otp">OTP:</label>
|
||||
<input type="text" id="otp" name="otp" required>
|
||||
<br>
|
||||
<input type="hidden" name="csrf_token" value="<%= csrfToken %>">
|
||||
|
||||
<button type="submit">Submit OTP</button>
|
||||
</form>
|
||||
</body>
|
||||
|
Reference in New Issue
Block a user