diff --git a/headless/vk/config.go b/headless/vk/config.go index 269085f..cfeb12d 100644 --- a/headless/vk/config.go +++ b/headless/vk/config.go @@ -43,7 +43,7 @@ func fetchConfig() (VKConfig, error) { chunksBase := bundleURL[:strings.LastIndex(bundleURL, "core_spa_vk.")] + "chunks/" // Extract app_id and API version from the main bundle - if m := regexp.MustCompile(`[,;]u=(\d{7,8}),_=\d{7,8},p=\d{8,9}`).FindStringSubmatch(bundleStr); m != nil { + if m := regexp.MustCompile(`[,;]u=(\d{7,8}),[a-z]=\d{7,9}`).FindStringSubmatch(bundleStr); m != nil { cfg.AppID = m[1] } else { return cfg, fmt.Errorf("app_id not found in bundle") diff --git a/relay/pion/headless-joiner-common/vk_auth.go b/relay/pion/headless-joiner-common/vk_auth.go index 22bbc7e..525a6f9 100644 --- a/relay/pion/headless-joiner-common/vk_auth.go +++ b/relay/pion/headless-joiner-common/vk_auth.go @@ -333,7 +333,7 @@ func fetchVKConfig(httpGet func(string) ([]byte, error), logFn func(string, ...a chunksBase := bundleURL[:strings.LastIndex(bundleURL, "core_spa_vk.")] + "chunks/" cfg := &vkConfig{} - if m := regexp.MustCompile(`[,;]u=(\d{7,8}),_=\d{7,8},p=\d{8,9}`).FindStringSubmatch(bundleStr); m != nil { + if m := regexp.MustCompile(`[,;]u=(\d{7,8}),[a-z]=\d{7,9}`).FindStringSubmatch(bundleStr); m != nil { cfg.AppID = m[1] } else { return nil, fmt.Errorf("appID not found")