I am only able to grab cookies with the same domain, but when you view the cookies in the chrome dev tool, you can see a bunch of cookies with different domain values under the same url tree tab on the right like below. The circled cookie is from a different domain for example but show up under developer.chrome.com.

My question is how do you pull all the cookies from that domain tab with different domain values?
chrome.cookies.getAll({'url': "http://developer.chrome.com"}, function (cookies) {
if (cookies) {
console.log(cookies); //will only pull cookies with domain value developer.chrome.com
}
});
You need to inspect the requests being made on a tab to see which are making requests for cross-domain cookies.
In order to access the network api, you need to make a DevTools extension [info].
From there you need to make the following request:
chrome.devtools.network.getHAR()
This will log json regarding the network requests being made. In that json, you can access a cookie object. The json is based on the HAR spec. [info]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With