<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>21044</bug_id>
          
          <creation_ts>2008-09-23 16:22:46 -0700</creation_ts>
          <short_desc>JSEventTarget* classes assume each listener is a JSEventListener</short_desc>
          <delta_ts>2009-07-05 15:00:07 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebCore JavaScript</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.5</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar, NeedsReduction</keywords>
          <priority>P1</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Nikolas Zimmermann">zimmermann</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ap</cc>
    
    <cc>eric</cc>
    
    <cc>sam</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>92423</commentid>
    <comment_count>0</comment_count>
    <who name="Nikolas Zimmermann">zimmermann</who>
    <bug_when>2008-09-23 16:22:46 -0700</bug_when>
    <thetext>As the summary, says JSEventTargetNode::getListener function blindly casts an EventListener object to a JSEventListener. This will fail if ie. it&apos;s actually an ObjCEventListener.

The getListener/setListener functions of the JSEventTarget* classes are only used when calling someElement.onclick = &apos;...&apos; or someElement.onclick.handleEvent(..). The official DOM methods are not affected.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>92424</commentid>
    <comment_count>1</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2008-09-23 16:26:56 -0700</bug_when>
    <thetext>This would lead to a crash, so it should be a P1.  Any application which registers Obj-C listeners as well as allows pages to run JavaScript would be vulnerable to such a crash.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>92427</commentid>
    <comment_count>2</comment_count>
    <who name="Mark Rowe (bdash)">mrowe</who>
    <bug_when>2008-09-23 16:32:42 -0700</bug_when>
    <thetext>&lt;rdar://problem/6241522&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>105291</commentid>
    <comment_count>3</comment_count>
    <who name="Deirdre Saoirse Moen">desamo</who>
    <bug_when>2009-01-11 19:02:56 -0800</bug_when>
    <thetext>A test case would be helpful.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>129884</commentid>
    <comment_count>4</comment_count>
    <who name="Sam Weinig">sam</who>
    <bug_when>2009-07-05 15:00:07 -0700</bug_when>
    <thetext>This is no longer a problem.  We now check that it is a JSEventListener before use.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>