Why am I getting a COM UnauthorizedAccessException error: 80070005 when working with MetaDefender Core from ASP?

You will see this error if you do not have the proper permissions.

You can resolve the "COM UnauthorizedAccessException" error by doing the following:

  1. Check your IIS settings:

    • In IIS, right-click on your project and choose Properties.

    • Select Directory security.

    • Click Edit on Anonymous access.

    • Make note of the username (copy the name or CTRL+C).

  2. Go to DCOM config (Start > run > dcomcnfg or Win-R > dcomcnfg).

  3. Go to My Computer > DCOM config > Metascan.

  4. Right-click and select Properties.

  5. Click the Security tab:

    • Launch and Activation: Edit, add username (paste or CTRL+V) and give all local permissions

    • Access Permissions: Edit, add username (paste or CTRL+V) and give all local permissions

    • Configuration Permission: Edit, add user and give full control

  6. Restart MetaDefender Core service.

  7. Restart IIS.

This article applies to MetaDefender Core v3
This article was last updated on 2017-12-21
OL