Skip to main content

Is it possible to whitelist command/programs to be used by shell_exec?

Comments

4 comments

  • cPanelMichael
    My server has CloudLinux installed, if it helps.

    Hello, I believe shell_exec is safe when using CageFS, according to this thread on the CloudLinux forums: shell_exec + cloudlinux + cagefs Thank you.
    0
  • VMunich
    Hello, I believe shell_exec is safe when using CageFS, according to this thread on the CloudLinux forums: shell_exec + cloudlinux + cagefs Thank you.

    Thanks. So that would protect the server in general by preventing users from leaving their jail, but would that prevent someone to use, say `wget` from shell_exec to download potential harmful files?
    0
  • cPanelMichael
    but would that prevent someone to use, say `wget` from shell_exec to download potential harmful files?

    Could you provide an example of a harmful file or a specific action such a file would take? Thank you.
    0
  • quizknows
    Thanks. So that would protect the server in general by preventing users from leaving their jail, but would that prevent someone to use, say `wget` from shell_exec to download potential harmful files?

    - So that would protect the server in general by preventing users from leaving their jail yes. - would that prevent someone to use, say `wget` from shell_exec to download potential harmful files no, probably not.
    0

Please sign in to leave a comment.