<?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>42170</bug_id>
          
          <creation_ts>2010-07-13 09:19:51 -0700</creation_ts>
          <short_desc>postMessage() second argument should not accept full URL</short_desc>
          <delta_ts>2010-08-10 22:41:58 -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>DOM</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>INVALID</resolution>
          
          
          <bug_file_loc> javascript:var url=&quot;http://www.example.com/test&quot;,win=window.open(url);try{win.postMessage(&quot;test&quot;,url);alert(&quot;FAIL&quot;)}catch(e){alert(&quot;PASS&quot;)}</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Anne van Kesteren">annevk</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ap</cc>
    
    <cc>ian</cc>
    
    <cc>mike</cc>
    
    <cc>shadow2531</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>250549</commentid>
    <comment_count>0</comment_count>
    <who name="Anne van Kesteren">annevk</who>
    <bug_when>2010-07-13 09:19:51 -0700</bug_when>
    <thetext>Per HTML5 http://www.whatwg.org/specs/web-apps/current-work/complete/web-messaging.html#dom-window-postmessage postMessage() should throw if targetOrigin contains a path component.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>250553</commentid>
    <comment_count>1</comment_count>
    <who name="Anne van Kesteren">annevk</who>
    <bug_when>2010-07-13 09:23:39 -0700</bug_when>
    <thetext>See also: https://bugzilla.mozilla.org/show_bug.cgi?id=578380</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>250575</commentid>
    <comment_count>2</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2010-07-13 09:45:43 -0700</bug_when>
    <thetext>Anne, do you know if there is a good reason for this requirement? Ignoring unnecessary components seems cleaner in general.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>250582</commentid>
    <comment_count>3</comment_count>
    <who name="Anne van Kesteren">annevk</who>
    <bug_when>2010-07-13 09:54:47 -0700</bug_when>
    <thetext>Authors might otherwise mistakenly believe they get more protection than they actually do. To me it seems cleaner to reject everything that is not an origin.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>250591</commentid>
    <comment_count>4</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2010-07-13 10:14:08 -0700</bug_when>
    <thetext>In general, we strongly dislike raising exceptions where they weren&apos;t raised before, since that tends to transform minor/potential mistakes into serious breakage of functionality on existing pages.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>262934</commentid>
    <comment_count>5</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2010-08-10 18:11:28 -0700</bug_when>
    <thetext>The spec has changed.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>263026</commentid>
    <comment_count>6</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2010-08-10 22:41:58 -0700</bug_when>
    <thetext>Thanks. This seems invalid per the new spec.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>