Forgetting about setting proper permissions when pushing a custom framework can lead to some nasty problems on your Android phone as discovered by XDA forum member birgertime.
To avoid this in future, the XDA member has written a script to fix this in a flashable zip. Upon every boot, the script will scan /system/app, /system/framework and /data/app and set the proper permissions for all the files in those locations.
Note that after flashing the script, you may still be required to use adb to set the correct permissions in order for the script to work on every boot.
If you are interested in the actual script, the dev has also provided the code. For more information and to download the script, head on over to the forum thread.___________________