Closed kmaher212 closed 8 years ago
Only characters contained in RFC 3986's section 2.3 unreserved characters list are allowed in the request_path
property.
Characters that are allowed in a URI but do not have a reserved purpose are called unreserved. These include uppercase and lowercase letters, decimal digits, hyphen, period, underscore, and tilde.
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
I believe it would be wrong to accept characters from the reserved list (aka URI delimiters defined in section 2.2) since they would need to be percent encoded when your consumers are making the request to Kong, which would make things confusing for them. If they would be sent not percent encoded, we would not comply to RFC 3986 in the way that request_path
is supposed to be contained in a URI section delimited by /
, which would not be the case if other delimiting characters were allowed.
Hi Charbonnier,
Can you please provide guidance regarding how we should proxy these type of requests?
https://localhost/wapi/v1.2.3/record:host?name~=abcmachine&ipv4addr~=192.168.2.2&_return_type=xml-pretty https://localhost/wapi/v1.2.3/network?network=192.168.2.0&_return_type=xml-pretty&_return_fields=network,netmask,options,extattrs
Thanks, Kathy
From: Thibault Charbonnier [mailto:notifications@github.com] Sent: Friday, November 06, 2015 11:10 PM To: Mashape/kong Cc: Maher, Kathy Subject: Re: [kong] Use of colon in request path for API creation (#692)
Only characters contained in RFC 3986https://urldefense.proofpoint.com/v2/url?u=https-3A__tools.ietf.org_html_rfc3986&d=CwMCaQ&c=gtIjdLs6LnStUpy9cTOW9w&r=gFEejS4hzs1eGwRbNnwrLKtyDc4uDMIztPDHP1LxfVE&m=aJeTMbRE3fpN06YYxeDmaYaoelI70GZhzqS2JiGG37o&s=igrPDFrFA_7cVc7e8ukgXW2zbL0ve7Qf2UTBGL39wb8&e='s section 2.3 unreserved characters list are allowed in the request_path property.
Characters that are allowed in a URI but do not have a reserved purpose are called unreserved. These include uppercase and lowercase letters, decimal digits, hyphen, period, underscore, and tilde.
unreserved = ALPHA / DIGIT / "-" / "." / "_" / "~"
I believe it would be wrong to accept characters from the reserved list (aka URI delimiters defined in section 2.2) since they would need to be percent encoded when your consumers are making the request to Kong, which would make things confusing for them. If they would be sent not percent encoded, we would not comply to RFC 3986 in the way that request_path is supposed to be contained in a URI section delimited by /, which would not be the case if other delimiting characters were allowed.
— Reply to this email directly or view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_Mashape_kong_issues_692-23issuecomment-2D154623348&d=CwMCaQ&c=gtIjdLs6LnStUpy9cTOW9w&r=gFEejS4hzs1eGwRbNnwrLKtyDc4uDMIztPDHP1LxfVE&m=aJeTMbRE3fpN06YYxeDmaYaoelI70GZhzqS2JiGG37o&s=w04HwIK8tDzhdgoavEW0CnA7qD2g_AMnXIOBdb9bovg&e=.
If you wish to route by path, your request_path
could be:
/wapi/
/wapi/v1.2.3/
/wapi/v1.2.3/network
and /wapi/v1.2.3/record
.If you wish to route by Host, (request_host
), then it depends on the domain name on which Kong is hosted.
Up to you. Please read the proxy docs.
**My name is Thibault.
Unable to specify special characters such as a colon (:) in request path i.e. path must only contain alphanumeric and '. -, _, ~' characters.