收紧移动壳分享链接边界

移动壳分享链接归一到公开主站同源地址

补充协议相对链接和缓存回退拒绝测试

配置检查锁定分享链接归一策略

更新原生壳方案和共享决策记录
This commit is contained in:
2026-06-19 00:53:05 +08:00
parent bb85986d1f
commit af1e95febb
7 changed files with 168 additions and 16 deletions
+2
View File
@@ -2,6 +2,7 @@ import { describe, expect, test } from 'vitest';
import { HOST_BRIDGE_VERSION } from '../../../../packages/shared/src/contracts/hostBridge';
import {
ALLOWED_PRODUCTION_WEB_ORIGIN,
DEFAULT_MOBILE_SHELL_WEB_URL,
buildMobileShellUrl,
resolveMobileShellBaseWebUrl,
@@ -10,6 +11,7 @@ import {
describe('buildMobileShellUrl', () => {
test('默认 H5 地址指向真实主站', () => {
expect(DEFAULT_MOBILE_SHELL_WEB_URL).toBe('https://app.genarrative.world/');
expect(ALLOWED_PRODUCTION_WEB_ORIGIN).toBe('https://app.genarrative.world');
});
test('为 H5 附加原生移动壳上下文', () => {
+1 -1
View File
@@ -11,7 +11,7 @@ export type MobileShellUrlOptions = {
};
export const DEFAULT_MOBILE_SHELL_WEB_URL = 'https://app.genarrative.world/';
const ALLOWED_PRODUCTION_WEB_ORIGIN = 'https://app.genarrative.world';
export const ALLOWED_PRODUCTION_WEB_ORIGIN = 'https://app.genarrative.world';
const LOCAL_DEVELOPMENT_WEB_HOSTS = new Set([
'127.0.0.1',
'localhost',