{"action":"created","issue":{"url":"https://api.github.com/repos/magento/magento2/issues/16237","repository_url":"https://api.github.com/repos/magento/magento2","labels_url":"https://api.github.com/repos/magento/magento2/issues/16237/labels{/name}","comments_url":"https://api.github.com/repos/magento/magento2/issues/16237/comments","events_url":"https://api.github.com/repos/magento/magento2/issues/16237/events","html_url":"https://github.com/magento/magento2/issues/16237","id":333632975,"node_id":"MDU6SXNzdWUzMzM2MzI5NzU=","number":16237,"title":"REST WEBAPI malforms parameters in v2.2.4 when decoding","user":{"login":"reviskar","id":10104702,"node_id":"MDQ6VXNlcjEwMTA0NzAy","avatar_url":"https://avatars1.githubusercontent.com/u/10104702?v=4","gravatar_id":"","url":"https://api.github.com/users/reviskar","html_url":"https://github.com/reviskar","followers_url":"https://api.github.com/users/reviskar/followers","following_url":"https://api.github.com/users/reviskar/following{/other_user}","gists_url":"https://api.github.com/users/reviskar/gists{/gist_id}","starred_url":"https://api.github.com/users/reviskar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/reviskar/subscriptions","organizations_url":"https://api.github.com/users/reviskar/orgs","repos_url":"https://api.github.com/users/reviskar/repos","events_url":"https://api.github.com/users/reviskar/events{/privacy}","received_events_url":"https://api.github.com/users/reviskar/received_events","type":"User","site_admin":false},"labels":[{"id":373917120,"node_id":"MDU6TGFiZWwzNzM5MTcxMjA=","url":"https://api.github.com/repos/magento/magento2/labels/Component:%20Framework/Webapi","name":"Component: Framework/Webapi","color":"7fb703","default":false},{"id":686477493,"node_id":"MDU6TGFiZWw2ODY0Nzc0OTM=","url":"https://api.github.com/repos/magento/magento2/labels/Fixed%20in%202.3.x","name":"Fixed in 2.3.x","color":"0e8a16","default":false},{"id":686420665,"node_id":"MDU6TGFiZWw2ODY0MjA2NjU=","url":"https://api.github.com/repos/magento/magento2/labels/Issue:%20Clear%20Description","name":"Issue: Clear Description","color":"0e8a16","default":false},{"id":686476746,"node_id":"MDU6TGFiZWw2ODY0NzY3NDY=","url":"https://api.github.com/repos/magento/magento2/labels/Issue:%20Confirmed","name":"Issue: Confirmed","color":"0e8a16","default":false},{"id":688811200,"node_id":"MDU6TGFiZWw2ODg4MTEyMDA=","url":"https://api.github.com/repos/magento/magento2/labels/Issue:%20Format%20is%20valid","name":"Issue: Format is valid","color":"0e8a16","default":false},{"id":21716835,"node_id":"MDU6TGFiZWwyMTcxNjgzNQ==","url":"https://api.github.com/repos/magento/magento2/labels/Issue:%20Ready%20for%20Work","name":"Issue: Ready for Work","color":"0e8a16","default":false},{"id":686477126,"node_id":"MDU6TGFiZWw2ODY0NzcxMjY=","url":"https://api.github.com/repos/magento/magento2/labels/Reproduced%20on%202.2.x","name":"Reproduced on 2.2.x","color":"e99695","default":false},{"id":718638829,"node_id":"MDU6TGFiZWw3MTg2Mzg4Mjk=","url":"https://api.github.com/repos/magento/magento2/labels/help%20wanted","name":"help wanted","color":"0e8a16","default":true}],"state":"closed","locked":false,"assignee":{"login":"engcom-backlog-nazar","id":40756439,"node_id":"MDQ6VXNlcjQwNzU2NDM5","avatar_url":"https://avatars2.githubusercontent.com/u/40756439?v=4","gravatar_id":"","url":"https://api.github.com/users/engcom-backlog-nazar","html_url":"https://github.com/engcom-backlog-nazar","followers_url":"https://api.github.com/users/engcom-backlog-nazar/followers","following_url":"https://api.github.com/users/engcom-backlog-nazar/following{/other_user}","gists_url":"https://api.github.com/users/engcom-backlog-nazar/gists{/gist_id}","starred_url":"https://api.github.com/users/engcom-backlog-nazar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/engcom-backlog-nazar/subscriptions","organizations_url":"https://api.github.com/users/engcom-backlog-nazar/orgs","repos_url":"https://api.github.com/users/engcom-backlog-nazar/repos","events_url":"https://api.github.com/users/engcom-backlog-nazar/events{/privacy}","received_events_url":"https://api.github.com/users/engcom-backlog-nazar/received_events","type":"User","site_admin":false},"assignees":[{"login":"engcom-backlog-nazar","id":40756439,"node_id":"MDQ6VXNlcjQwNzU2NDM5","avatar_url":"https://avatars2.githubusercontent.com/u/40756439?v=4","gravatar_id":"","url":"https://api.github.com/users/engcom-backlog-nazar","html_url":"https://github.com/engcom-backlog-nazar","followers_url":"https://api.github.com/users/engcom-backlog-nazar/followers","following_url":"https://api.github.com/users/engcom-backlog-nazar/following{/other_user}","gists_url":"https://api.github.com/users/engcom-backlog-nazar/gists{/gist_id}","starred_url":"https://api.github.com/users/engcom-backlog-nazar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/engcom-backlog-nazar/subscriptions","organizations_url":"https://api.github.com/users/engcom-backlog-nazar/orgs","repos_url":"https://api.github.com/users/engcom-backlog-nazar/repos","events_url":"https://api.github.com/users/engcom-backlog-nazar/events{/privacy}","received_events_url":"https://api.github.com/users/engcom-backlog-nazar/received_events","type":"User","site_admin":false}],"milestone":null,"comments":5,"created_at":"2018-06-19T11:37:12Z","updated_at":"2018-12-13T10:03:20Z","closed_at":"2018-11-20T07:54:31Z","author_association":"NONE","body":"###  Background\r\nWe recently updated our system from 2.1.9 to 2.2.4.\r\nA following critical error was introduced, using the built in REST API's as described here: https://devdocs.magento.com/guides/v2.2/rest/performing-searches.html\r\n\r\n### Preconditions\r\n<!---\r\n    Please provide as detailed information about your environment as possible.\r\n    For example Magento version, tag, HEAD, PHP & MySQL version, etc..\r\n-->\r\n1. Magento 2.2.4\r\n2. PHP 7.0\r\n\r\n### Steps to reproduce\r\n<!---\r\n    It is important to provide a set of clear steps to reproduce this bug.\r\n    If relevant please include code samples\r\n-->\r\n1. Query products from `/rest/V1/products?searchCriteria[filter_groups][0][filters][0][field]=name&searchCriteria[filter_groups][0][filters][0][value]=%25car%25&searchCriteria[filter_groups][0][filters][0][condition_type]=like`\r\n( Note the `%25car%25` in the query.)\r\n\r\n\r\n### Expected result\r\n<!--- Tell us what should happen -->\r\n1. Response should filter the string \"%car%\" in product name search criteria\r\n2. I.e `<value>%car%</value>`\r\n\r\n### Actual result\r\n<!--- Tell us what happens instead -->\r\n1. Instead the string \"ʲ%\" will end up being used as input.\r\n2. I.e `<value>ʲ%</value> `\r\n\r\n### Analysis\r\nIt seems that when the `UrlDecoder::decodeParams` is called in `Magento\\Webapi\\Controller\\Rest\\InputParamsResolver::106`, the string is actually already been decoded, so the decoder will end up with `rawurldecode('%car%')` witch will return an unexpected result;"},"comment":{"url":"https://api.github.com/repos/magento/magento2/issues/comments/446911017","html_url":"https://github.com/magento/magento2/issues/16237#issuecomment-446911017","issue_url":"https://api.github.com/repos/magento/magento2/issues/16237","id":446911017,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0NjkxMTAxNw==","user":{"login":"yaroslav-zenin","id":27727454,"node_id":"MDQ6VXNlcjI3NzI3NDU0","avatar_url":"https://avatars2.githubusercontent.com/u/27727454?v=4","gravatar_id":"","url":"https://api.github.com/users/yaroslav-zenin","html_url":"https://github.com/yaroslav-zenin","followers_url":"https://api.github.com/users/yaroslav-zenin/followers","following_url":"https://api.github.com/users/yaroslav-zenin/following{/other_user}","gists_url":"https://api.github.com/users/yaroslav-zenin/gists{/gist_id}","starred_url":"https://api.github.com/users/yaroslav-zenin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yaroslav-zenin/subscriptions","organizations_url":"https://api.github.com/users/yaroslav-zenin/orgs","repos_url":"https://api.github.com/users/yaroslav-zenin/repos","events_url":"https://api.github.com/users/yaroslav-zenin/events{/privacy}","received_events_url":"https://api.github.com/users/yaroslav-zenin/received_events","type":"User","site_admin":false},"created_at":"2018-12-13T10:03:20Z","updated_at":"2018-12-13T10:03:20Z","author_association":"CONTRIBUTOR","body":"Found that issue was caused by commit https://github.com/magento/magento2/commit/377668493512c25d6ba94c2fdff1a9f6a35e3530#diff-25b137703a62acb5686fb2e5ab17ec5a"}}
{"actor":{"display_login":"yaroslav-zenin"}}