Description of the issue:
A recent update in Brave has caused the user agent to change based on the type of method that is used to perform a request.
When using the latest version of https://www.npmjs.com/package/axios to do a post request the user-agent header is:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.72 Safari/537.36
Now when I load an iframe (on the same website, to the same website as axios is requesting data from) the headers changes to:
user-agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 11_2_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4430.72 Safari/537.36
How can this issue be reproduced?
- Open https://codepen.io/Philo01/pen/GRrPZYe
- Open your console and switch to the network tab.
- Look for one request to github.com (iframe), this will have the Intel Mac OS X 11_2_3 agent.
- Look for one request to google.com (axios), this will have the Intel Mac OS X 10_15_7 agent.
Expected result:
Expecting both to be Intel Mac OS X 11_2_3.
Brave Version( check About Brave
):
1.23.71
Additional Information:
Worked with previous versions of Brave. I do not have this issue with Firefox or Safari.