change the streamguard cwc_emm function.