-
Notifications
You must be signed in to change notification settings - Fork 1.7k
fix: remove usage of insecure tmpnam #3149
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
Conversation
Sounds good overall, just a few remarks:
|
Sure, makes sense. Will push the changes. |
117915a
to
1d83852
Compare
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.
LGTM
Signed-off-by: Felipe Zipitria <[email protected]>
Signed-off-by: Felipe Zipitria <[email protected]>
Signed-off-by: Felipe Zipitria <[email protected]>
acquire_global_lock() prototype should be added in modsecurity.h in case we want ot reuse it elsewhere (or it should be marked as static for now). The #ifdef __SET_MUTEX_PERMS should also move to acquire_global_lock(). When you're at it:
This block can be removed, it's redundant with previous line Thanks for you responsiveness |
Signed-off-by: Felipe Zipitria <[email protected]>
|
was a typo, and should be |
what
acquire_global_lock
so we DRYGLOBAL_LOCK_TEMPLATE
) as a definition outside a functionwhy
drawbacks
L_tmpnam
is 20 bytes, andAPR_MAX_PATH
should be ~ 4096.references