In a concave mirror, the magnification is the negative ratio of image distance to the object distance.
According to Cartesian sign convention, distance from the mirror towards object are negative and that in opposite side are positive.
Hence, when the image is real(in front of the mirror) the magnification is negative and if the image is virtual(behind the mirror) the magnification is positive.