Forum Replies Created

Viewing 5 replies - 1 through 5 (of 5 total)
  • I’m having trouble with vantage theme and using the rel=0 directive to youtube not working to suppress related videos being shown at the end of playback.

    Mark Ark Ark, can you please post a link to the other thread you found helpful? Are you getting the rel=0 directive to work? Presently, I’m just inserting the video link without any html around it like the iframe you have above.

    Thread Starter WilliamKF

    (@williamkf)

    @*B.V.Ramanarao* I’m self hosted, so won’t be exceeding my hosting provider’s terms.

    I’m still unclear on how to “just single UserAgent or Host name Banning”. What UserAgent or Host name would I be banning?

    Thread Starter WilliamKF

    (@williamkf)

    @*B.V.Ramanarso* I have a blank list of banned User Agents, I’m not using this feature and I’m not clear on what I would put in that list. The addition of 192.99.152.38 to my banned hosts seems to be the cause of the failure. That host got 404 file not found too many times and ended up on the permanently banned list, once it appeared, the site stopped working. It would be nice to find the log files for the “Internal Server Error” to know exactly what is going wrong, but I was unable to locate them.

    What would I use in the Ban User Agents to ban user agents and rogue bots that are trying to hack my site?

    Thread Starter WilliamKF

    (@williamkf)

    I deleted the plugin and reinstalled it, all worked fine until I did the tweaks section and the .htaccess was edited to add:

    # BEGIN Tweaks
    		# Rules to block access to WordPress specific files
    		<files .htaccess>
    			Order allow,deny
    			Deny from all
    		</files>
    		<files readme.html>
    			Order allow,deny
    			Deny from all
    		</files>
    		<files readme.txt>
    			Order allow,deny
    			Deny from all
    		</files>
    		<files install.php>
    			Order allow,deny
    			Deny from all
    		</files>
    		<files wp-config.php>
    			Order allow,deny
    			Deny from all
    		</files>
    
    		# Rules to disable directory browsing
    		Options -Indexes
    
    		<IfModule mod_rewrite.c>
    			RewriteEngine On
    
    			# Rules to protect wp-includes
    			RewriteRule ^wp-admin/includes/ - [F]
    			RewriteRule !^wp-includes/ - [S=3]
    			RewriteCond %{SCRIPT_FILENAME} !^(.*)wp-includes/ms-files.php
    			RewriteRule ^wp-includes/[^/]+\.php$ - [F]
    			RewriteRule ^wp-includes/js/tinymce/langs/.+\.php - [F]
    			RewriteRule ^wp-includes/theme-compat/ - [F]
    
    			# Rules to prevent php execution in uploads
    			RewriteRule ^(.*)/uploads/(.*).php(.?) - [F]
    
    			# Rules to block unneeded HTTP methods
    			RewriteCond %{REQUEST_METHOD} ^(TRACE|DELETE|TRACK) [NC]
    			RewriteRule ^(.*)$ - [F]
    
    			# Rules to block suspicious URIs
    			RewriteCond %{QUERY_STRING} \.\.\/ [NC,OR]
    			RewriteCond %{QUERY_STRING} ^.*\.(bash|git|hg|log|svn|swp|cvs) [NC,OR]
    			RewriteCond %{QUERY_STRING} etc/passwd [NC,OR]
    			RewriteCond %{QUERY_STRING} boot\.ini [NC,OR]
    			RewriteCond %{QUERY_STRING} ftp\:  [NC,OR]
    			RewriteCond %{QUERY_STRING} http\:  [NC,OR]
    			RewriteCond %{QUERY_STRING} https\:  [NC,OR]
    			RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]
    			RewriteCond %{QUERY_STRING} mosConfig_[a-zA-Z_]{1,21}(=|%3D) [NC,OR]
    			RewriteCond %{QUERY_STRING} base64_encode.*\(.*\) [NC,OR]
    			RewriteCond %{QUERY_STRING} ^.*(\[|\]|\(|\)|<|>|?a|"|;|\?|\*|=$).* [NC,OR]
    			RewriteCond %{QUERY_STRING} ^.*("|'|<|>|\|{||).* [NC,OR]
    			RewriteCond %{QUERY_STRING} ^.*(%24&x).* [NC,OR]
    			RewriteCond %{QUERY_STRING} ^.*(127\.0).* [NC,OR]
    			RewriteCond %{QUERY_STRING} ^.*(globals|encode|localhost|loopback).* [NC,OR]
    			RewriteCond %{QUERY_STRING} ^.*(request|concat|insert|union|declare).* [NC]
    			RewriteCond %{QUERY_STRING} !^loggedout=true
    			RewriteCond %{QUERY_STRING} !^action=jetpack-sso
    			RewriteCond %{QUERY_STRING} !^action=rp
    			RewriteCond %{HTTP_COOKIE} !^.*wordpress_logged_in_.*$
    			RewriteCond %{HTTP_REFERER} !^https://maps\.googleapis\.com(.*)$
    			RewriteRule ^(.*)$ - [F]
    
    			# Rules to block foreign characters in URLs
    			RewriteCond %{QUERY_STRING} ^.*(%0|%A|%B|%C|%D|%E|%F).* [NC]
    			RewriteRule ^(.*)$ - [F]
    		</IfModule>
    	# END Tweaks

    Which gets errors:

    .htaccess: Invalid command ‘Order’, perhaps misspelled or defined by a module not included in the server configuration

    Forum: Hacks
    In reply to: How to unlock user?
    Thread Starter WilliamKF

    (@williamkf)

    I resolved this:

    In MySQL there are two tables that you can edit to clone the locked out user and make a new user that is not locked out:

    wp_users
    wp_usermeta
    In wp_users table find the locked out user row and copy it but supply new unique entries for the new user name for these columns along the lines given here:

    user_login: ‘oldUser1’ -> ‘newUser2’
    user_nicename: ‘OldUser’ -> ‘CloneUser’
    display_name: ‘User1’ -> ‘User2’
    ID: 2 -> 3
    Next, in the wp_usermeta table, copy the 18 rows that match user_id 2 and make new rows with user_id 3. For row with meta_key column value nickname give a new value.

    Having done all this, you may restart your apache server and now login using the User2 with your original password that was copied from User1 and you will have the same privileges as before and not be locked out.

Viewing 5 replies - 1 through 5 (of 5 total)