Today I noticed that the .htaccess file in my public_html root was modified a couple of months ago.
Before every RewriteRule line, some bot or somebody has added the following three lines:
RewriteCond %{REQUEST_URI} !^/[0-9]+\..+\.cpaneldcv$
RewriteCond %{REQUEST_URI} !^/[A-F0-9]{32}\.txt(?:\ Comodo\ DCV)?$
RewriteCond %{REQUEST_URI} !^/\.well-known/acme-challenge/[0-9a-zA-Z_-]+$
# lines above were inserted above each rewrite such as the following
RewriteRule ^home/? /index.html [QSA,END,NC]
I also noticed that I had a public_html/.well-known/acme-challenge/ empty directory. I have two questions.
- What should I make of this?
- What effect do the rewrite conditions have? My rewrites still seem to work as before.
Update
It seems to have to do with Let's Encrypt TLS cert auto-renewal, so the folder was probably created by the certification bot. But why do such a hatch job of my .htaccess? the trio of lines I pointed out appears, as I said, before every rewrite. So it adds a lot of bloat and confusion to the file.