Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't access to page ending with rc when using generated .htaccess #652

Closed
2 tasks done
wtfred opened this issue Feb 19, 2019 · 5 comments
Closed
2 tasks done

Can't access to page ending with rc when using generated .htaccess #652

wtfred opened this issue Feb 19, 2019 · 5 comments

Comments

@wtfred
Copy link
Contributor

wtfred commented Feb 19, 2019

Bug Report

Prerequisites

  • Can you reproduce the problem on TYPO3 v9.5 LTS
  • Did you perform a cursory search to see if your bug or enhancement is already reported?

Description

Any slug ending with rc cause 403 when .htaccess was generated by bootstrap_package

Steps to Reproduce

  1. Have bootstrap_package generate .htaccess
  2. Name a page randomrc or just rename the slug of an existing page to make it end with rc
  3. Try to access to the page using the slug

Expected behavior: Page display

Actual behavior: Error 403

Problem comes from lines https://github.com/benjaminkott/bootstrap_package/blob/master/Configuration/Server/_.htaccess#L315 and https://github.com/benjaminkott/bootstrap_package/blob/master/Configuration/Server/_.htaccess#L323, maybe should end with (?:~|\.rc))$#"> instead of (?:~|rc))$#">
(Thanks to Mathias Brodala for pointing me the cause!)

@benjaminkott
Copy link
Owner

@wtfred thx for pointing this out, i´ve double checked this with the typo3 configuration file and it seems that this one also hat the same problem.

https://github.com/TYPO3/TYPO3.CMS/blame/f9ea59ca7275b4dbfa8b118fc3e5e44c65b90547/typo3/sysext/install/Resources/Private/FolderStructureTemplateFiles/root-htaccess#L323

@mbrodala do you think we also need to change it there?

@benjaminkott
Copy link
Owner

was added here TYPO3/typo3@edd2a1c

@mbrodala
Copy link
Contributor

Yes, the .htaccess of TYPO3 should be adjusted to cover .rc (thus file resources) instead of rc.

@lolli42
Copy link
Contributor

lolli42 commented Feb 25, 2019

I created core patch https://forge.typo3.org/issues/87783 to deal with this. If this has been decided and a merge has happened, we may afterwards put that into BP_8-0 branch of bootstrap package to Configuration/Apache/.htaccess. Other BP branches are not affected since bootstrap package branch v8 only creates that file on its own, in v9 and v10 this is done by core.

@benjaminkott
Copy link
Owner

thx @lolli42 applied the patch also here and voted the one on core, will backport them later to the branches.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants