Join the community today
Register Now

htpasswd.sh does not work anymore one a domain

Discussion in 'Install & Upgrades or Pre-Install Questions' started by EckyBrazzz, May 5, 2019.

  1. EckyBrazzz

    EckyBrazzz Active Member

    459
    90
    28
    Mar 28, 2018
    Brazil
    Ratings:
    +170
    Local Time:
    4:22 PM
    1.17.x
    10.3.x
    In my vhost I have:
    Code (Text):
    location ~* /(wp-login\.php) {
        limit_req zone=xwplogin burst=1 nodelay;
        #limit_conn xwpconlimit 30;
        auth_basic "Privatehtpasswd.sh";
        auth_basic_user_file /home/nginx/domains/$vhost/htpasswd_wplogin;
        include /usr/local/nginx/conf/php-wpsc.conf;
    
        # https://community.centminmod.com/posts/18828/
        #include /usr/local/nginx/conf/php-rediscache.conf;
    }
    

    The file /home/nginx/domains/$vhost/htpasswd_wplogin exist owner:group(root:nginx)

    But when loggin into the site it don't asks for a login/password, but says it is not enabled.

    Code (Text):
    You are about to log in to the site “domain.com” with the username “XXXXXXXXXXXXX”, but the website does not require authentication. This may be an attempt to trick you.
    
    Is “domain.com” the site you want to visit?
    


    What could be wrong ?
     
  2. EckyBrazzz

    EckyBrazzz Active Member

    459
    90
    28
    Mar 28, 2018
    Brazil
    Ratings:
    +170
    Local Time:
    4:22 PM
    1.17.x
    10.3.x
    Quick Solution: Downloaded the domain, deleted the entries in CMM, created it again, changed DB setting, uploaded the domain, ready. Time to sleep, cause woke up with mouse in my hand and hitting the enter key! Almost hitting the max time again to stay awake.
     
  3. eva2000

    eva2000 Administrator Staff Member

    40,620
    9,015
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,881
    Local Time:
    5:22 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    for
    Code (Text):
    location ~* /(wp-login\.php) {
       limit_req zone=xwplogin burst=1 nodelay;
       #limit_conn xwpconlimit 30;
       auth_basic "Privatehtpasswd.sh";
       auth_basic_user_file /home/nginx/domains/$vhost/htpasswd_wplogin;
       include /usr/local/nginx/conf/php-wpsc.conf;
    
       # https://community.centminmod.com/posts/18828/
       #include /usr/local/nginx/conf/php-rediscache.conf;
    }
    

    i assume using $vhost is just a placeholder for public masking of your real domain ? if not that that is why the HTTP password protection didn't work as nginx could find the htpasswd_wplogin file as /home/nginx/domains/$vhost/htpasswd_wplogin would be an invalid path.
     
    style="display:inline-block;min-width:400px;max-width:970px;width:95%;height:90px" data-ad-client="ca-pub-6669518204467592" data-ad-slot="4024536743" data-ad-format="auto">
  4. EckyBrazzz

    EckyBrazzz Active Member

    459
    90
    28
    Mar 28, 2018
    Brazil
    Ratings:
    +170
    Local Time:
    4:22 PM
    1.17.x
    10.3.x
    That SecureFX is sometime really slow. Still downloading the wp-content folder. Don't know how to set that one up to download a folder in parallel.
     
  5. eva2000

    eva2000 Administrator Staff Member

    40,620
    9,015
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,881
    Local Time:
    5:22 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    upload_2019-5-5_21-15-23.png
     
  6. EckyBrazzz

    EckyBrazzz Active Member

    459
    90
    28
    Mar 28, 2018
    Brazil
    Ratings:
    +170
    Local Time:
    4:22 PM
    1.17.x
    10.3.x
    Yes, did that, but it is not the same as in Filezilla, FileZilla place the downloads in a que and download them lots quicker. Now SecureFX keeps on on folder, downloading file per file.

    But made a quick workaround with tar -pcvzf and downloaded that one.

    And another bad news, firefox plugins disabled. Issue should be fixed Unable to install add-ons (Download failed. Please check your connection.) · Issue #851 · mozilla/addons but they don't keep the promised time. Nightly build works, but missing bookmarks
     
  7. eva2000

    eva2000 Administrator Staff Member

    40,620
    9,015
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,881
    Local Time:
    5:22 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    Yeah read about firefox addons being broken due to expired intermediate ssl certificate ! I use Opera and Chrome so no big deal :)

    As to SecureFX you can try to uncheck transfer queue

    upload_2019-5-6_0-21-5.png

    But yes I also download zipped/tarred compressed single files as it's much faster generally and with tar you preserve the file /directory permissions :) ;)
     
  8. EckyBrazzz

    EckyBrazzz Active Member

    459
    90
    28
    Mar 28, 2018
    Brazil
    Ratings:
    +170
    Local Time:
    4:22 PM
    1.17.x
    10.3.x
    I use Chrome a lot, but due to the fact when I have some time over 100+ tabs open it get stuck, won't allow to load a new site or refresh an old one without a forced quit or even system reboot.

    FireFox seems to fix the issue, I can add my extensions again. So, goodbye Nightly built and ganna stick to the beta for a while. Yeah, will give Opera a try again, last time I used it was in a Linux distro. Comes always in hand to have a second good browser.

    SecureFX, well we have the same settings but maybe confusing, in FileZilla you see the Queue and that it's working on max. 10 files at the same time. Now I only see one line (well this case I started the wp-content dir to test), stays at 98-100% and downloads and the Size of File an Bytes Transferd growing. Don't see a good progress bar, but as it is a package together with SecureCRT I'm happy with it. (Got my hands on the new beta scrt_sfx-x64.8.6.0.1917 build for testing --:) better speeds are coming in the next release.) Used it in a VMware only for testing, cause it's only valid for a short time/date. secureFX.png
     
  9. eva2000

    eva2000 Administrator Staff Member

    40,620
    9,015
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +13,881
    Local Time:
    5:22 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    With SecureCRT/SecureFX in advanced settings for SFTP/SCP at least you can tune the ssl cipher and key exchange alogorithms used too - some would be faster than others so picking one with balance of speed vs security might help though ultimately depends on speed of your own ISP connection.
     
    • Informative Informative x 1