Discover Centmin Mod today
Register Now

Wordpress autoprotect is driving me crazy

Discussion in 'Blogs & CMS usage' started by EckyBrazzz, Apr 26, 2019.

  1. eva2000

    eva2000 Administrator Staff Member

    58,893
    12,490
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,122
    Local Time:
    4:07 PM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    correction actually PHPFINFO_STANDALONE='y' is for install php fileinfo extension in a different way not for forcing PHP Fileinfo. So setting PHPFINFO='y' is enough on centmin.sh menu option 5 recompile IF you have enough memory - specifically >780,000 KB and >1023000 KB swap space as PHP Fileinfo can require ~1.5-1.6GB of memory to compile.

     
  2. EckyBrazzz

    EckyBrazzz Active Member

    917
    190
    43
    Mar 28, 2018
    >>>>Click here<<<< i'm nearby......
    Ratings:
    +363
    Local Time:
    3:07 AM
    Latest
    Latest
    Have set it to PHPFINFO='y' in the first place because I thought that setting it to PHPFINFO_STANDALONE='y' was a kind of overkill. Sorry, forgot to mention it.

    @eva2000 Thanks again for the great support!
     
  3. eva2000

    eva2000 Administrator Staff Member

    58,893
    12,490
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,122
    Local Time:
    4:07 PM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    You're welcome :)
     
  4. EckyBrazzz

    EckyBrazzz Active Member

    917
    190
    43
    Mar 28, 2018
    >>>>Click here<<<< i'm nearby......
    Ratings:
    +363
    Local Time:
    3:07 AM
    Latest
    Latest
    Guess what : Passed login to only 1 support team --> BRUTE FORCE ATTACK (install WP with option 22-1)
    Code:
    <private login>        142.44.134.139    1556993103    May 4, 2019 3:05 pm
    <private login>        206.189.172.90    1556993078    May 4, 2019 3:04 pm
    <private login>        95.85.15.251    1556993002    May 4, 2019 3:03 pm
    <private login>        185.26.122.69    1556992998    May 4, 2019 3:03 pm
    <private login>        91.223.195.146    1556992952    May 4, 2019 3:02 pm
    <private login>        178.128.163.39    1556992325    May 4, 2019 2:52 pm
    <private login>        109.70.6.188    1556992284    May 4, 2019 2:51 pm
    <private login>        190.15.198.188    1556992159    May 4, 2019 2:49 pm
    <private login>        212.63.111.87    1556992066    May 4, 2019 2:47 pm
    <private login>        35.203.66.234    1556992030    May 4, 2019 2:47 pm
    <private login>        52.17.161.35    1556991993    May 4, 2019 2:46 pm
    <private login>        178.62.249.144    1556991931    May 4, 2019 2:45 pm
    <private login>        47.104.188.241    1556991881    May 4, 2019 2:44 pm
    <private login>        14.102.145.209    1556991799    May 4, 2019 2:43 pm
    <private login>        104.131.183.84    1556991712    May 4, 2019 2:41 pm
    <private login>        154.8.159.29    1556991690    May 4, 2019 2:41 pm
    <private login>        159.65.142.52    1556991682    May 4, 2019 2:41 pm
    <private login>        139.99.160.111    1556991528    May 4, 2019 2:38 pm
    <private login>        153.120.181.196    1556991348    May 4, 2019 2:35 pm
    <private login>        192.99.58.114    1556991306    May 4, 2019 2:35 pm
    <private login>        202.28.110.204    1556991297    May 4, 2019 2:34 pm
    <private login>        159.65.145.34    1556991244    May 4, 2019 2:34 pm
    <private login>        35.231.252.44    1556991079    May 4, 2019 2:31 pm
    <private login>        198.50.207.113    1556991033    May 4, 2019 2:30 pm
    <private login>        5.144.130.12    1556991008    May 4, 2019 2:30 pm
    <private login>        104.199.154.100    1556990875    May 4, 2019 2:27 pm
    <private login>        206.189.149.115    1556990771    May 4, 2019 2:26 pm
    <private login>        66.70.197.206    1556990748    May 4, 2019 2:25 pm
    <private login>        68.183.25.103    1556990663    May 4, 2019 2:24 pm
    <private login>        139.59.80.180    1556990634    May 4, 2019 2:23 pm
     
  5. eva2000

    eva2000 Administrator Staff Member

    58,893
    12,490
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,122
    Local Time:
    4:07 PM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    confused related to autoprotect.sh ?? or totally separate issue/topic ?
     
  6. EckyBrazzz

    EckyBrazzz Active Member

    917
    190
    43
    Mar 28, 2018
    >>>>Click here<<<< i'm nearby......
    Ratings:
    +363
    Local Time:
    3:07 AM
    Latest
    Latest
    Sorry, WPML. Passed login to them and they leaked the login. Is not related to this thread. Already change the wp admin account, just figuring out how to change the htprotection.
     
  7. eva2000

    eva2000 Administrator Staff Member

    58,893
    12,490
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,122
    Local Time:
    4:07 PM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    To reset Wordpress wp-login.php HTTP password created by centmin.sh menu option 22 wordpress auto installer, you can use htpasswd.sh script
    Code (Text):
    vhostname=yourdomain.com
    /usr/local/nginx/conf/htpasswd.sh create /home/nginx/domains/$vhostname/htpasswd_wplogin USERNAME PASSWORD
    

    where, you change USERNAME to your desired username and PASSWORD to your password and change yourdomain.com to your wordpress site's domain name

    then restart nginx
    Code (Text):
    ngxrestart
     
  8. EckyBrazzz

    EckyBrazzz Active Member

    917
    190
    43
    Mar 28, 2018
    >>>>Click here<<<< i'm nearby......
    Ratings:
    +363
    Local Time:
    3:07 AM
    Latest
    Latest
    Thanks for the quick resonse. Just forgot ":" between USERNAME PASSWORD. But attack stopped for now.
     
  9. eva2000

    eva2000 Administrator Staff Member

    58,893
    12,490
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,122
    Local Time:
    4:07 PM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    no my htpasswd.sh script doesn't need semi-colon between username and password :)
     
  10. EckyBrazzz

    EckyBrazzz Active Member

    917
    190
    43
    Mar 28, 2018
    >>>>Click here<<<< i'm nearby......
    Ratings:
    +363
    Local Time:
    3:07 AM
    Latest
    Latest
    See private conversation.
     
  11. eva2000

    eva2000 Administrator Staff Member

    58,893
    12,490
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,122
    Local Time:
    4:07 PM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    the command for htpasswd.sh will create appropriately formatted htpass file with hashed password

    example creating the htpass file at /home/nginx/domains/yourdomain.com/htpasswd_wplogin will use command to create username = user1 and password = pass1
    Code (Text):
    /usr/local/nginx/conf/htpasswd.sh create /home/nginx/domains/yourdomain.com/htpasswd_wplogin user1 pass1
    
    /home/nginx/domains/yourdomain.com/htpasswd_wplogin
    contents:
    user1:$apr1$/KFa19OQ$iXx6d.QsyIw873LN1IC5w.
    


    for your wp-login.php to work, your nginx vhost should have the wp-login.php location context with uncommented directories referencing auth_basic_user_file /home/nginx/domains/yourdomain.com/htpasswd_wplogin file where yourdomain.com is your wordpress domain. If they're commented out with hash # in front, then they would be disabled.
    Code (Text):
        auth_basic "Private";
        auth_basic_user_file /home/nginx/domains/yourdomain.com/htpasswd_wplogin;
    


    Insights forum has discussion thread for various ways to password protect a directory in Centmin Mod Nginx and one is using my own created htpasswd.sh https://community.centminmod.com/threads/how-to-properly-password-protect-a-directory-or-file.579/ :)