New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 753746 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Jun 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , iOS , Chrome , Mac , Fuchsia
Pri: 2
Type: Compat


Show other hotlists

Hotlists containing this issue:
Hotlist-2


Sign in to add a comment

Image submit button makes extra form data if "value" attribute is present.

Reported by babata...@gmail.com, Aug 9 2017

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3180.0 Safari/537.36

Example URL:
https://superb-robot-720.appspot.com/

Steps to reproduce the problem:
1. Open https://superb-robot-720.appspot.com/
2. Click chrome image (it is a image submit button).

What is the expected behavior?
The form data should be just "mybutton.x=100&mybutton.y=100" (the numbers are not matter). "mybutton=test" should not be included.

What went wrong?
The form data includes "mybutton=test".

According to HTML spec 4.10.21.4 (https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#constructing-form-data-set), it should not be sent.

- The image button matches the algorithm 3-3 "If the field element is an input element whose type attribute is in the Image Button state,"
- 3-3-7 directs to skip following steps ("Continue"), so 3-4 "Let name be the value of the field element's name attribute" and 3-9 "Otherwise, append an entry to the form data set ..." should be skipped.
- Therefore, the constructed "form data set" should not include the value of the image button.

Note that this issue does not occur if the "value" attribute of the image button is empty.

Does it occur on multiple sites: N/A

Is it a problem with a plugin? No 

Did this work before? N/A 

Does this work in other browsers? Yes

Chrome version: 62.0.3180.0  Channel: canary
OS Version: 10.0
Flash Version:
 
Cc: pnangunoori@chromium.org
Labels: Needs-Triage-M62 OS-Linux OS-Mac
Status: Untriaged (was: Unconfirmed)
Tested on Chrome Stable #60.0.3112.90, Canary #62.0.3180.0 on Windows 7, Mac 10.12.6, Ubuntu 14.04 and able to reproduce the issue. 

This is a non-regression issue and able to reproduce from M-45 #45.0.2454.85. Marking it as untriaged so that issue gets addressed.

Observations - Mentioned issue works fine in FireFox.

Thanks.
Components: Blink>Forms

Comment 3 by tkent@chromium.org, Aug 22 2017

Labels: -Needs-Triage-M62 Hotlist-Interop OS-Android OS-Chrome OS-Fuchsia OS-iOS
Status: Available (was: Untriaged)
Summary: Image submit button makes extra form data if "value" attribute is present. (was: Image submit button makes extra form data if "value" is present.)
Safari 10.1: Has mybutton=test
Edge: No mybutton=test
Firefox: No mybutton=test

IMO, we need to start with adding a UseCounter.

Owner: shanmug...@samsung.com
Status: Assigned (was: Available)
Project Member

Comment 5 by bugdroid1@chromium.org, Sep 8 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/294a692bd7f6ef700813520b48f14f9e4f8e75bd

commit 294a692bd7f6ef700813520b48f14f9e4f8e75bd
Author: Shanmuga Pandi M <shanmuga.m@samsung.com>
Date: Fri Sep 08 07:00:42 2017

Measure the usage of image button form data with value attribute.

Image submit button makes extra form data if "value" attribute
is present. As interop Edge and Firefox is not makes extra form
data.

Bug:  753746 
Change-Id: Ibbcf49b62fb704008c7f0bdc17915770e328bfff
Reviewed-on: https://chromium-review.googlesource.com/652727
Commit-Queue: Shanmuga Pandi <shanmuga.m@samsung.com>
Reviewed-by: Kent Tamura <tkent@chromium.org>
Cr-Commit-Position: refs/heads/master@{#500531}
[modify] https://crrev.com/294a692bd7f6ef700813520b48f14f9e4f8e75bd/third_party/WebKit/Source/core/html/forms/ImageInputType.cpp
[modify] https://crrev.com/294a692bd7f6ef700813520b48f14f9e4f8e75bd/third_party/WebKit/public/platform/web_feature.mojom
[modify] https://crrev.com/294a692bd7f6ef700813520b48f14f9e4f8e75bd/tools/metrics/histograms/enums.xml

Comment 6 by tkent@chromium.org, Sep 8 2017

NextAction: 2017-12-26
Labels: Needs-Feedback
Tested the issue on Windows 7, Mac OS 10.12.5 and Ubuntu 14.04 using Chrome version M63 - 63.0.3212.0 as per the issue mentioned in original comment. 

“[mybutton] => test” value is still displayed upon clicking on the Chrome image after navigating to the URL ‘https://superb-robot-720.appspot.com/’. Please refer the screenshot attached.

@shanmuga.m -- Could you please confirm the fix. So that it would help us in triaging the issue further by adding TE-Verified labels.

Thank you!
753746.PNG
165 KB View Download
@pnangunoori,
 Before fixing the issue, currently we are measuring the usage of this scenario.
Still fix for the issue is not landed.
Cc: srikanthg@chromium.org eugene...@chromium.org
srikanthg@, is this reproducible on iOS?
Reproduced on all browsers on iOS.
Tested on iOS 11.2
The NextAction date has arrived: 2017-12-26
Cc: danyao@chromium.org
Components: Mobile>WebView>Glue
+danyao@ for ios web compat bug.

Comment 14 by tkent@chromium.org, Jan 19 2018

Labels: Needs-BlinkIntent
NextAction: ----
> Usecounter shows 0.017% usage

IMO, we should proceed deprecation-and-remove process.

Status: Started (was: Assigned)
Project Member

Comment 17 by bugdroid1@chromium.org, Feb 1 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9b477bcaea5558d93d9d6aadc6674181bd00aab1

commit 9b477bcaea5558d93d9d6aadc6674181bd00aab1
Author: Shanmuga Pandi M <shanmuga.m@samsung.com>
Date: Thu Feb 01 14:36:42 2018

Remove extra form data, if "value" attribute present with non-empty value

This patch removes the extra form data added, if "value" attribute
present with non-empty value for <input type='image'>

Intent to Deprecate and Remove:
https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/hp1_-1tgvDs

Bug:  753746 
Change-Id: I1de9a0c9babd9d16b45e5eefa780370fff8c75e9
Reviewed-on: https://chromium-review.googlesource.com/896905
Reviewed-by: Kent Tamura <tkent@chromium.org>
Commit-Queue: Shanmuga Pandi <shanmuga.m@samsung.com>
Cr-Commit-Position: refs/heads/master@{#533655}
[add] https://crrev.com/9b477bcaea5558d93d9d6aadc6674181bd00aab1/third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/image-click-form-data.html
[add] https://crrev.com/9b477bcaea5558d93d9d6aadc6674181bd00aab1/third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/resources/image-submit-click.html
[modify] https://crrev.com/9b477bcaea5558d93d9d6aadc6674181bd00aab1/third_party/WebKit/LayoutTests/fast/forms/image/input-image-submit.html
[modify] https://crrev.com/9b477bcaea5558d93d9d6aadc6674181bd00aab1/third_party/WebKit/Source/core/html/forms/ImageInputType.cpp
[modify] https://crrev.com/9b477bcaea5558d93d9d6aadc6674181bd00aab1/third_party/WebKit/public/platform/web_feature.mojom
[modify] https://crrev.com/9b477bcaea5558d93d9d6aadc6674181bd00aab1/tools/metrics/histograms/enums.xml

Components: -Mobile>WebView>Glue
Labels: -Needs-Feedback -Needs-BlinkIntent M-66
Status: Fixed (was: Started)
Labels: -M-66 M-68
Status: Started (was: Fixed)
Project Member

Comment 20 by bugdroid1@chromium.org, Feb 2 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f591d29ef77a34fb59a33c4e8c50586305eb68d9

commit f591d29ef77a34fb59a33c4e8c50586305eb68d9
Author: Kent Tamura <tkent@chromium.org>
Date: Fri Feb 02 01:48:51 2018

Revert "Remove extra form data, if "value" attribute present with non-empty value"

This reverts commit 9b477bcaea5558d93d9d6aadc6674181bd00aab1.

Reason for revert: We should deprecate the feature first.

Original change's description:
> Remove extra form data, if "value" attribute present with non-empty value
> 
> This patch removes the extra form data added, if "value" attribute
> present with non-empty value for <input type='image'>
> 
> Intent to Deprecate and Remove:
> https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/hp1_-1tgvDs
> 
> Bug:  753746 
> Change-Id: I1de9a0c9babd9d16b45e5eefa780370fff8c75e9
> Reviewed-on: https://chromium-review.googlesource.com/896905
> Reviewed-by: Kent Tamura <tkent@chromium.org>
> Commit-Queue: Shanmuga Pandi <shanmuga.m@samsung.com>
> Cr-Commit-Position: refs/heads/master@{#533655}

TBR=tkent@chromium.org,foolip@chromium.org,shanmuga.m@samsung.com

Change-Id: I97c5987adba9eaa097808f7a35c54859217edd2e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug:  753746 
Reviewed-on: https://chromium-review.googlesource.com/897264
Reviewed-by: Kent Tamura <tkent@chromium.org>
Commit-Queue: Kent Tamura <tkent@chromium.org>
Cr-Commit-Position: refs/heads/master@{#533910}
[delete] https://crrev.com/e0dea6a4ba075e2fc9b575969e1d8c1fcf448ebd/third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/image-click-form-data.html
[delete] https://crrev.com/e0dea6a4ba075e2fc9b575969e1d8c1fcf448ebd/third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/resources/image-submit-click.html
[modify] https://crrev.com/f591d29ef77a34fb59a33c4e8c50586305eb68d9/third_party/WebKit/LayoutTests/fast/forms/image/input-image-submit.html
[modify] https://crrev.com/f591d29ef77a34fb59a33c4e8c50586305eb68d9/third_party/WebKit/Source/core/html/forms/ImageInputType.cpp
[modify] https://crrev.com/f591d29ef77a34fb59a33c4e8c50586305eb68d9/third_party/WebKit/public/platform/web_feature.mojom
[modify] https://crrev.com/f591d29ef77a34fb59a33c4e8c50586305eb68d9/tools/metrics/histograms/enums.xml

Project Member

Comment 21 by bugdroid1@chromium.org, Feb 2 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8d0135f15287aa1ea1f6594136dcf1c36f0e290f

commit 8d0135f15287aa1ea1f6594136dcf1c36f0e290f
Author: Shanmuga Pandi M <shanmuga.m@samsung.com>
Date: Fri Feb 02 09:01:17 2018

Deprecate extra form data, if "value" attribute present with non-empty value

This patch will show deprecate warning for the extra form data which was added,
if "value" attribute present with non-empty value for <input type='image'>

Intent to Deprecate and Remove:
https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/hp1_-1tgvDs

Bug:  753746 
Change-Id: I565132d6ef8c6d4a93ce5447e5d18d7f7f8c1910
Reviewed-on: https://chromium-review.googlesource.com/896740
Reviewed-by: Kent Tamura <tkent@chromium.org>
Commit-Queue: Shanmuga Pandi <shanmuga.m@samsung.com>
Cr-Commit-Position: refs/heads/master@{#534004}
[add] https://crrev.com/8d0135f15287aa1ea1f6594136dcf1c36f0e290f/third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/image-click-form-data-expected.txt
[add] https://crrev.com/8d0135f15287aa1ea1f6594136dcf1c36f0e290f/third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/image-click-form-data.html
[add] https://crrev.com/8d0135f15287aa1ea1f6594136dcf1c36f0e290f/third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/resources/image-submit-click.html
[modify] https://crrev.com/8d0135f15287aa1ea1f6594136dcf1c36f0e290f/third_party/WebKit/LayoutTests/fast/forms/image/input-image-submit-expected.txt
[modify] https://crrev.com/8d0135f15287aa1ea1f6594136dcf1c36f0e290f/third_party/WebKit/Source/core/frame/Deprecation.cpp
[modify] https://crrev.com/8d0135f15287aa1ea1f6594136dcf1c36f0e290f/third_party/WebKit/Source/core/html/forms/ImageInputType.cpp

Project Member

Comment 22 by bugdroid1@chromium.org, Jun 6 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/74c2995af5cd264c782b13e99bdce248694593cb

commit 74c2995af5cd264c782b13e99bdce248694593cb
Author: Shanmuga Pandi M <shanmuga.m@samsung.com>
Date: Wed Jun 06 11:34:04 2018

Remove extra form data, if "value" attribute present with non-empty value

This patch removes the extra form data added, if "value" attribute
present with non-empty value for <input type='image'>

Intent to Deprecate and Remove:
https://groups.google.com/a/chromium.org/forum/#!topic/blink-dev/hp1_-1tgvDs

Bug:  753746 
Change-Id: I6a4987a7fb5751b75ff2472f594063876ec076a1
Reviewed-on: https://chromium-review.googlesource.com/1086953
Commit-Queue: Shanmuga Pandi <shanmuga.m@samsung.com>
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Cr-Commit-Position: refs/heads/master@{#564854}
[delete] https://crrev.com/64debbe9a4de290c8fb4f3ac9ef87768a379d167/third_party/WebKit/LayoutTests/external/wpt/html/semantics/forms/the-input-element/image-click-form-data-expected.txt
[modify] https://crrev.com/74c2995af5cd264c782b13e99bdce248694593cb/third_party/WebKit/LayoutTests/fast/forms/image/input-image-submit-expected.txt
[modify] https://crrev.com/74c2995af5cd264c782b13e99bdce248694593cb/third_party/WebKit/LayoutTests/fast/forms/image/input-image-submit.html
[modify] https://crrev.com/74c2995af5cd264c782b13e99bdce248694593cb/third_party/blink/public/platform/web_feature.mojom
[modify] https://crrev.com/74c2995af5cd264c782b13e99bdce248694593cb/third_party/blink/renderer/core/frame/deprecation.cc
[modify] https://crrev.com/74c2995af5cd264c782b13e99bdce248694593cb/third_party/blink/renderer/core/html/forms/image_input_type.cc
[modify] https://crrev.com/74c2995af5cd264c782b13e99bdce248694593cb/tools/metrics/histograms/enums.xml

Labels: -M-68 Target-69
Status: Fixed (was: Started)

Sign in to add a comment