Cors For Upload


Cross-Origin Application Upload Allowance

During the process of secondary development, to prevent token expiration issues in the application upload interface, we have introduced a feature to allow cross-origin application upload lists. Under trusted domains, there is no need to pass verification parameters, enabling direct interface calls for application uploads.

Notes:

  1. Format: protocol://domain or IP:port, multiple cross-origin addresses separated by commas.

  2. Differentiate between the system's cross-origin access setting and the configuration for allowing cross-origin application uploads: access-control-allow-origin and upload-control-allow-origin.

  3. The system's cross-origin access setting and the configuration for allowing cross-origin application uploads will take effect simultaneously. If you only need to configure allowing cross-origin application uploads, set only upload-control-allow-origin.

Steps:

  1. Open the \larkxr-center\application.properties file, add the configuration: pxy.security.upload-control-allow-origin=http://192.168.0.55:8181

    • This will allow direct interface calls for application uploads under the domain http://192.168.0.55:8181 without the need to pass verification parameters.

Prompt:

  • If the client's access source is not from the page http://192.168.0.55:8181 or is from a different source than the interface address, application uploads will not work correctly, and a "No access permission" message will be displayed.

admin 2025年4月14日 13:34 收藏文档