Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
1 vote
1 answer
40 views

Why is my Ruby on Rails app session logging out randomly?

I'm a veteran programmer (C# mainly) but recently I've been dabbling with Ruby on Rails (7 to be specific). I've built a small authenticated app with a logout button. During my local testing, I would ...
Ka Wai Cheung's user avatar
0 votes
1 answer
16 views

Keystonejs 6 Authenticate from external frontend server with AuthenticateUserWithPassword mutation

I'm building a decoupled keystonejs (keystonejs 6) app with different frontends that will pull and push data from the main keystonejs instance using its graphql api. I've set the access control to ...
AngelMS's user avatar
  • 61
0 votes
0 answers
31 views

Integrating Third-Party Authentication in an Angular Application with Spring Boot

I am in the process of developing an application with an Angular frontend and a Spring Boot backend. I would like to delegate the management of authentication, tokens, sessions, and refresh tokens to ...
Az''s user avatar
  • 1
0 votes
0 answers
36 views

E_UNAUTHORIZED_ACCESS Error with AdonisJs and Google oAuth

I created a project with adonisjs by setting up google oAuth authentication. When I launch a call via postman on a route protected by my auth_middleware, I get the error 401 E_UNAUTHORIZED_ACCESS ...
nathaliej's user avatar
0 votes
0 answers
19 views

New Tab Opens Login Page Even When Already Logged In (Node-RED Session Issue)

I'm working on a Node-RED application, and I'm encountering an issue with session handling when opening a new tab in the same browser. Here's what's happening: I log in to http://localhost:1880/api/...
Logu's user avatar
  • 1
1 vote
0 answers
20 views

get_absolute_url django admin session id missing

I'm using Django's "View on site" feature to navigate from the Django admin to a specific page in my application for a model instance. On this page, a GET request is made to retrieve data ...
sparsh's user avatar
  • 145
0 votes
1 answer
31 views

Why Use Refresh Tokens in Authentication? Can't They Be Stolen Like JWTs?

I'm implementing authentication in my app using ASP.NET Web API and JWTs. I’m trying to understand the purpose of refresh tokens and have some doubts about their benefits and security implications: ...
Nikusha Gabidzashvili's user avatar
-1 votes
0 answers
48 views

Save authenticaion object across multiple requests, at session level

I am creating a app which has login page and that is verified by the authentication manager in spring security, so I did not used the default login page provided by spring security by not configuring ...
adil's user avatar
  • 1
0 votes
1 answer
56 views

PHP login logic with "resume previous login"

I'd like to realize a login mechanism in PHP, able to: ask username and password the first time you log in; don't ask again username and password if you re-access the site within x days since the ...
the_candyman's user avatar
  • 1,653
-1 votes
2 answers
63 views

What should we store in the session when using session-based authentication? [closed]

I'm learning how to use session-based authentication for my web app, but I'm not sure what kind of data should be stored in the session. What information do I need to keep in the session after a user ...
Impossible cell 754863921's user avatar
0 votes
0 answers
86 views

Next auth(Authjs) session is null on Nextjs 14 server page

import { auth } from "@/auth"; const page = async ({children}) => { const session = await auth(); return <div>{children}</> }; // My auth config import { Pool } from &...
key's user avatar
  • 21
0 votes
1 answer
61 views

Do something after succesful login in Rails devise

I have a Rails app and use devise for registration and sign-up of users. Now I want to store the date of the last successful login on the user. Basically I thought about overwriting the create method ...
Julian's user avatar
  • 62
0 votes
0 answers
27 views

Save session information in Postgres with cutom Session model for express

I want to use session for an express back-end authentication & authorization using express-session library. I also want to persist the session in Postgres with custom schema as defined in the ...
chala's user avatar
  • 21
1 vote
0 answers
27 views

Auth logoutOtherDevices manually Laravel

I use Session Driver Database, If instead of using Auth::logoutOtherDevices($currentPassword); , for example, I did it manually like this: $user = $req->user(); $session = $req->session(...
none's user avatar
  • 97
0 votes
0 answers
18 views

Laravel sanctum SPA on logout not set user_id field null [duplicate]

I use Laravel sanctum SPA specifically through sessions and cookies when logging out the user_id field in Database is not set to null after the user logs out, but it remains until another request ...
none's user avatar
  • 97
0 votes
0 answers
26 views

Laravel Auth::attempt() cannot save sessions in the database

I am using laravel 11 and I seem to be missing something in the authentication setup. I updated all user IDs to uuid instead of the default incremental int approach, unfortunately, Auth::attempt() isn'...
jmakinin's user avatar
0 votes
0 answers
275 views

FastAPI Starlette Middleware session - unable to access session data after redirect

I'm writing a simple web app using Fast API as the backend, and I want authentication to be achieved via Azure B2C. The logic of this all is not really important now, I just want to be able to test ...
Dominik Borkowski's user avatar
1 vote
0 answers
26 views

OAuth2 strategy after token exchange

I want to understand how the professionals handle auth. To better understand my problem I'll describe my app structure quickly: I have a json api written in Go. Let's call it the BACKEND. I have a ...
Latex User 101's user avatar
0 votes
0 answers
55 views

TRPCClientError: Cannot read properties of undefined (reading 'set')

Im using nextjs app router, trpc, prisma, and trying to implement login functionality with setting a cookie. Im trying to set cookie in res headers, but i get this error. I cannot figure out why? ...
Ash Gharibyan's user avatar
0 votes
3 answers
114 views

ASP.NET Core 6.0 MVC : get session and cookies in view

Browser>Application>Cookies I am attempting to create session and cookies in a ASP.NET Core 6 MVC project. When I debug the project locally on my PC, the session and cookies are working as ...
Lamont Chean's user avatar
0 votes
1 answer
68 views

Flask web app redirects to login page instead of dashboard after successful authentication to an external website

I am making a Flask web application that clones a login page of a website and sending post request to authenticate to the original website. The request is made using session so to be able to preserve ...
Mihai's user avatar
  • 41
0 votes
0 answers
47 views

Can't get file because logged in is not kept

I'm encountering the same situation which is described in this page How to requests.Session().get if website does not keep me logged in? with another website: Trying to download an executable on this ...
Kaoru54's user avatar
  • 11
0 votes
1 answer
48 views

What If Session Expires While User Is Still On The Website

Suppose that there are 5 minutes left for the session to expire when user enters the website.Every action that user will make after 5 minutes will be rejected by server if it requires you to login and ...
Tunahan Keklik's user avatar
0 votes
0 answers
33 views

Session Persistence Issue Between Two Django Projects Using Both JWT and Session Authentication

Background Project A Legacy system Django full-stack server based on a template language Using sessions for authentication Python version 3.8 Django version 3.2 Project B New project JSON-based Django ...
genie's user avatar
  • 1
1 vote
1 answer
294 views

Cannot authenticate in fresh installed Laravel 11 with MySQL/MariaDB

I cannot have Laravel 11 authentication working with MySQL or MariaDB. Here's what I've done: Install Laravel with composer create-project laravel/laravel foo Create Database and edit .env ...
Arcesilas's user avatar
  • 1,432
0 votes
1 answer
42 views

Issue with back button navigation after login in Node.js Express using sessions and cookies

I've implemented a basic login system using session and cookies in Node.js Express. After successful login, users are redirected to /home to see a welcome page. However, when users click the browser's ...
prajitha k's user avatar
0 votes
0 answers
37 views

CakePHP 4.5 Session was already started on logout

I'm trying to upgrade to PHP 4.5 and everything is going flawless except logging out. CakePHP 4.5.5 CakePHP/Authorisation 2.10.2 When logging out in: APP/Controller/UsersController.php public ...
Zegert's user avatar
  • 113
0 votes
2 answers
57 views

Login session not accessible other than redirected page

This is my login.php if ($_SERVER["REQUEST_METHOD"] == "POST") { $username = $_POST['username']; $password = $_POST['password']; $stmt = $conn->prepare("SELECT ...
Asad Khrd's user avatar
0 votes
0 answers
208 views

/api/auth/session being called multiple times and expires getting updated for every call

Integrating NextAuth using Google Provider [...nextauth].js file export const authOptions = { providers: [ GoogleProvider({ clientId: process.env.GOOGLE_CLIENT_ID, ...
ishu_oct's user avatar
0 votes
0 answers
66 views

Next-Auth session error while trying to login with credentials or google

I am using Next.js 14 and NextAuth 4 and trying the login using credentials and google provider When i am running my project in dev mode there is no error and it's working fine as client-side is ...
Riyan Ali's user avatar
0 votes
0 answers
16 views

Issue with session authentication not being preserved across calls from React frontend to Django backend

I have the following code: LoginPage.js: import React from 'react'; import axios from 'axios'; import { useNavigate, Navigate } from 'react-router-dom'; import { Button, Grid, TextField } from '@mui/...
user24368649's user avatar
0 votes
1 answer
112 views

Laravel 10: Session regeneration in middleware not updating values

I am working on a Laravel 10 application with middleware that checks if a token has expired. If it has, it generates a new token using refresh_token, creates a new session, and updates the session ...
José Victor's user avatar
0 votes
1 answer
31 views

How to proceed authentification and authorization between three layers?

I have a bunch of services divided into three parts: First: custom authorization server as C# Web API. It handles users' info and returns tokens following authorization code flow. Second: React with ...
TyuJas's user avatar
  • 27
0 votes
0 answers
115 views

How can I persist Django session across multiple applications?

I want to be upfront with you the project I'm working with is kind of a mess, so I'm just looking for solutions. I have a Django app (no DRF) and a CI4 app. I want authentication to persist across the ...
user23976798's user avatar
0 votes
0 answers
73 views

What is the best practice for handling auth sessions in a CLI application?

I've looked up similar questions on SO and Reddit, but none of them seem to have an accepted answer, which is why I'm hoping to get some insight here. I'm building a Node + Express application that ...
Safwan Parkar's user avatar
1 vote
1 answer
52 views

Session not properly being passed for login and authentication

I am trying to learn how sessions work. I know that in the server side, req.session.user = { id: 1, username: 'user1' }; is being read correctly but when I hit the endpoint /check-session req....
leon's user avatar
  • 181
0 votes
1 answer
534 views

Zitadel create service users dinamically

I'd like to implement a feature, in which service users could be created programatically. For example, on my backend on an endpoint I receive the necessary credentials, then I create a service user on ...
Patrick Visi's user avatar
0 votes
0 answers
28 views

PHP Session Breaks between pages

When try to login to Admin Panel session created. But Can't Login to Admin Dashboard. Session Breaks. What's the problem ? <?php session_start(); require('connection.inc.php'); require('functions....
Sumit Bera's user avatar
0 votes
0 answers
29 views

will the data in the session get cleared if we switch route?

We have 2 routes for user registration /signup and /verifyOtp. Both routes are working fine in Postman and backend: the user email is getting verified by otp cross-checking the data is pushing to the ...
Naseela K T's user avatar
0 votes
0 answers
16 views

Hello Next.js [...nextAuth].js File Session Function Calling Questions

I'm just asking you to check this part because I'm working on a project related to Next.js and the session part doesn't seem to be working in the callback function during the login logic ...
Developer Kim _ Claude's user avatar
0 votes
2 answers
206 views

ASP.NET Core Web API : session cookie removed after page refresh

I'm new to sessions/cookies for auth so I'm getting to know about everything slowly. I have a Web API that has some endpoints to login and also a protected endpoint that can only be accessed once the ...
ServletException's user avatar
0 votes
0 answers
56 views

Problem with login and register function i session Flask

I can't register it move me to login page. When I want to login it tells me login failed. Any ideas? Not sure where is the problem. I think I am already tried everything. I ve checked and there is no ...
Robert Wyszynski's user avatar
0 votes
0 answers
21 views

User.Claims becomes empty/null on closing browser tab

After implementing on closing browser tab to call a logout API, I came across this issue on production mode: result = (GlobalErrors)_licensing.RemoveSessionFromDB(User.FindFirstValue(ClaimTypes.Sid)); ...
Firefly0027's user avatar
0 votes
1 answer
39 views

MVC controller ignoring security.php [duplicate]

I have security.php: <?php session_start(); if (!isset($_SESSION['logged']) || !$_SESSION['logged'] ) { header("location:/backoffice/login.php"); session_destroy(); } And my ...
Jooseeeeee's user avatar
1 vote
0 answers
41 views

Session Authentication Fails on Express Server After Google OAuth Login

I'm developing a MERN stack application with a React frontend hosted on Surge (https://thestudyapp.surge.sh) and an Express backend hosted on Render (https://study-app-server.onrender.com). I've ...
TedRed's user avatar
  • 127
0 votes
0 answers
27 views

How do I go about session handling considering my approach?

I currently have a decent authentication logic in place which will verify credentials against the database document/entry. Once a login request has a successful response, I set a httpOnly cookie ...
iamgreenintro's user avatar
0 votes
1 answer
632 views

How I can update session in server side

How I can update session in server side using authV5 in nextjs latest update I tried : import { update } from "@/auth But the update not in auth
أحمد السديري's user avatar
0 votes
0 answers
14 views

WHy does user log out after the session id is regenrated?

I want to have a secure session variable for logged in users, where the session id keeps changing every 30 mins and so. the problem is I want the session ID to change but every 30 mins, the user gets ...
 Junior's user avatar
0 votes
0 answers
30 views

How to handle leftover session data when implementing session and cookie-based login and logout?

Let's consider situation implementing session and cookie-based login and logout function from scratch, we store session id and user information corresponding to session id on the server side (memory ...
Yu Byung Suk's user avatar
1 vote
1 answer
185 views

How to integrate a backend nest auth session based, with frontend in next.js?

I implemented my backend using authentication with sessions however I cannot connect to my frontend application when I make the request through insominia can have the session id saved in my cokkies ...
Edson Magno's user avatar

1
2 3 4 5
54