In the Kentico Settings, you can set the allowed File Types for Media Library (Settings > Content > Media > Security > Media file allowed extensions), as well as in the Form Control itself (Upload File) in the settings you can set the Allowed_Extensions property.
If you're doing pure ASPX, you should be able to set the Allowed_Extensions in the back end code for that form control.