-
Notifications
You must be signed in to change notification settings - Fork 184
CWE-460 #962
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
CWE-460 #962
Conversation
Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very interesting code example! My comments are mostly cosmetic.
Thanks for the contribution!
|
||
# CWE-460: Improper Cleanup on Thrown Exception | ||
|
||
The product does not clean up its state or incorrectly cleans up its state when an exception is thrown, leading to unexpected state or control flow. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We usually make the first sentence something like:
Ensure that your code fully and correctly cleans up its state whenever an exception occurs to avoid unexpected state or control flow.
Rather than taking the actual CWE description. We have plans to change the naming of the rulesets in the future in order to avoid this confusion, but for now, I'd change the first sentence to be "always do this" or "never do this"
docs/Secure-Coding-Guide-for-Python/CWE-664/CWE-460/noncompliant.py
Outdated
Show resolved
Hide resolved
hi @BartKaras1128 thank you so much for the feedback! i will keep it in mind when submitting other PRs! =) |
…nt.py Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Co-authored-by: Bartlomiej Karas <[email protected]> Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
Hi @kets99! Thanks for the PR and sorry for missing to kick-off the linter (which does not run automatically for new contributors). It found some minor syntax issues. Can you address them? You'll find the log here: https://github.com/ossf/wg-best-practices-os-developers/actions/runs/16997777562/job/48808825760?pr=962 If you need any support, please let me know! |
Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
Signed-off-by: Ketki <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you! Looks good to me.
No description provided.