Post

Replies

Boosts

Views

Activity

Unable to use ALL cookies from webpage in my background script - [Safari App Extension]
Hi All. I am building a safari app extension which needs to make several HTTP requests from the background script. The HTTP requests need to use the Cookies that exist on my webpage. When I make the requests from my background script, I see 3 of my 4 cookies are added to the request cookie header, but the 4th cookie is not there. The 4th cookie has SameSite=Lax which seems to be the issue. When I manually change Lax to none, in my webpage's cookie storage, then the request goes through successfully from my background script. Does anyone know if there is a way to get/use cookies labeled as SameSite=Lax in my background script? I tried the broswer.cookies API, but it seems that the API will only retrieve non HttpOnly cookies, and my cookie has HttpOnly enabled as well, so this does not work. How can I make requests from my background script that need to use cookies from my webpage? P.S. This works in my chrome extension just fine, but it seems Safari has some restrictions Thanks in Advance :)
3
1
1.8k
Apr ’21