file validator extensions

The file property extension for file validation allows you to check for only extensions that you want to upload. Is there a way to configure it to check for extensions that you don’t want to upload. For example if I want to allow all extensions except for ‘exe, pdf, html’ or if I don’t want to allow uploading of any images? How can this be done in Yii2?

Guide > Validating Input > Creating Validators

http://www.yiiframework.com/doc-2.0/guide-input-validation.html#creating-validators