0

Workaround for gmail error “downloading this attachment is disabled”

Workaround for gmail error “downloading this attachment is disabled”

I wanted to download an attachment that was sent to me years ago, but now gmail is blocking the download of files with attachments it doesn’t like and gives the user no way to download it. Their helpful advice was to ask the original sender to upload it to Google Drive. Not helpful if the original sender doesn’t have the file because it is a decade old.

Workaround

Gmail has your data right there, it just thinks it knows better than you. Maybe this helps protect some people. But I just want my file.

 

The first thing to do is view the original source by clicking on the three dots at the top right of the email

The click the Download Original link and open the file in a text editor. At the top of the file you will find the message header and body, and just after that you will find the attachments are encoded as text using base64 encoding. Each attachment will look like a block like this:

--bcaec554d754b0f76a04d9fda578--
--bcaec554d754b0f77204d9fda57a
Content-Type: application/pdf; name="test.zip"
Content-Disposition: attachment; filename="test.zip"
Content-Transfer-Encoding: base64
X-Attachment-Id: 123456789_0.1

d2h5IGFyZSB5b3UgdHJ5aW5nIHRvIGRlY29kZSB0aGlzPyB3aHkgYXJlIHlvdSB0cnlpbmcgdG8gZGVjb2RlIHRoaXM/d2h5IGFyZSB5b3UgdHJ5aW5nIHRvIGRlY29kZSB0aGlzP3doeSBhcmUgeW91IHRyeWluZyB0byBkZWNvZGUgdGhpcz93aHkgYXJlIHlvdSB0cnlpbmcgdG8gZGVjb2RlIHRoaXM/d2h5IGFyZSB5b3UgdHJ5aW5nIHRvIGRlY29kZSB0aGlzP3doeSBhcmUgeW91IHRyeWluZyB0byBkZWNvZGUgdGhpcz93aHkgYXJlIHlvdSB0cnlpbmcgdG8gZGVjb2RlIHRoaXM/d2h5IGFyZSB5b3UgdHJ5aW5nIHRvIGRlY29kZSB0aGlzP3doeSBhcmUgeW91IHRyeWluZyB0byBkZWNvZGUgdGhpcz93aHkgYXJlIHlvdSB0cnlpbmcgdG8gZGVjb2RlIHRoaXM/d2h5IGFyZSB5b3UgdHJ5aW5nIHRvIGRlY29kZSB0aGlzP3doeSBhcmUgeW91IHRyeWluZyB0byBkZWNvZGUgdGhpcz93aHkgYXJlIHlvdSB0cnlpbmcgdG8gZGVjb2RlIHRoaXM/d2h5IGFyZSB5b3UgdHJ5aW5nIHRvIGRlY29kZSB0aGlzP3doeSBhcmUgeW91IHRyeWluZyB0byBkZWNvZGUgdGhpcz93aHkgYXJlIHlvdSB0cnlpbmcgdG8gZGVjb2RlIHRoaXM/d2h5IGFyZSB5b3UgdHJ5aW5nIHRvIGRlY29kZSB0aGlzP3doeSBhcmUgeW91IHRyeWluZyB0byBkZWNvZGUgdGhpcz8K

--bcaec554d754b0f76a04d9fda578--

Either copy and past the content between the X-Attachment and before the end of record into a new file, or for very large attachments delete everything except the encoded attachment.

On a Mac/Unix environment you can use the base64 program to decode the attachment

 

cat encoded.txt | base64 --decode > test.zip
unzip test.zip

 

mbrandeis

Leave a Reply

Your email address will not be published. Required fields are marked *