Front Door (Premium) redirect to path rule remove query string

Carlito Jamero (INFOSYS LIMITED) 20 Reputation points Microsoft Vendor
2024-09-17T02:29:12.0033333+00:00

Hi,

My use is to create a rewrite rule.

First Rule

if there's a query string replace the query string

Second rule

if there's no query string add a query string.

How can I achieve this in rule set? It seems there's no way to test if the url has no query string and second, query string is always appended in rewrite rule.

Regards,

Carlito

Azure Front Door
Azure Front Door
An Azure service that provides a cloud content delivery network with threat protection.
692 questions
{count} votes

Accepted answer
  1. KapilAnanth-MSFT 47,046 Reputation points Microsoft Employee
    2024-09-17T06:18:22.5833333+00:00

    @Carlito Jamero (INFOSYS LIMITED) ,

    I see you would like to modify and append a query string, not query path.

    Apologies on the misunderstanding,

    I believe your requirement is similar to Bob Chandra's question from : https://learn.microsoft.com/en-au/answers/questions/1667790/in-azure-front-door-premium-is-it-possible-to-just

    As I mentioned there,- Currently, URL Rewrite does support configuring the Query String

    • You have to use URL Redirect if you were to edit/modify the Query String
      • User's image
      • User's image
      • Any query string is always replaced by "sp=SASTOKEN"
    • However, this would expose the SAS Token in the browser** and has limited use case.

    This is useful if you trust the source to not abuse the SAS Token.

    In such scenarios, I would suggest you consider using AFD Private Link and block internet access to the blob.

    Should you feel that "Query String" should be included with URL Rewrite, kindly consider raising a post in Azure Feedback Hub

    All the feedback shared in these forums are monitored and reviewed by the Microsoft engineering teams responsible for building Azure

    Thanks,

    Kapil


    Please Accept an answer if correct.

    Original posters help the community find answers faster by identifying the correct answer.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.