From the log captured via Wireshark, we found that there was no X-Timestamp in the requests sent at the very begining while X-Timestamp were found in other requests sent later, it happens only when re-open the browser. Could you please help clarify why there is no X-Timestamp in the requests sent at the very begining or is there any solution to add X-Timestamp in all the requests including the requests sent when openning the browser (without X-Timestamp)?
Code:
function modifyRequestHeaderHandler_(details) {
details.requestHeaders.push({name: "X-Timestamp", value: "xxxx-xx-xxxx"});
return {requestHeaders: details.requestHeaders};
};
//add a listener onberforesendherders
chrome.webRequest.onBeforeSendHeaders.addListener(
modifyRequestHeaderHandler_,
{urls: []},
['requestHeaders', 'blocking']
);