The file
formtool supports the ftAllowedFileExtensions
attribute which allows you to set the allowed file extensions for that upload field;
<cfproperty name="ftAllowedFileExtensions"
default="pdf,doc,ppt,xls,docx,pptx,xlsx,jpg,jpeg,png,gif,zip,rar,flv,swf,mpg,mpe,mpeg,m1s,mpa,mp2,m2a,mp2v,m2v,m2s,mov,qt,asf,asx,wmv,wma,wmx,rm,ra,ram,rmvb,mp3,mp4,3gp,ogm,mkv,avi"
hint="Used when ftRenderType is set to HTML, extentions allowed to be uploaded." />
So .exe
and .com
extensions are not allowed but they could possibly be placed inside a zip or other file format that allows embedding.
If you need to restrict the extensions for dmFile for example, then you can extend dmFile in your project and override the filename property to specify the extensions you accept;
<cfcomponent extends="farcry.core.packages.types.dmFile">
<cfproperty name="filename" type="string" required="no" default=""
ftSeq="3" ftFieldset="File Details" ftLabel="File"
ftType="file" ftDestination="/dmfile"
ftAllowedFileExtensions="doc,docx,xls,xlsx,pdf"
ftSecure="false" ftBulkUploadTarget="true"
hint="The name of the file to be uploaded">
</cfcomponent>