Jump to content

No errors — but I cannot get past the login page on a new install


ErikMH
 Share

Recommended Posts

I’m new to Processwire. I’ve installed the current release version at my very-long-time (25 years) host, pair Networks. MySQL db is created. Installation process completed with no errors.

I’m now trying to log in. Rather than taking the default `/admin` suggestion, I chose `/xyzzy`. When I go to `example.com/xyzzy`, PW displays a login screen, as expected. I enter the username (`xyzzy`) and password that I assigned (and copied and stored in 1Password) in the installation process (five words separated by hyphens). So far, so good.

I would expect then to be taken to the admin pages. Or (if I got something wrong) to be given an error message. Instead, I’m taken to the URL `example.com/xyzzy/page/?login=1`, which as far as I can tell is exactly the same as the initial login page. No error is given.

I grew so frustrated by this, that I deleted the entire installation and the MySQL database, re-downloaded PW, installed it again using a different username and password for the admin account.

And I’m seeing exactly the same behavior. Time for me to ask you experts: WTF?

Many thanks for any insights you may have....

 

Link to comment
Share on other sites

Sorry if this is a silly / obvious thing, but please note that setting the page name for the admin to xyzzy doesn't also set the admin/superuser's name to xyzzy as well. Did you explicitly set it to xyzzy as well?

Link to comment
Share on other sites

31 minutes ago, elabx said:

Can you try on site/config.php:



$config->sessionFingerprint = false;
$config->sessionChallenge = false;

 

Those were not in the file to un-comment, so I added them. Not knowing where to put them, I put them at the very top of the file.

And — bingo! — I can log in! Yea! Thank you!

Now.... Can you tell me what I’ve done, why those lines weren’t already in the file, and where I should actually put them in the file?

17 minutes ago, adrian said:

Sorry if this is a silly / obvious thing, but please note that setting the page name for the admin to xyzzy doesn't also set the admin/superuser's name to xyzzy as well. Did you explicitly set it to xyzzy as well?

Not at all — that’s an excellent question. I did explicity set it that way — but you’re right: I should’ve explicitly mentioned it here. Thanks for thinking of it!

Link to comment
Share on other sites

2 hours ago, ErikMH said:

Can you tell me what I’ve done, why those lines weren’t already in the file, and where I should actually put them in the file?

That's a very good question haha, it just happened to me just today when moving a live site to local development for some upgrades and found the recommendation around the forum, I didn't dig much deeper into the exact issue with the fingerprint and the change of environment. 

Though I can tell you I noticed that had to be related to the fingerprint because the session log shows a message about it. You should still be able to something under /site/assets/log/session.txt. 

I can also tell you that those lines are not originally on the file because the site/config.php file is sort of an "override" to the more complete wire/config.php. So in that link I pasted you can see the whole  configuration, and on the site/config.php file you specify exact details of your installation. I don't think the order is really relevant on this files as the values defined are used further in the actual execution of the ProcessWire scripts. 

 

  • Like 1
Link to comment
Share on other sites

Excellent, @elabx — thank you again. It turns out it was the fingerprinting (not the sessionChallenge) — and I’m guessing it’s because I’m using Cloudflare’s 1.1.1.1 WARP for my local connection. I’ve removed the sessionChallenge override, and moved the sessionFingerprint line down in site/config.php to the spot that would correspond to where it is in wire/config.php. Everything’s still working, so I’m happy and I’ve learned something. Thanks!

Onwards, through the fog!

  • Like 2
Link to comment
Share on other sites

Is your site using or running on the Cloudflare CDN as well?

If so you might want to add custom page rules in Cloudflare to disable all kinds of caching for /youradminarea/*.

Because that really interferes with your ProcessWire session and can make life quite hard.

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By Marvin
      Hi,
      I'm still new at processwire, i want to ask, i was create a website with sign in system, but i want to add a access roles/permission for each user at my website. For now, i just can create a login user without any permission and the user data became as a pages in my processwire.
      Here i attach my code for login
      <?php $note = $note2 = $hidden =""; if($input->get->id == "logout") { $session->remove('login_id'); } if($input->post->submit) { $email = $sanitizer->email($input->post->email); $pass = $sanitizer->text($input->post->pass); $result = $pages->find("email=$email, text_1=$pass"); if(!$email || !$pass) { $note = "Data belum lengkap"; } else { if($result->count > 0) { $session->login_id = "$result"; $hidden = "style = 'diplay:none'"; $url=$pages->get("/files/")->httpUrl; header("Location:$url"); die(); } else { $note = "Akun tidak ditemukan"; } } } ?> And this code for login form
      <div class="frow-container"> <div class="frow centered mt-50"> <div class="col-md-1-3"> <div class="box p-40 shadow-light"> <h2 class="mb-20 text-center" <?=$hidden?>>Database Partitur<br>GII HIT</h2> <form method="post" <?=$hidden?>> <label>Username <input type="text" name="email"></label> <label>Password <input type="password" name="pass"></label> <input type="submit" name="submit" value="Masuk"> </form> <p class="notif"><?=$note;?></p> <div class="text-center"><?=$note2;?></div> </div> </div> </div> </div> Just for remember, my user data now is a pages, and i cannot give any permission to user data.
      Thank you very much for help.
    • By kyksh
      Hi!
      I need users to login by their email address. This works when I change the value in ProcessLogin.module
       122     protected $useEmailLogin = null;
      to
      122     protected $useEmailLogin = true;
      What would be a recommended way to enable this?
      There's this line in ProcessLogin.module:
        15  * @property bool|int $allowEmail Whether or not email login is allowed (0|false=off, 1|true=Yes, 2=Yes or name also allowed)
      But I can't figure out how to set this. I tried next to $useEmailLogin in ProcessLogin.module and in config.php, but neither takes effect.
      BTW I tried module LoginWithEmail but it seems outdated. My PW version is 3.0.165
    • By Grigorij Schleifer
      Hello processwire community, I am a total CMS beginner and I am trying to install processwire on my mac.
      I have downloaded processwire using git and loaded the location, where the files where downloaded into chrome, safary or opened the location from the terminal. No installation guide startet. I just typed the directory location into the browsers url address bar and could see all the files that were downloaded. When I tried to open installl.php file, my browser just showed me the code.
      I think I am missing something trivial. Do I need to install a specific PHP version and MySQL first? Or do I need to set up an Apache server first. 
      I am very thankful for every suggestion/help I can get.
      Thank you
    • By jploch
      Hey folks,
      Iam working on a new Admin Theme, based on AdminThemeReno, which I would like to release for the public soon.
      Now I want to style the login page to fit the look and feel of the backend.

      After some research, I found out that I have to set the "$config->defaultAdminTheme = 'AdminThemeName' " inside my site config.php file to load all the styles from my admin theme on the login page instead of the default ones.
      Is it possible to set this via api from my Admin Theme settings, without the need of editing the config file?
       
    • By DanielKit
      Hi. I'm currently stuck at the login page in my project. Once I enter my admin username and my password and press login, nothing happens. The page just reloads. However, the URL changes from http://myipaddress/processwire to http://myipaddress/processwire/?login=1. I've checked all of my server settings, and to my knowledge, all seems to be fine there. I don't know where to go from here.. Thanks in advance!
×
×
  • Create New...