WordPress is a free and open-source content management system written in PHP and paired with a MySQL or MariaDB database. Features include a plugin architecture...
Treat every uploaded file as potentially dangerous. Allow only the formats your application needs, and validate the file extension, type and contents on the server. Checks performed only in the browser can be bypassed.
Store uploads outside the public web directory where your application supports this, and serve downloads through a mechanism that checks access permissions. If uploads must sit in a public directory, configure it to prevent uploaded files from executing code. Generate new filenames and prevent existing files from being overwritten.
Set limits on file sizes and upload counts, add malware scanning, and test with harmless files. Do not rely on scanning alone: access restrictions and preventing code execution remain essential.