Maybe we are talking at cross-purposes. The scenario I am thinking of is that no script, whether client-browser-based (like JavaScript) or generated in a browser by a script should be able to force a value into the INPUT TYPE=FILE form element AND on its own issue a SUBMIT. I understood that to be the basis of the problem described above: test an existing browser form by using a script to execute it, including the definition of a value from the script for the VALUE element of the INPUT TYPE=FILE form element.
The W3C HTML 4 specifications are quite explicit about this:
"A user agent should not send any file that the user has not explicitly asked to be sent. Thus, HTML user agents are expected to confirm any default file names that might be suggested by the value attribute of the INPUT element. Hidden controls must not specify files."
http://www.w3.org/TR/html401/appendix/notes.html#forms-security
I also found an email exchange about the issue on the W3C site.
> And about the security considerations, lets just hope that
> Java/J/ECMAscript and the DOMs aren't allowing write access to
> the INPUT TYPE=FILE VALUE attributes and submitting forms by
> themselves these days.
The response:
Luckily Microsoft and Netscape have indeed noticed this, and both
have made file input VALUE attributes read-only (you can write to
them but it fails silently). This is contrary to the documentation
at msdn.microsoft.com though. (Which says value and outerHTML are
both read/write.)
http://lists.w3.org/Archives/Public/www-html/2000Apr/0018.html
Are you suggesting that a script be able to input the VALUE of the INPUT TYPE=FILE form element without user intervention in a browser file and force a SUBMIT, or do you have some ohter scenario in mind?
Live in the present