Skip to content

Infinite Redirection #31917

Open
Open
@ethanamessmer

Description

@ethanamessmer

Current behavior

Error when trying to connect to an AzureAD SSO authenticated application through Cypress. Get a 302 response with infinite redirection to the microsoft.login.com page, but never actually reach it because we cannot puppeteer a login.

Here's what we've tried so far

  1. Setting experimentalSessionAndOrigin to true
  2. Setting experimentalModifyObstructiveThirdPartyCode to true
  3. Attempting to set up auth tokens ahead of time in cookies
  4. Puppeteering login
  5. Running in incognito to make sure it needs to log in
  6. ChromeWebSecurity set to true

I know this error has been talked about previously here: #7619, but no other solutions/updates in the bug have publicly been shared from what I can tell.

Desired behavior

In this situation, Cypress should redirect to login.microsoft.com and go through the login steps with a service account created specifically for this app, then go back to the application after being authenticated

Test code to reproduce

it('Should login, () => {
  cy.visit('url-to=app')
  cy.origin('login.microsoft.com', () => {
    //Login Steps
  })
})

Cypress Version

12.0.0

Node version

20.10.0

Operating System

macOS 14.7.6

Debug Logs

Other

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions