In recent factory firmwares Ubiquiti prevents any installation of third Party
firmwares by using signed firmwares. any unsigned firmware cannot be installed.
since it is not possible to downgrade this firmware to a previous version which
did not go that idiot move it is required to use a special flashing method.
simply copy flash-upgrade.bin with scp/winscp to your ubiquiti device into the /tmp directory.
login with ssh to your ubiquiti device
and execute the following lines
chmod 700 /tmp/flash-upgrade.bin
/tmp/flash-upgrade.bin

the router will now flash itself. once ths command has finished, simply powercycle your device.
future upgrades can be done with standard dd-wrt webgui. to get back to ubiquiti firmware, you have 
to use the tftp recovery method