• Resolved wburling1

    (@wburling1)


    Not sure if this has been discussed before but asking again.
    I have an external database where the username and password fields are in normal text. I want to use this database with the external login plugin but do not know how to make the password change so the the plugin will allow users log in with their current password.
    I also am not sure where I set a separate salt for each password.
    Thanks for any help on this.
    Wayne

Viewing 15 replies - 16 through 30 (of 42 total)
  • Thread Starter wburling1

    (@wburling1)

    I am not familiar with how to read the php logs, when I opened the last one it is very large and to unreadable. Is there a way I can forward it to you to check?
    Wayne

    Thread Starter wburling1

    (@wburling1)

    Tom,
    Could my problems be because I am using an old version of php 5.6?
    If I change to a newer version, it will break the current site.
    And I do not have enough available databases to create a duplicate site.
    Wayne

    Plugin Author tbenyon

    (@tbenyon)

    Hey Wayne,

    I just switched my PHP version to 5.6.32 and everything worked fine for me.

    If you would like to go back to that php error log file and copy the last 20 lines in here (if there’s anything useful) that’d be helpful.

    If not the next step is probably for me to add a new feature to the plugin that would generate:

    • A list of the current settings (without sensitive information)
    • A tickbox to add additional loggin to the error log file
    • Load the last 30 lines from the php error log file that are external login relavent

    Users could then paste this information into support forms so that I can further help diagnose the problem.

    Plugin Author tbenyon

    (@tbenyon)

    Hey Wayne,

    I think I may have found the issue if your hashing algorithm is set to ‘none’.
    The issue is in the following file in the plugin:
    login/validate_password.php
    Current line:
    if ($algorithm == "bcrypt" || $algorithm == "phpass" || $algorithm == "phpcrypt") {

    The line should read:
    if ($algorithm == "bcrypt" || $algorithm == "phpass" || $algorithm == "phpcrypt" || $algorithm == "none") {

    If you can test this that’d be great.

    You could also prove this is correct by typing in a completely lower case version of the password as this should authenticate you.

    I’m going to get this fix into the next release ??

    Thread Starter wburling1

    (@wburling1)

    Tom,
    I made the changes to the login/validate_password.php file and it allowed me to log in with my admin userid, however, it still does not allow other users that do not have a WP userid but have a userid in the external database. I created 2 dummy users in the external database and then tried to log into wp but still get the (ERROR: Invalid username. Lost your password?) error.
    I will try to find the php log and post it here.
    Wayne

    Thread Starter wburling1

    (@wburling1)

    Here is what I found from June 10 but did not find anything for today when I tried to login with dummy ids. Hope this helps Wayne

    [04-Jun-2019 23:13:30 UTC] PHP Parse error: syntax error, unexpected ‘:’ in /home/vwca1/public_html/vwwordpress/wp-content/plugins/php-code-for-posts/Classes/Shortcode.php(283) : eval()’d code on line 73
    [04-Jun-2019 23:13:58 UTC] PHP Parse error: syntax error, unexpected ‘:’ in /home/vwca1/public_html/vwwordpress/wp-content/plugins/php-code-for-posts/Classes/Shortcode.php(283) : eval()’d code on line 73
    [04-Jun-2019 23:15:18 UTC] PHP Parse error: syntax error, unexpected ‘:’ in /home/vwca1/public_html/vwwordpress/wp-content/plugins/php-code-for-posts/Classes/Shortcode.php(283) : eval()’d code on line 73
    [10-Jun-2019 12:40:17 UTC] PHP Warning: mysqli::mysqli(): (28000/1045): Access denied for user ‘vw_wayne’@’localhost’ (using password: YES) in /home/vwca1/public_html/vwwordpress/wp-content/plugins/php-code-for-posts/Classes/Shortcode.php(283) : eval()’d code on line 8
    [10-Jun-2019 12:40:17 UTC] PHP Warning: mysqli_connect(): (28000/1045): Access denied for user ‘vw_wayne’@’localhost’ (using password: YES) in /home/vwca1/public_html/vwwordpress/wp-content/plugins/php-code-for-posts/Classes/Shortcode.php(283) : eval()’d code on line 16
    [10-Jun-2019 12:42:04 UTC] PHP Warning: mysqli_query(): Empty query in /home/vwca1/public_html/vwwordpress/wp-content/plugins/php-code-for-posts/Classes/Shortcode.php(283) : eval()’d code on line 112
    [10-Jun-2019 12:44:46 UTC] PHP Warning: mysqli_query(): Empty query in /home/vwca1/public_html/vwwordpress/wp-content/plugins/php-code-for-posts/Classes/Shortcode.php(283) : eval()’d code on line 112
    [10-Jun-2019 12:45:20 UTC] PHP Warning: mysqli_query(): Empty query in /home/vwca1/public_html/vwwordpress/wp-content/plugins/php-code-for-posts/Classes/Shortcode.php(283) : eval()’d code on line 112

    Thread Starter wburling1

    (@wburling1)

    Tom,
    Just finally found this log.
    Wayne

    68.41.220.8 – – [15/Jun/2019:05:01:53 -0700] “POST /wp-admin/admin-ajax.php HTTP/1.1” 200 108 “https://vwwordpress.vwclub.org/wp-admin/” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:03:54 -0700] “POST /wp-admin/admin-ajax.php HTTP/1.1” 200 67 “https://vwwordpress.vwclub.org/wp-admin/” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:05:58 -0700] “GET /wp-login.php?redirect_to=http%3A%2F%2Fvwwordpress.vwclub.org%2Fwp-admin%2F&reauth=1 HTTP/1.1” 200 1480 “-” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:06:53 -0700] “POST /wp-login.php HTTP/1.1” 302 – “https://vwwordpress.vwclub.org/wp-login.php?redirect_to=http%3A%2F%2Fvwwordpress.vwclub.org%2Fwp-admin%2F&reauth=1” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:06:54 -0700] “GET /wp-admin/ HTTP/1.1” 200 27032 “https://vwwordpress.vwclub.org/wp-login.php?redirect_to=http%3A%2F%2Fvwwordpress.vwclub.org%2Fwp-admin%2F&reauth=1” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:07:55 -0700] “POST /wp-admin/admin-ajax.php HTTP/1.1” 200 67 “https://vwwordpress.vwclub.org/wp-admin/” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:15 -0700] “GET /wp-admin/plugins.php HTTP/1.1” 200 28827 “https://vwwordpress.vwclub.org/wp-admin/” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-content/plugins/all-in-one-wp-migration/lib/view/assets/css/updater.min.css?v=6.97&ver=5.2.1 HTTP/1.1” 200 1308 “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-content/plugins/all-in-one-wp-migration/lib/view/assets/javascript/util.min.js?v=6.97&ver=5.2.1 HTTP/1.1” 200 2185 “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-content/plugins/all-in-one-wp-migration/lib/view/assets/javascript/updater.min.js?v=6.97&ver=5.2.1 HTTP/1.1” 200 1867 “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-admin/load-styles.php?c=1&dir=ltr&load%5B%5D=dashicons,admin-bar,common,forms,admin-menu,dashboard,list-tables,edit,revisions,media,themes,about,nav-menus,wp-pointer,widgets&load%5B%5D=,site-icon,l10n,buttons,wp-auth-check,media-views&ver=5.2.1 HTTP/1.1” 304 – “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-includes/js/shortcode.min.js?ver=5.2.1 HTTP/1.1” 200 1138 “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-admin/load-scripts.php?c=1&load%5B%5D=hoverIntent,common,admin-bar,underscore,wp-util,wp-a11y,updates,jquery-ui-core,thickbox,plugin-install,svg-painter&ver=5.2.1 HTTP/1.1” 304 – “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-includes/js/jquery/ui/widget.min.js?ver=1.11.4 HTTP/1.1” 200 2599 “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-admin/images/spinner.gif HTTP/1.1” 304 – “https://vwwordpress.vwclub.org/wp-admin/load-styles.php?c=1&dir=ltr&load%5B%5D=dashicons,admin-bar,common,forms,admin-menu,dashboard,list-tables,edit,revisions,media,themes,about,nav-menus,wp-pointer,widgets&load%5B%5D=,site-icon,l10n,buttons,wp-auth-check,media-views&ver=5.2.1” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-includes/js/jquery/ui/sortable.min.js?ver=1.11.4 HTTP/1.1” 200 6550 “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:08:16 -0700] “GET /wp-includes/js/jquery/ui/mouse.min.js?ver=1.11.4 HTTP/1.1” 200 1021 “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”
    68.41.220.8 – – [15/Jun/2019:05:09:18 -0700] “POST /wp-admin/admin-ajax.php HTTP/1.1” 200 67 “https://vwwordpress.vwclub.org/wp-admin/plugins.php” “Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.90 Safari/537.36”

    Thread Starter wburling1

    (@wburling1)

    Tom,
    I have been gone for a couple of weeks, and am just trying again to get this working. I decided to start from scratch, I have installed and activated the plugin from wordpress. I still can not get this to work. I have done the test connection and it works fine, but when I try to log in with a user that is in the external database but not in the WP database it gives me the invalid user or password error. Can you tell me if there is something that I am doing incorrectly.
    Thanks
    Wayne

    Thread Starter wburling1

    (@wburling1)

    Plugin Author tbenyon

    (@tbenyon)

    Hey @wburling1,

    I can see the issue!

    You simply need to check the box that says ‘Enable External Login’.

    This is here so that you don’t lock yourself out of the admin area while you’re making sure the test works.

    Ticking this activates the plugin.

    Let me know if this works. ??

    Thanks,

    Tom

    Thread Starter wburling1

    (@wburling1)

    Tom,
    I checked the box and saved changes. Then I logged out of my admin user and tried to log back in with the admin user and that worked. I then logged out again and this time tried to log in with another userid from the external database and it gives me the Invalid User Id or Password. My question is that the password in the external database is in normal text. Does the External Login plugin check for a hashed password when it checks the external database if the user is not in the WP-User database? Wayne

    Plugin Author tbenyon

    (@tbenyon)

    It will always check the external database password using the “Hash Type” setting.

    If it is set to ‘none’ it will assume the passwords are in plain text.

    Thread Starter wburling1

    (@wburling1)

    Tom,
    Ok how or where do I set it to “none”? You made a change to check it but not sure where I set it or check it.
    Wayne

    Plugin Author tbenyon

    (@tbenyon)

    At the bottom of the “Hash Type” setting dropdown is the option “None”.

    Thread Starter wburling1

    (@wburling1)

    Tom, Thank you so much it is working now.
    Now all I have to do is use the hook you put in and have it update the external database.
    Might be back in touch for help with that though.
    Wayne

Viewing 15 replies - 16 through 30 (of 42 total)
  • The topic ‘Adding Salt’ is closed to new replies.