CDN 用戶操作
CDN User Guide
CDN User Guide
  • Domain Management
    • Add Domain
    • Batch Modify Upstream
    • Batch Remove Specific Domains
    • Export Site Records
  • Modules
    • Site Certificate
    • Token Auth
    • Custom Header
    • Redirects
    • CORS Setting
    • Proxy Rewrite
  • Site Settings
    • Cache Setting
    • Compress
    • Rates Limit
    • DNS API
    • Ports
  • Firewall
    • Whitelist Setting
    • Blacklist Setting
    • Positions Setting
    • Anti CC Setting
    • Interval Freq. Limit
    • Second Freq. Limit
    • User Agent Setting
  • ACL
  • Block List
  • Error Pages
  • Site Info.
Powered by GitBook
On this page
  1. Modules

Proxy Rewrite

PreviousCORS SettingNextSite Settings

Last updated 6 months ago

When the origin request URI does not match the source site URI, it can lead to origin fetch failures. You can configure the origin URI rewrite feature to modify the origin request URI to match the source site's URI.

How to set up origin rewrite?

  • Navigate to Sites -> Sites Settings -> Modules -> Proxy Rewrite -> Create Proxy Rewrite

  • Click Create Proxy Rewrite, and you will be prompted to enter a custom name.

Origin Rewrite Field Descriptions: After creating the configuration set as described above, add the origin rewrite rules with the following fields:

  • Priority: The priority weight for origin requests; a higher number means higher priority.

  • URI Path: Refers to the path part of the URL after the hostname (HOST) in the request, which identifies a specific resource, e.g., /images/logo.png.

  • Origin URI: When a proxy server (like a CDN) forwards a request to the backend origin, it might rewrite the URI path based on requirements. This rewritten path is called the Origin URI.

  • Origin HOST: This is the target hostname (HOST) that the proxy server sets when forwarding the request to the backend origin. It can be different from the hostname in the original request and can be rewritten to match backend configurations.

  • Origin HTTP Method: You can select HTTP methods like GET, POST, PUT, etc., for the origin request.