what you don't know can hurt you
Home Files News &[SERVICES_TAB]About Contact Add New

OLE Packager Embedding Issues

OLE Packager Embedding Issues
Posted Jul 3, 2015
Authored by Kevin Beaumont

This write up discusses the dangers around the OLE packager used to embed any file into Office documents.

tags | paper
SHA-256 | 5509a7219c971da3da4845092734860348e1252d37f58e83a5749a69db947031

OLE Packager Embedding Issues

Change Mirror Download
All,

OLE Packager is a feature introduced in Windows 3.1, which ran "up to"
Windows XP: https://en.wikipedia.org/wiki/Object_Linking_and_Embedding

It is still present in every version of Microsoft Office, on every Windows
OS.

It allows you to embed any file into Office documents. It is also very
dangerous and there is no way to disable it.

To test, open Word 2010/2013 and select Insert -> Object -> Create from
File, and drop an executable into the document. Double clicking the
executable then spawns the executable. You can also right click the file
name, to change the name and use a custom icon. You can use the Draw
functions to draw a white box over the file extension.

This isn't new (although I think most people aren't aware this function is
still active).

There's all sorts of problems, though:

- You can bypass many mail gateways and antivirus products by simply saving
the document as an .RTF file - these also support OLE Packager objects.
Most products I've tested fail to scan for Packager objects inside RTF
files, which are in turn then opened in Word by default.

- A dll file called packager.dll is used to determine if the file extension
can execute code via a static list, and displays a warning for the user to
click through. There is no way to disable the Packager functionality, so
every Enterprise/Gov/Org/user has this functionality enabled right now.

- The DLL file hasn't been kept up to date. For example, you can use .PS1
(PowerShell) embeds without any security warning. There's a lot of file
types now you can execute code with without warning, basically.

- You can also embed executable code within ZIP files, to completely bypass
the warning.

- The files are executed from your %appdata% folder, which is trusted for
things such as Windows Scripting Host. So for example, you can use
malicious .js files to execute full code, wrapped in a ZIP, with absolutely
no warning to the user nor ability to disable the functionality, even with
Group Policy/high security Office templates etc.

I've tried this technique with most of the large cloud based email
filtering companies and it just sails past them. I've also tried two
anti-exploit products (Malwarebytes Anti-Exploit and a company I won't name
due to NDA) and it doesn't trigger their protection. No antivirus product
detected anything suspect during testing.

I notified Microsoft of my research back in March, but from the dialogue
I've had it's a supported feature dating back to the early 90s. It also
appears to be supported going forward. I think it blows apart security
models and basically provides an easy way to detonate code on PCs far
behind firewalls - my belief is organisations should be able to disable
this feature, and it should probably be disabled by default in future
Office versions.

As a mitigation, you can install Microsoft EMET and manually add
packager.dll to ASR.

--Kevin


Login or Register to add favorites

File Archive:

December 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Dec 1st
    0 Files
  • 2
    Dec 2nd
    41 Files
  • 3
    Dec 3rd
    25 Files
  • 4
    Dec 4th
    0 Files
  • 5
    Dec 5th
    0 Files
  • 6
    Dec 6th
    0 Files
  • 7
    Dec 7th
    0 Files
  • 8
    Dec 8th
    0 Files
  • 9
    Dec 9th
    0 Files
  • 10
    Dec 10th
    0 Files
  • 11
    Dec 11th
    0 Files
  • 12
    Dec 12th
    0 Files
  • 13
    Dec 13th
    0 Files
  • 14
    Dec 14th
    0 Files
  • 15
    Dec 15th
    0 Files
  • 16
    Dec 16th
    0 Files
  • 17
    Dec 17th
    0 Files
  • 18
    Dec 18th
    0 Files
  • 19
    Dec 19th
    0 Files
  • 20
    Dec 20th
    0 Files
  • 21
    Dec 21st
    0 Files
  • 22
    Dec 22nd
    0 Files
  • 23
    Dec 23rd
    0 Files
  • 24
    Dec 24th
    0 Files
  • 25
    Dec 25th
    0 Files
  • 26
    Dec 26th
    0 Files
  • 27
    Dec 27th
    0 Files
  • 28
    Dec 28th
    0 Files
  • 29
    Dec 29th
    0 Files
  • 30
    Dec 30th
    0 Files
  • 31
    Dec 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2024 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close