Skip to content

#31 Improved randomness of downloading - #36

Open
i3130002 wants to merge 4 commits into
openspeedtest:mainfrom
i3130002:main
Open

#31 Improved randomness of downloading#36
i3130002 wants to merge 4 commits into
openspeedtest:mainfrom
i3130002:main

Conversation

@i3130002

@i3130002 i3130002 commented Jan 23, 2026

Copy link
Copy Markdown

Dear @openspeedtest
Please review these changes and merge if you see fit

Thanks for creating and maintaining this project. <3

- Generate the download file at container startup instead of build
  time; fresh data per deployment and ~30MB smaller image.
- Add WITHOUT_LETSENCRYPT build arg to skip certbot/dcron/crond
  (~65MB smaller); entrypoint and renew scripts fail fast if Let's
  Encrypt is requested without certbot.
Comment thread Dockerfile Outdated
ARG FILE_SIZE=31457280
ARG FILE_NAME=downloading
ENV FILE_SIZE=${FILE_SIZE}
ENV FILE_NAME=${FILE_NAME}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thinking security wise, any sanity checking needed here to avoid buffer overflow ? Could I enter a string ../../../etc/password for example to the file_name kind of thing. Like the flexibility - wondered if anyone else thought there may need some guardrails around it.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had removed the FILE__NAME as the frontend would not be able to change to the mentioned here and there is no actual benefit of changing it as far as I know. You're correct, the risks of escaping with ../../ might be valid too. (Although this is a variable for Dockerfile which the user who builds the image would set. Doesn't get expose anything either way)

Allow me apply the latest patches I made.

Comment thread Dockerfile Outdated
&& chmod 400 /etc/nginx/nginx.conf \
&& chmod +x /entrypoint.sh \
&& chown -R nginx /usr/share/nginx/html/ \
&& chmod 755 /usr/share/nginx/html/upload \

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I always wondered why this file had execute permissions, would it work just the same as 0744 ?

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

Successfully merging this pull request may close these issues.

2 participants