Jump to content

Avatar name prefixed with dot

pd.

Browser, version and OS: 

-

Steps to reproduce/what were you doing before it happened?

Create image file locally with name starting with a dot and upload it as avatar

 

What happened?

Avatar uploaded but nginx returns 403 if one tries to view it.

 

What did you expect to happen?

200 

 

Link to a page where it happened, if applicable: 

https://linustechtips.com/main/uploads/monthly_2020_10/..png.02833d20ab0debf8feedf769e7c54976.png

Screenshots of the issue, if applicable: 

 

Any other relevant details:

 

 

If it's a cloudflare error, what was the ray ID from the bottom of the error page? 

Link to comment
Share on other sites

Link to post
Share on other sites

12 minutes ago, pd. said:

 

Why exactly would you want it to work ?
Even if it did.. that's just bad practice lol

~New~  BoomBerryPi project !  ~New~


new build log : http://linustechtips.com/main/topic/533392-build-log-the-scrap-simulator-x/?p=7078757 (5 screen flight sim for 620$ CAD)LTT Web Challenge is back ! go here  :  http://linustechtips.com/main/topic/448184-ltt-web-challenge-3-v21/#entry601004

Link to comment
Share on other sites

Link to post
Share on other sites

12 minutes ago, givingtnt said:

that's just bad practice

Exactly, I do not see a reason to save original filename of uploaded file especially when you already take 

md5( mt_rand() )

for it. 

Link to comment
Share on other sites

Link to post
Share on other sites

We block files starting with a ., and the forum software tries to retain the original name to make the URLs somewhat identifiable. It is an oversight that they would come into conflict, but the solution here for now is to rename your image to something other than ..png, and I don't know that it necessarily justifies work to fix it.

HTTP/2 203

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×