WordPress.org

Ready to get started?Download WordPress

Forums

BulletProof Security
[resolved] Redirects from Blogger giving a 403 error (16 posts)

  1. Revery123
    Member
    Posted 1 year ago #

    After installing bulletproof and securing the .htaccess files, my redirects from my old blogger (specifically posts, not the homepage) returns 403 errors. However, when I set the .htaccess to default my redirects work again. Currently I am using the "Blogger To WordPress" plug in.

    What should I add to the .htaccess file (in bulletproof mode) to allow my redirects to work from blogger?

    http://wordpress.org/extend/plugins/bulletproof-security/

  2. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    I would need to see some of the Post URL's to tell you why they are being forbidden. Please post a couple of them. And also explain how you are currently doing the redirects. Thanks.

  3. Revery123
    Member
    Posted 1 year ago #

  4. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    So how are you doing the redirect? Where is the redirect code? is it php code? is it .htaccess code?

  5. Revery123
    Member
    Posted 1 year ago #

    I am using the "blogger to wordpress" plugin for my redirects:
    http://wordpress.org/extend/plugins/blogger-to-wordpress/

    It generates code that I replace my blogger template html with.

  6. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    Ok i see that you can generate a custom js script and add it to your blogger site and it will redirect to your WordPress site. i looked at that js script and it could cause your site to get devalued or penalized by google for using this type of redirect method. Google and other search engines recommend that you do not use of the meta http-equiv="Refresh" content="0 tag.

    Source: http://support.google.com/webmasters/bin/answer.py?hl=en&answer=79812

    This meta tag sends the user to a new URL after a certain amount of time, and is sometimes used as a simple form of redirection. However, it is not supported by all browsers and can be confusing to the user. The W3C recommends that this tag not be used. We recommend using a server-side 301 redirect instead.

    But if you are stuck with doing this method then i guess you will have to take the risk.

    Note: The blogger to wordpress plugin has not been updated in over 3 years. I cannot test that plugin for this reason and also the reason that i do not have a blogger site to test with.

    What i think you may need to do is something like this:

    the js script is doing the redirect to your site, but the plugin on your WordPress site is trying to force the redirection into a very unsafe method of redirection once the URL is redirected from your blogger site. that unsafe method is a very common simulated RFI hacking attempt -
    game-wisdom.com/?b2w=http://chronicgamedesigner.blogspot.com/2012/07/the-game-design-tax-man.html

    What you may be able to do is add 301 .htaccess redirect code to correct this unsafe redirect method.

    see this tutorial on how to do 301 .htaccess redirects >>> http://forum.ait-pro.com/forums/topic/htaccess-redirect-code-where-do-i-add-redirect-htaccess-code/

    Personally i think the whole approach is a very bad one from start to finish and you will probably just end up with a low ranking website or maybe even get penalized by Google for the redirection method you are currently using.

  7. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    Or you can of course remove/comment out the BPS security filters in your root .htaccess file that protect your website against RFI hacking attempts. If you would like that information then let me know, but personally i think you should not do this and actually find a better method to redirect your blogger site to WordPress. Thanks.

  8. Revery123
    Member
    Posted 1 year ago #

    If I use the 301 .htaccess method, do I have to include every single url? He has over 400 posts.

  9. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    You could use more sophisticated .htaccess code such as this code.

    RedirectMatch 301  ^/([^/]+)/([^/.]+)\.html$ /$1/$2/
    RedirectMatch 301  ^/([^/]+)/([^/]+)/([^/.]+)\.html$ /$1/$2/$3/
    
    Of if you need to limit it by hosts, you can use mod_rewrite:
    
    RewriteCond %{HTTP_HOST} sitename.com [NC]
    RewriteRule ^([^/]+)/([^/.]+)\.html$ /$1/$2/ [R=301,L]
    
    RewriteCond %{HTTP_HOST} sitename.com [NC]
    RewriteRule ^([^/]+)/([^/]+)/([^/.]+)\.html$ /$1/$2/$3/ [R=301,L]
  10. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    One thing i keep meaning to add to my redirect tutorial is that the "+" sign is also a "placeholder" for a back reference.

    The $1 back reference will back reference the first "+" sign, the $2 back reference will back reference the second "+" sign, etc etc etc.

  11. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

  12. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    And i went ahead and added this example of the code above to the Forum Tutorial with an explanation of how it works >>> http://forum.ait-pro.com/forums/topic/htaccess-redirect-code-where-do-i-add-redirect-htaccess-code/#back-reference-plus-sign

  13. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    Did the redirect code above work? Can this thread be resolved? Please resolve this thread if the issue has been taken care of. Thanks.

  14. Revery123
    Member
    Posted 1 year ago #

    I have not tested the code yet, I will get back to you when I do. Hopefully in a few days, thanks for the solutions.

  15. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    Yep no problem. When other folks see that you confirmed that something works then that helps them out if they have this question/issue. ;) Thanks.

  16. AITpro
    Member
    Plugin Author

    Posted 1 year ago #

    @Revery123 - resolving this thread. If this code above does not work then unresolve this thread. Thanks.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags