Following the email conversation with David I am raising this security issue as agreed (or some might say a feature/expected behavior)
Summary
By using the "mailto?attach=..." parameter, a website can make GNOME Gmail attach local files to an email message without showing a warning to the user, additionally when user writes an email they can't see that there is an attachment on some systems. Please see test.gif for a demonstration.
To summarize it is an analog of CVE-2020-11879 in GNOME Evolution KDE KMail (CVE-2020-11880), IBM/HCL Notes (CVE-2020-4089), and Pegasus Mail. https://twitter.com/jensvoid/status/1295357952480751616 Jens originally found this type of issue in email clients. As Jens wrote in the bugzilla report 613425 I quote: "This is arguable a dangerous feature because it allows an attacker to exfiltrate arbitrary files on disk (and also email from the victim's IMAP account), if the victim sends an email based on attacker controlled mailto input and misses the attachment being added."
How to reproduce
1) Have GNOME Gmail client installed on Ubuntu and choose GNOME GMail and Chrome as default browsers (I tested on Ubuntu 20.04 and 18.04.4 with latest stable Chrome)
2) Copy Tux.png to /tmp directory
3) Open test.html
4) Click "Send email"
5) In the GNOME Gmail fill the "To" and "Subject" fields
6) Click send
Tux.png https://en.wikipedia.org/wiki/File:Tux.pngAdditional information
On Ubuntu 18.04.4 with Chrome version 83.0.4103.116 attachment isn't shown, as you can see in demo above
On Ubuntu 20.04 with the latest stable Chrome attachment is shown
Following the email conversation with David I am raising this security issue as agreed (or some might say a feature/expected behavior)
Summary By using the "mailto?attach=..." parameter, a website can make GNOME Gmail attach local files to an email message without showing a warning to the user, additionally when user writes an email they can't see that there is an attachment on some systems. Please see test.gif for a demonstration.
To summarize it is an analog of CVE-2020-11879 in GNOME Evolution KDE KMail (CVE-2020-11880), IBM/HCL Notes (CVE-2020-4089), and Pegasus Mail. https://twitter.com/jensvoid/status/1295357952480751616 Jens originally found this type of issue in email clients. As Jens wrote in the bugzilla report 613425 I quote: "This is arguable a dangerous feature because it allows an attacker to exfiltrate arbitrary files on disk (and also email from the victim's IMAP account), if the victim sends an email based on attacker controlled mailto input and misses the attachment being added."
How to reproduce 1) Have GNOME Gmail client installed on Ubuntu and choose GNOME GMail and Chrome as default browsers (I tested on Ubuntu 20.04 and 18.04.4 with latest stable Chrome) 2) Copy Tux.png to /tmp directory 3) Open test.html 4) Click "Send email" 5) In the GNOME Gmail fill the "To" and "Subject" fields 6) Click send
Tux.png https://en.wikipedia.org/wiki/File:Tux.png Additional information On Ubuntu 18.04.4 with Chrome version 83.0.4103.116 attachment isn't shown, as you can see in demo above On Ubuntu 20.04 with the latest stable Chrome attachment is shown![latestUbuntu](https://user-images.githubusercontent.com/11824569/90698931-e5a5f400-e279-11ea-8883-0a1adbdf8911.png)