浏览代码

Additional CORS headers settings, added earlier. In progress.

Lauri Ojansivu 6 年之前
父节点
当前提交
d8f112278b
共有 2 个文件被更改,包括 10 次插入0 次删除
  1. 0 0
      snap-src/bin/config
  2. 10 0
      snap-src/bin/wekan-help

文件差异内容过多而无法显示
+ 0 - 0
snap-src/bin/config


+ 10 - 0
snap-src/bin/wekan-help

@@ -68,6 +68,16 @@ echo -e "\t$ snap set $SNAP_NAME cors='*'"
 echo -e "\t-Disable the CORS:"
 echo -e "\t-Disable the CORS:"
 echo -e "\t$ snap set $SNAP_NAME cors=''"
 echo -e "\t$ snap set $SNAP_NAME cors=''"
 echo -e "\n"
 echo -e "\n"
+echo -e "To enable the Set Access-Control-Allow-Headers header. \"Authorization,Content-Type\" is required for cross-origin use of the API."
+echo -e "\t$ snap set $SNAP_NAME cors-allow-headers='Authorization,Content-Type'"
+echo -e "\t-Disable the Set Access-Control-Allow-Headers header. \"Authorization,Content-Type\" is required for cross-origin use of the API."
+echo -e "\t$ snap set $SNAP_NAME cors-allow-headers=''"
+echo -e "\n"
+echo -e "To enable the Set Access-Control-Expose-Headers header.  This is not needed for typical CORS situations. Example: *"
+echo -e "\t$ snap set $SNAP_NAME cors-expose-headers='*'"
+echo -e "\t-Disable the Set Access-Control-Expose-Headers header.  This is not needed for typical CORS situations. Example: ''"
+echo -e "\t$ snap set $SNAP_NAME cors-expose-headers=''"
+echo -e "\n"
 echo -e "Enable browser policy and allow one trusted URL that can have iframe that has Wekan embedded inside."
 echo -e "Enable browser policy and allow one trusted URL that can have iframe that has Wekan embedded inside."
 echo -e "\t\t Setting this to false is not recommended, it also disables all other browser policy protections"
 echo -e "\t\t Setting this to false is not recommended, it also disables all other browser policy protections"
 echo -e "\t\t and allows all iframing etc. See wekan/server/policy.js"
 echo -e "\t\t and allows all iframing etc. See wekan/server/policy.js"

部分文件因为文件数量过多而无法显示