Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

143
Vistas
Chrome is blocking cookies in private mode for sameSite=none and Secure = CookieSecurePolicy.Always

I'm using identity server 4 and I have set cookiePolicy like:

in startup.cs

var cookiePolicyOptions = new CookiePolicyOptions
        {
            MinimumSameSitePolicy = Microsoft.AspNetCore.Http.SameSiteMode.None,
            HttpOnly = Microsoft.AspNetCore.CookiePolicy.HttpOnlyPolicy.None,
            Secure = CookieSecurePolicy.Always,
            
        };

and next:

app.UseCookiePolicy(cookiePolicyOptions);

I have also react application to authorize User in ID4. I am using Implicit Flow. When User is in normal mode everything's ok.

But when User is using private mode then the sign in window is not appear. sign in window

When in Google Chrome settings, Block thirty part cookies is set to Allow in private mode then everything is OK.

In case when application is running on localhost without https there is ok in both mode. The problem starts when application is on server with Https certificate.

I found a lot of information but still don't know if I Can do something to allow to set cookies in private mode during authorization?

Let me know if I should provide more information ;)

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

My problem was that I set sameSite=none

It's mean that my IdentityServer has different domain name than my web client.

I have changed to sameSite=Lax -it's mean that Identity and WebClient has the same domain name- but I needed to change also on my IIS binding to the same domain name for Identity Server on port: 8443 Site and Web client site. (before that two domain names was different)

In this case chrome is not blocking cookies as thirty part cookie and allow set idsrv.external cookie in browser in incognito mode also.

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda