Vote #80939
完了robots.txt: disallow crawling login, register, and lost password form
0%
説明
The attached patch adds robots exclusion tags (@@) to login, register, and lost password form.
Currently, Redmine allows web crawlers such as Googlebot and Baiduspider to index those forms. I think it is undesirable for the following reasons:
- There is no meaningful information there
- If the Redmine instance requires login, probably the admin doesn't want to publish any information to the internet. It is so bad to be indexed by Google
That can be resolved by the attached patch by adding robots exclusion tags to the pages.
journals
Added tests to the patch.
--------------------------------------------------------------------------------
Setting the target version to 4.2.0.
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
Committed the patch.
--------------------------------------------------------------------------------
Redmine already generates a @robots.txt@ in @welcome#robots@. Wouldn't this be better suited there, specifically in source:trunk/app/views/welcome/robots.text.erb so that we have a single location where we define behavior for robots?
--------------------------------------------------------------------------------
Holger Just wrote:
> Redmine already generates a @robots.txt@ in @welcome#robots@. Wouldn't this be better suited there, specifically in source:trunk/app/views/welcome/robots.text.erb so that we have a single location where we define behavior for robots?
You are absolutely right. I forgot about the existence of robots.txt for some reason.
The attached new patch uses robots.txt instead of robots meta tag.
--------------------------------------------------------------------------------
Looks good to me, thanks!
--------------------------------------------------------------------------------
Committed patch #33658#note-6.
--------------------------------------------------------------------------------