Blocked plugin files

When downloading a MIP plugin from the internet, the downloaded files are “blocked”, and the plugin fails to load with a NotSupportedException in the mip logs and the following error message:

An attempt was made to load an assembly from a network location which would have caused the assembly to be sandboxed in previous versions of the .NET Framework. This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous. If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch. See http://go.microsoft.com/fwlink/?LinkId=155569 for more information.

To fix this you can unblock .dll in the file properties:

It works, but is a bit cumbersome. Is this supposed to be the standard procedure or is there a way around this?

This is standard Windows functionality and will also happen for other non-plugin dlls. I suggest requesting the plugin developer to provide you with an installer for the plugin instead of the raw files.

I had this issue with BatAction, one of Milestone’s own plugin samples. My solution was to open the project in Visual studio. The go to Project>Properties and enable signing. Then rebuild as Release (not debug). Then I could copy the dll and pdb files from Bin into the BatchAction folder in MipPlugins and restart the event server. Then BatAction shows in my Rules and I can execute Batch files from rules.