Security fix for Bin/Core/Assembler.php

Fixes for multiple security issues