← sources

Docker Container php2shell audit script

source: reddit (reddit:selfhosted)published 2026-10-22 16:56ingested 2026-10-23 02:39

retained text

Here's a quick script to check if you have a vulnerable version of php running on any of your docker containers. 

[https://gist.github.com/jonmchan/f68bf6aeb5e58048e6654743d9e618e5](https://gist.github.com/jonmchan/f68bf6aeb5e58048e6654743d9e618e5)

    $ sudo ./audit.sh
    
    === Starting Docker PHP2Shell Audit ===
    
    [SAFE] Container: kimai-kimai-1 is running patched PHP v8.3.36. 
    [VULNERABLE] Container: nextcloud-nextcloud-aio-nextcloud-1 (PHP v8.3.19) is vulnerable to PHP2Shell! 
    [VULNERABLE] Container: wildcard-web (PHP v8.3.31) is vulnerable to PHP2Shell! 
    [VULNERABLE] Container: root-web (PHP v8.3.31) is vulnerable to PHP2Shell! 
    [VULNERABLE] Container: home-web (PHP v8.4.16) is vulnerable to PHP2Shell! 
    [VULNERABLE] Container: whblog-whblog-1 (PHP v8.2.25) is vulnerable to PHP2Shell! 
    
    === Audit Complete ===

document fetched 2026-10-23 00:32 · canonical https://reddit.com/r/selfhosted/comments/1xco3g9/docker_container_php2shell_audit_script