mirror of
https://github.com/hoppscotch/hoppscotch.git
synced 2026-04-26 01:06:00 +03:00
[GH-ISSUE #3639] [bug]: OAuth Rest Request Failing - application/x-www-form-urlencoded body cuts off request when including a colon #1256
Labels
No labels
CodeDay
a11y
browser limited
bug
bug fix
cli
core
critical
design
desktop
discussion
docker
documentation
duplicate
enterprise
feature
feature
fosshack
future
good first issue
hacktoberfest
help wanted
i18n
invalid
major
minor
need information
need testing
not applicable to hoppscotch
not reproducible
pull-request
question
refactor
resolved
sandbox
self-host
spam
stale
testmu
wip
wont fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hoppscotch#1256
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @jimifredjr on GitHub (Dec 10, 2023).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/3639
Is there an existing issue for this?
Current behavior
When I send a request to get a new oAuth token
and I'm using a application/x-www-form-urlencoded body
and I include a parameter
scopewith a value ofaccess:userthen the colon breaks the request
and I can see that the generated code bash curl only has
--data 'scope="access'and notice the first double quotation but no closing one in the scope
Steps to reproduce
Go to send an oAuth token
With a application/x-www-form-urlencoded body
and include a parameter
scopewith a value ofaccess:userAnd check the bash Generated Code
For the missing part of the parameter
Environment
Production
Version
Cloud
@ajmalmohad commented on GitHub (Dec 11, 2023):
It's the same issue as https://github.com/hoppscotch/hoppscotch/issues/3461
@jimifredjr commented on GitHub (Dec 11, 2023):
It's not exactly the same. I manually added the request variables and Hoppscotch is cutting off the variable when sending the request. I'm unable to get an oAuth Token at my workplace because of this.
@ajmalmohad commented on GitHub (Dec 11, 2023):
Yeah that's what is happening in the other issue as well, it is because you have a colon in the value. When parsing, the data is like scope: access:user. In the current version, it is split by colon and string at 1st index is taken as value. It is fixed and will be released this month i guess
@jimifredjr commented on GitHub (Dec 20, 2023):
I just tested the update and it's still failing.
Hoppscotch is adding an extra double parenthesis that is making it fail e.g.
--data 'scope="access:user enable:true"'
instead of what it should be
--data 'scope=access:user enable:true'
@sashoalm commented on GitHub (Feb 11, 2026):
@ajmalmohad, @jimifredjr - I can confirm this issue happens to me as well. I have a minimal reproducible example - when I import --data 'foo:bar=1' and export it, hoppscotch has turned it into --data 'foo=bar: 1'.
It happens on an updated version (I updated today before testing it). Screenshots (imported into hoppscottch, then exporting it from hoppscotch - it's changed, foo:bar=1 becomes foo=bar:1):