Actually this is not an ASP thing.  It's a WebBrowser on a Windows
Form.  It's not altering the HTML in any way, it's just looping
through all HtmlElements and getting their types.  There's no reason
this is insecure, for example, I could just right click in IE8 and
View Source and look for "<input type=\"text\"".  Why can't I do that
programmatically with a WebBrowser?

On Sep 14, 5:02 pm, Andrew Badera <[email protected]> wrote:
> Some controls like input type="file" can't have their text set
> serverside because you don't want to enable someone to force upload an
> arbitrary file from your machine. Concerns like that -- by opening a
> web page, you're giving a degree of access to your machine. You can't
> fully trust any random server.
>
> I've never known an input type="text" to have this issue, but I
> suspect there's some context we're not seeing here.
>
> ∞ Andy Badera
> ∞ +1 518-641-1280
> ∞ This email is: [ ] bloggable [x] ask first [ ] private
> ∞ Google me:http://www.google.com/search?q=andrew%20badera
>
>
>
> On Mon, Sep 14, 2009 at 4:40 PM, VIKAS GARG <[email protected]> wrote:
>
> > An what are those reasons plz tell us
>
> > On 9/14/09, Andrew Badera <[email protected]> wrote:
>
> >> That's not Microsoft. That's HTML spec. There are certain controls you
> >> can't set in certain ways from the server due to security issues. Quit
> >> bitching about Microsoft for no good reason. (There are PLENTY of good
> >> reasons -- bitch about them!)
>
> >> ∞ Andy Badera
> >> ∞ +1 518-641-1280
> >> ∞ This email is: [ ] bloggable [x] ask first [ ] private
> >> ∞ Google me:http://www.google.com/search?q=andrew%20badera
>
> >> On Mon, Sep 14, 2009 at 11:50 AM, Anonymous <[email protected]> wrote:
>
> >>> Im automating a webbrowser to do certain tasks.  I loop through the
> >>> text boxes in the html sometimes and this requires
>
> >>> if(HtmlElement1.GetAttribute("type") == "text")
> >>>>>>do stuff;
>
> >>> Right now it's sometimes giving me the UnauthorizedAccessException
> >>> when I get there.
>
> >>> ARGH!
>
> >>> Does microsoft have to control what I do on my own computer...?
>
> >>> Anyways, I tried caspol -security off.  It says it temporarily turned
> >>> it off but it still gives the exception.  Stupid security mechanisms.
>
> > --
> > With Regards
> > Vikas Garg
> > 919458309530

Reply via email to