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

rewrite: Avoid panic on bad arg count for uri #6571

Merged
merged 2 commits into from
Sep 13, 2024

Conversation

mister-turtle
Copy link
Contributor

All cases for args[0] require additional arguments present in the slice so doing the bounds check here covers all cases. Cases requiring additional parameters already include additional checks on the len(args)

All cases for args[0] require additional arguments present in the slice so doing the bounds check here covers all cases. Cases requiring additional parameters already include additional checks on the len(args)
@CLAassistant
Copy link

CLAassistant commented Sep 13, 2024

CLA assistant check
All committers have signed the CLA.

@francislavoie francislavoie added the bug 🐞 Something isn't working label Sep 13, 2024
@francislavoie francislavoie changed the title Avoid OOB panic on slice access in parseCaddyfileURI when invalid config is used rewrite: Avoid panic on bad arg count for uri Sep 13, 2024
…s already seem to have bounds checks in place.
Copy link
Member

@francislavoie francislavoie left a comment

Choose a reason for hiding this comment

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

Thanks!

(The lint errors aren't your fault, false-positives we're still dealing with separately)

@francislavoie francislavoie merged commit 21f9c20 into caddyserver:master Sep 13, 2024
30 of 33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐞 Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants