<p dir="ltr">Hi Kelvin,</p>
<p dir="ltr">It's actually pretty simple to do: use a regex to get the second word, then use vmod-var to decode the token.</p>
<div class="gmail_extra"><br><div class="gmail_quote">On Oct 19, 2016 12:15, "Kelvin Loke" <<a href="mailto:kelvin1111111@gmail.com">kelvin1111111@gmail.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Good day everyday, I have a question about req.http.Authorization. As req.http.Authorization is at the format of "Basic Uk1CVTUweWMjIyMg==", do we have any variable for the base64 decoded value from req.http.Authorization?<div><br></div><div>I knew that Varnishncsa has %u for this purpose, it would be great if there is a default variable that I can use in Varnish VCL.</div><div><br></div><div>Thanks!</div></div>
<br>______________________________<wbr>_________________<br>
varnish-misc mailing list<br>
<a href="mailto:varnish-misc@varnish-cache.org">varnish-misc@varnish-cache.org</a><br>
<a href="https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc" rel="noreferrer" target="_blank">https://www.varnish-cache.org/<wbr>lists/mailman/listinfo/<wbr>varnish-misc</a><br></blockquote></div></div>