Ported to Misp2