After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 773830 - [REGRESSION] Infinite loop in forms with multiple saved credentials
[REGRESSION] Infinite loop in forms with multiple saved credentials
Status: RESOLVED FIXED
Product: epiphany
Classification: Core
Component: Passwords, Cookies, & Certificates
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Sergio Villar
Epiphany Maintainers
Depends on:
Blocks:
 
 
Reported: 2016-11-02 13:58 UTC by Sergio Villar
Modified: 2016-11-03 15:19 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch (2.25 KB, patch)
2016-11-02 14:29 UTC, Sergio Villar
committed Details | Review
web-extension: Add missing casts (1.39 KB, patch)
2016-11-03 15:19 UTC, Michael Catanzaro
committed Details | Review

Description Sergio Villar 2016-11-02 13:58:30 UTC
The patch for bug 772530 fixed AngularJS form filling but added a regression
Comment 1 Sergio Villar 2016-11-02 13:58:57 UTC
The patch for bug 772530 fixed AngularJS form filling but added a regression
Comment 2 Sergio Villar 2016-11-02 14:02:57 UTC
(sorry for the above comments added by mistake)

The patch for bug 772530 fixed AngularJS form filling but added a regression. The use of webkit_dom_html_input_element_set_editing_value() added some undesirable side effects to the form auto-filling mechanism.

That function is called inside fill_form_cb() and triggers an event which is handled by username_node_input_cb() (note that we need to have multiple credentials in order to listen to that event). That method calls pre_fill_password() which calls pre_fill_form(). This last method starts a data query call which eventually calls fill_form_cb() again resulting in an infinite number of calls between those methods.
Comment 3 Sergio Villar 2016-11-02 14:29:30 UTC
Created attachment 338953 [details] [review]
Patch
Comment 4 Michael Catanzaro 2016-11-02 15:39:35 UTC
Review of attachment 338953 [details] [review]:

Why do we not need a similar change for the password input field?

::: embed/web-extension/ephy-web-extension.c
@@ +913,3 @@
   WebKitDOMElement *main_div;
 
+  if (g_object_get_data (G_OBJECT (username_node), "ephy-auto-filled"))

It looks like a good fix to me. Maybe name the key "ephy-is-auto-filling"?
Comment 5 Sergio Villar 2016-11-02 16:11:11 UTC
(In reply to Michael Catanzaro from comment #4)
> Review of attachment 338953 [details] [review] [review]:
> 
> Why do we not need a similar change for the password input field?

Because we do not listen to changes in the pass field. We use changes in username field to fill the password one.
Comment 6 Michael Catanzaro 2016-11-02 17:45:52 UTC
OK then
Comment 7 Sergio Villar 2016-11-03 08:15:54 UTC
Review of attachment 338953 [details] [review]:

Landed 7f3a9f7186
Comment 8 Michael Catanzaro 2016-11-03 15:19:34 UTC
The following fix has been pushed:
7c5d710 web-extension: Add missing casts
Comment 9 Michael Catanzaro 2016-11-03 15:19:37 UTC
Created attachment 339042 [details] [review]
web-extension: Add missing casts