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

Add rlimit and prevent the process from forking #183

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mscherer
Copy link

While it doesn't prevent all exploitations, it make
like harder for a attacker who would want to spawn a shell
or similar type of attack.

@@ -183,6 +183,9 @@ AM_CONDITIONAL(HAVE_STRCHRNUL, [test "x${ac_cv_func_strchrnul}" = xyes])
AC_CHECK_FUNCS([strnlen])
AM_CONDITIONAL(HAVE_STRNLEN, [test "x${ac_cv_func_strnlen}" = xyes])

AC_CHECK_FUNCS([prlimit])
AM_CONDITIONAL(HAVE_PRLIMIT, [test "x${ac_cv_func_prlmit}" = xyes])
Copy link
Contributor

Choose a reason for hiding this comment

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

this AM_CONDITIONAL is pointless as it isn't used in the makefiles. just delete it.

Copy link
Author

Choose a reason for hiding this comment

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

So I am not that fluent with automake/autoconf, but if I remove the AM_CONDITIONAL, is there value in keeping the AC_CHECK_FUNCS ?

Copy link
Contributor

Choose a reason for hiding this comment

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

the AC_CHECK_FUNCS is needed to create HAVE_PRLIMIT which you use later on :)

While it doesn't prevent all exploitations, it make
like harder for a attacker who would want to spawn a shell
or similar type of attack.
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