Answers.Body: <p>Just want to chime in with what fixed this for me. </p>
  
  <p>I had the same issue and it was the Nginx configuration. Specifically, the order that I some of my location and cache settings. </p>
  
  <p>To get it working, I strictly followed the order from this: <a href="https://nystudio107.com/blog/static-caching-with-craft-cms" rel="nofollow noreferrer">https://nystudio107.com/blog/static-caching-with-craft-cms</a></p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-09-09T03:33:46.770Z
Answers.LastActivityDate: 2017-09-09T03:33:46.770Z
Answers.UserDisplayName: nathananderson
Answers.Body: <p>Sorry for answering my own question.  </p>
  
  <p>Upon a suggestion from P&amp;T, we found that our Nginx configuration was removing the cookies when it cached the page. When we left the cookies in, we were able to log in.</p>
  
  <p>We still don't know what changed to make the site suddenly not work, but at least the control panel is usable.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-20T02:09:08.203Z
Answers.Text: Glad you got it sorted!
Answers.UserDisplayName: Brad Bell
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-08-28T22:29:33.183Z
Answers.Text: What was the actual solution to this? I'm running into the same thing.
Answers.UserDisplayName: hisnameisjimmy
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-09-11T11:36:43.527Z
Answers.Text: The actual solution was to remove the nginx lines that removed the cookies.
Answers.UserDisplayName: user6137
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-01-18T20:04:44.330Z
Answers.LastActivityDate: 2017-01-18T20:04:44.330Z
Answers.UserDisplayName: user6137
Body: <p>I have an existing CMS website that seemingly has been working fine for several months.  Just recently we have lost the ability to access the admin portion of the site (the rest of the site works well).  To our knowledge, nothing has changed to make the site behave differently.</p>
  
  <p>We have since set up our own dev box with identical code and it seems to behave the same way.  Works one day, next day we can't log in.  No errors in browser or log files.  Browser cache and cookies cleared.  Different browsers all work the same way.  You log in, it blinks a second, then redirects to login.  If wrong password entered, we get the wrong password error.  Even the database seems to show our login was good.</p>
  
  <p>We have multiple environments on the original site, only the production environment has this issue.  Our second environment only has the production environment so i don't think they are conflicting.</p>
  
  <p>Only thing i can think of is nginx cache but we don't cache the admin directories.  I don't see anything different in .htaccess that would do this.</p>
  
  <p>Any ideas?</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-01-16T13:44:22.573Z
Comments.Text: Our current theory is that we somehow voided Crafts licensing and they are not letting us use the control panel.  We are not sure the best way to contact them on this issue.
Comments.UserDisplayName: user6137
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-01-16T22:20:31.230Z
Comments.Text: Pretty strange. Try trashing the entire contents of your `/craft/storage` folder, see if that helps.
Comments.UserDisplayName: Lindsey D
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-09-09T12:27:25.503Z
Comments.Text: Just to firmly debunk your theory for future readers, @rscott6666 – Craft will *not* lock you out of your control panel if your license is invalid, it'll simply display an annoying alert.
Comments.UserDisplayName: Mats Mikkel Rummelhoff
Tags: <login>
Title: CMS login redirects to back to login
ThreadText: # CMS login redirects to back to login
  
  (Asked by: username_0 on 2017-01-15)
  
  I have an existing CMS website that seemingly has been working fine for several months. Just recently we have lost the ability to access the admin portion of the site (the rest of the site works well). To our knowledge, nothing has changed to make the site behave differently.
  
  We have since set up our own dev box with identical code and it seems to behave the same way. Works one day, next day we can't log in. No errors in browser or log files. Browser cache and cookies cleared. Different browsers all work the same way. You log in, it blinks a second, then redirects to login. If wrong password entered, we get the wrong password error. Even the database seems to show our login was good.
  
  We have multiple environments on the original site, only the production environment has this issue. Our second environment only has the production environment so i don't think they are conflicting.
  
  Only thing i can think of is nginx cache but we don't cache the admin directories. I don't see anything different in .htaccess that would do this.
  
  Any ideas?
  
  **Tags:** login
  
  > **Comments:**
  > **username_0**: Our current theory is that we somehow voided Crafts licensing and they are not letting us use the control panel.  We are not sure the best way to contact them on this issue.  
  > **username_1**: Pretty strange. Try trashing the entire contents of your `/craft/storage` folder, see if that helps.  
  > **username_2**: Just to firmly debunk your theory for future readers, @rscott6666 – Craft will *not* lock you out of your control panel if your license is invalid, it'll simply display an annoying alert.  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_3 on 2017-09-09. Score: 2
  
  Just want to chime in with what fixed this for me.
  
  I had the same issue and it was the Nginx configuration. Specifically, the order that I some of my location and cache settings.
  
  To get it working, I strictly followed the order from this: <https://nystudio107.com/blog/static-caching-with-craft-cms>
  
  
  ---
  
  ### Answer by username_0 on 2017-01-18. Score: 2
  
  Sorry for answering my own question.
  
  Upon a suggestion from P&T, we found that our Nginx configuration was removing the cookies when it cached the page. When we left the cookies in, we were able to log in.
  
  We still don't know what changed to make the site suddenly not work, but at least the control panel is usable.
  
  > **Comments:**
  > **username_4**: Glad you got it sorted!  
  > **username_5**: What was the actual solution to this? I'm running into the same thing.  
  > **username_0**: The actual solution was to remove the nginx lines that removed the cookies.  
  
  ---
  
  