Changeset 19940 in webkit


Ignore:
Timestamp:
Mar 1, 2007 11:59:15 PM (17 years ago)
Author:
antti
Message:

LayoutTests:

Reviewed by Maciej.


HTTP layout test for http://bugs.webkit.org/show_bug.cgi?id=12690
REGRESSION: can not log in to bank of america with TOT webkit
<rdar://problem/4990044>

also for
http://bugs.webkit.org/show_bug.cgi?id=12604
http://bugs.webkit.org/show_bug.cgi?id=12020


  • http/tests/misc/multiple-submit-expected.txt: Added.
  • http/tests/misc/multiple-submit.html: Added.
  • http/tests/misc/resources/post-echo-and-notify-done.cgi: Added.

WebCore:

Reviewed by Maciej.


Fix http://bugs.webkit.org/show_bug.cgi?id=12690
REGRESSION: can not log in to bank of america with TOT webkit
<rdar://problem/4990044>


and http://bugs.webkit.org/show_bug.cgi?id=12604
REGRESSION: After closing the "Would you like to save password" sheet, the form fails
to submit automatically at http://www.mac.com/WebObjects/HomePage.woa
<rdar://problem/4871752>


and http://bugs.webkit.org/show_bug.cgi?id=12020
REGRESSION: Flickr uploading broken
<rdar://problem/4928662>


Turn protection against multiple forms submission back on. This approach is buggy
but it is way better than not having it at all. Not protecting against this
breaks number of major sites.


  • bridge/mac/WebCoreAXObject.mm: (-[WebCoreAXObject accessibilityPerformAction:]):
  • loader/FrameLoader.cpp: (WebCore::FrameLoader::resetMultipleFormSubmissionProtection): (WebCore::FrameLoader::submitForm): (WebCore::FrameLoader::receivedMainResourceError):
  • loader/FrameLoader.h:
  • page/EventHandler.cpp: (WebCore::EventHandler::keyEvent):
  • page/Frame.cpp: (WebCore::Frame::setView):
  • page/mac/EventHandlerMac.mm: (WebCore::EventHandler::mouseDown):
Location:
trunk
Files:
3 added
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r19934 r19940  
     12007-03-01  Antti Koivisto  <antti@apple.com>
     2
     3        Reviewed by Maciej.
     4       
     5        HTTP layout test for http://bugs.webkit.org/show_bug.cgi?id=12690
     6        REGRESSION: can not log in to bank of america with TOT webkit
     7        <rdar://problem/4990044>
     8
     9        also for
     10        http://bugs.webkit.org/show_bug.cgi?id=12604
     11        http://bugs.webkit.org/show_bug.cgi?id=12020
     12       
     13        * http/tests/misc/multiple-submit-expected.txt: Added.
     14        * http/tests/misc/multiple-submit.html: Added.
     15        * http/tests/misc/resources/post-echo-and-notify-done.cgi: Added.
     16
    1172007-03-01  Kevin McCullough  <kmccullough@apple.com>
    218
  • trunk/WebCore/ChangeLog

    r19934 r19940  
     12007-03-01  Antti Koivisto  <antti@apple.com>
     2
     3        Reviewed by Maciej.
     4       
     5        Fix http://bugs.webkit.org/show_bug.cgi?id=12690
     6        REGRESSION: can not log in to bank of america with TOT webkit
     7        <rdar://problem/4990044>
     8       
     9        and http://bugs.webkit.org/show_bug.cgi?id=12604
     10        REGRESSION: After closing the "Would you like to save password" sheet, the form fails
     11        to submit automatically at http://www.mac.com/WebObjects/HomePage.woa
     12        <rdar://problem/4871752>
     13       
     14        and http://bugs.webkit.org/show_bug.cgi?id=12020
     15        REGRESSION: Flickr uploading broken
     16        <rdar://problem/4928662>
     17       
     18        Turn protection against multiple forms submission back on. This approach is buggy
     19        but it is way better than not having it at all. Not protecting against this
     20        breaks number of major sites.
     21       
     22        * bridge/mac/WebCoreAXObject.mm:
     23        (-[WebCoreAXObject accessibilityPerformAction:]):
     24        * loader/FrameLoader.cpp:
     25        (WebCore::FrameLoader::resetMultipleFormSubmissionProtection):
     26        (WebCore::FrameLoader::submitForm):
     27        (WebCore::FrameLoader::receivedMainResourceError):
     28        * loader/FrameLoader.h:
     29        * page/EventHandler.cpp:
     30        (WebCore::EventHandler::keyEvent):
     31        * page/Frame.cpp:
     32        (WebCore::Frame::setView):
     33        * page/mac/EventHandlerMac.mm:
     34        (WebCore::EventHandler::mouseDown):
     35
    1362007-03-01  Kevin McCullough  <kmccullough@apple.com>
    237
  • trunk/WebCore/bridge/mac/WebCoreAXObject.mm

    r19919 r19940  
    888888        if (!actionElement)
    889889            return;
    890 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
    891890        if (Frame* f = actionElement->document()->frame())
    892891            f->loader()->resetMultipleFormSubmissionProtection();
    893 #endif
    894892        actionElement->accessKeyAction(true);
    895893    }
  • trunk/WebCore/loader/FrameLoader.cpp

    r19902 r19940  
    14651465}
    14661466
    1467 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
    14681467void FrameLoader::didNotOpenURL(const KURL& URL)
    14691468{
     
    14761475    m_submittedFormURL = KURL();
    14771476}
    1478 #endif
    14791477
    14801478void FrameLoader::setEncoding(const String& name, bool userChosen)
     
    27302728void FrameLoader::submitForm(const FrameLoadRequest& request, Event* event)
    27312729{
    2732 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
    27332730    // FIXME: We'd like to remove this altogether and fix the multiple form submission issue another way.
    27342731    // We do not want to submit more than one form from the same page,
     
    27472744        m_submittedFormURL = request.resourceRequest().url();
    27482745    }
    2749 #endif
    27502746
    27512747    // FIXME: Why do we always pass true for userGesture?
     
    30393035   
    30403036    if (m_state == FrameStateProvisional) {
    3041 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
    30423037        KURL failedURL = m_provisionalDocumentLoader->originalRequestCopy().url();
    30433038        didNotOpenURL(failedURL);
    3044 #endif
     3039           
    30453040        // We might have made a page cache item, but now we're bailing out due to an error before we ever
    30463041        // transitioned to the new page (before WebFrameState == commit).  The goal here is to restore any state
  • trunk/WebCore/loader/FrameLoader.h

    r19737 r19940  
    339339        bool userGestureHint();
    340340
    341 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
    342341        void resetMultipleFormSubmissionProtection();
    343342        void didNotOpenURL(const KURL&);
    344 #endif
    345343
    346344        void addData(const char* bytes, int length);
     
    580578        RefPtr<HTMLFormElement> m_formAboutToBeSubmitted;
    581579        HashMap<String, String> m_formValuesAboutToBeSubmitted;
    582 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
    583580        KURL m_submittedFormURL;
    584 #endif
    585581   
    586582        Timer<FrameLoader> m_redirectionTimer;
  • trunk/WebCore/page/EventHandler.cpp

    r19855 r19940  
    3838#include "FocusController.h"
    3939#include "Frame.h"
     40#include "FrameLoader.h"
    4041#include "FrameTree.h"
    4142#include "FrameView.h"
     
    12581259        return false;
    12591260   
    1260 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
    12611261    if (!keyEvent.isKeyUp())
    1262         loader()->resetMultipleFormSubmissionProtection();
    1263 #endif
     1262        m_frame->loader()->resetMultipleFormSubmissionProtection();
    12641263
    12651264    result = !node->dispatchKeyEvent(keyEvent);
  • trunk/WebCore/page/Frame.cpp

    r19925 r19940  
    276276    d->m_view = view;
    277277
    278 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
    279278    // Only one form submission is allowed per view of a part.
    280279    // Since this part may be getting reused as a result of being
    281280    // pulled from the back/forward cache, reset this flag.
    282281    loader()->resetMultipleFormSubmissionProtection();
    283 #endif
    284282}
    285283
  • trunk/WebCore/page/mac/EventHandlerMac.mm

    r19884 r19940  
    456456
    457457    BEGIN_BLOCK_OBJC_EXCEPTIONS;
    458 #ifdef MULTIPLE_FORM_SUBMISSION_PROTECTION
     458   
    459459    m_frame->loader()->resetMultipleFormSubmissionProtection();
    460 #endif
     460
    461461    m_mouseDownView = nil;
    462462    dragState().m_dragSrc = 0;
Note: See TracChangeset for help on using the changeset viewer.