Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't login after update to 1.2.14 #3805

Closed
ISekan opened this issue Sep 15, 2020 · 18 comments
Closed

Can't login after update to 1.2.14 #3805

ISekan opened this issue Sep 15, 2020 · 18 comments
Labels
question A question not a bug

Comments

@ISekan
Copy link

ISekan commented Sep 15, 2020

Cacti 1.2.14/Centos7/MariaDB/Apache

Users can't login after update
But I can use their logins and all's ok
In logs cacti and apache nothing criminal
It doesn't depend from browsers and cookies

@ISekan ISekan added bug Undesired behaviour unverified Some days we don't have a clue labels Sep 15, 2020
@ISekan ISekan changed the title Can't login after uptate to 1.2.14 Can't login after update to 1.2.14 Sep 15, 2020
@ISekan
Copy link
Author

ISekan commented Sep 15, 2020

I found the bug:
If first login with admin user - all works and you can log out and use others users logins without problem
If first login with no admin user - can't login

@TheWitness
Copy link
Member

This might have to do with Firefox trying real hard to cache files that have changed, namely the JavaScript files, which have changed between releases. So, maybe just that upgrade issue. We've done a number of things to "trick" the various browsers from Caching expired JavaScript and CSS, but they keep making it more difficult.

@ISekan
Copy link
Author

ISekan commented Sep 15, 2020

It doesn't matter of type browser. Also I tried to clear all cache and reinstall browsers. Working only one way - first login with admin or user with similar rights like admin

@TheWitness
Copy link
Member

Are you using the LDAP integration? Just curious.

@ISekan
Copy link
Author

ISekan commented Sep 15, 2020

@TheWitness, only Built-in Authentication

@ISekan
Copy link
Author

ISekan commented Sep 16, 2020

I use different DNS name for cacti - http://cacti.***.com.by/cacti
The problem disappears if use original server name http://srv-***cacti-02/cacti

@TheWitness
Copy link
Member

That sounds like an issue that's more up @cigamit or @netniV's alley. You should check your apache error log too.

@ISekan
Copy link
Author

ISekan commented Sep 16, 2020

No errors in apache log

@TheWitness
Copy link
Member

TheWitness commented Sep 16, 2020

You might have to share your access log's, I'm betting there are some 304's or 302's in there, and where they are redirecting ain't working. Something in the Web Server configuration. Someone reported the same problem the other day, and their $url_path variable in config.php was wrong too.

@ISekan
Copy link
Author

ISekan commented Sep 17, 2020

@TheWitness
in config.php no changes from previous version
$url_path = '/cacti/';
access log in attach
cacti_access_log.zip

thanks

@TheWitness
Copy link
Member

So, being that this appears to be a Mac, I'm not going to be of much help. It may have something to do with SameSite cookies. Go into the config.php.dist, and pull out the setting from there and disable it. The config.php has changed quite a bit in recent versions, and the SameSite implementation in PHP7 was not very robust.

@ISekan
Copy link
Author

ISekan commented Sep 17, 2020

and one more thing
http://cacti-02/ - login doesn't work
http://cacti-02/cacti/ - working

@TheWitness
Copy link
Member

Oh, that's something completely different. Put the following in your document root

index.php

<?php

header("Location:cacti/index.php");

@TheWitness
Copy link
Member

No restart required.

@TheWitness TheWitness added question A question not a bug and removed bug Undesired behaviour unverified Some days we don't have a clue labels Sep 17, 2020
@TheWitness
Copy link
Member

This is not really a bug then. Web server configuration. I'll close, you can still comment though.

@ISekan
Copy link
Author

ISekan commented Sep 17, 2020

in config.php $url_path = '/cacti/'; to $url_path = '/'; solverd the problem
thanks to cacti forum - https://forums.cacti.net/viewtopic.php?f=2&t=61184

@ISekan
Copy link
Author

ISekan commented Sep 18, 2020

Is it need to change $url_path in new versions cacti or will be solved?

@netniV
Copy link
Member

netniV commented Sep 18, 2020

You only need to do that if you keep replacing your config.php file. SameSite cookies are a bane now because whilst its improving security it also blocks doing daft things like mixing site urls which people have been doing for years. Then it suddenly looks like a software problem when really its just the browsers reaching the state of security they should have had originally anyway 👍

@github-actions github-actions bot locked and limited conversation to collaborators Dec 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
question A question not a bug
Projects
None yet
Development

No branches or pull requests

3 participants