#!/system/bin/sh MODDIR="${0%/*}" MODPROP="$MODDIR/module.prop" update_description() { if [ -f "$MODPROP" ]; then sed -i "s|^description=.*|description=$1|" "$MODPROP" fi } update_description "Checking Zygisk module status..." # Check if Zygisk framework is available if [ ! -d "/data/adb/modules" ]; then update_description "Error - /data/adb/modules not found" exit 1 fi # Check if our module is loaded (check for libcamera_hook.so in cameraserver) CS_PID=$(pidof cameraserver 2>/dev/null) if [ -n "$CS_PID" ] && grep -q "libcamera_hook.so" /proc/"$CS_PID"/maps 2>/dev/null; then update_description "Active - hook loaded in cameraserver PID $CS_PID" else update_description "Zygisk module loaded - waiting for cameraserver" fi