Score:0

How to encode url in haproxy

in flag

I am new to haproxy and I wanted to know the best way to encode the URL in haproxy.

http-request redirect code 302 location https://testservice.com/login?service=abc&redirect_uri=https://login.serivce.com?next_url=%[hdr(host)]%[capture.req.uri,regsub(&,%26,g)] unless cookie

In the above statement, I want to encode anything that comes after redirect_url,

Can someone suggest me, please?

djdomi avatar
za flag
what do you want to solve?
Mahesh G avatar
in flag
@djdomi, In the above example, I want to encode the content present after the redirect_url parameter, when the redirection happens.
djdomi avatar
za flag
its looks for me like an [X-and-Y-Problem](https://faq-database.de/doku.php?id=en:x-and-y-problem) please be more specific, what is the use case you want to have.
djdomi avatar
za flag
Does this answer your question? [HAProxy encode url for querystring](https://serverfault.com/questions/910336/haproxy-encode-url-for-querystring)
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.