From 77d4ffe098dc151ab682d18d6f6d9cb045432f4a Mon Sep 17 00:00:00 2001 From: kulikov0 <19497634+kulikov0@users.noreply.github.com> Date: Thu, 7 May 2026 17:37:54 +0200 Subject: [PATCH] fix vk headless parser --- headless/vk/config.go | 2 +- relay/pion/headless-joiner-common/vk_auth.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) 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")