Shemiras Halashon Halachos

Hilchos Rechilus, chapter 9, section 7

The same applies to informing Shimon that Reuven stole from him or harmed him etc. Also, one may only warn Shimon if one already rebuked Reuven and he refused to listen as we wrote earlier in chapter 1 paragraph 3, see there. One must be very careful to not be lenient until one ensures all the conditions mentioned above are fulfilled for otherwise it is very likely one will transgress the Torah prohibition of rechilus.

Hilchos Rechilus, chapter 9, section 8 9

It makes no difference if Shimon asked one for the information or if one volunteers the information without him asking. All the conditions must be fulfilled even one tells the information to others [and not Shimon]. This is also rechilus as we explained in chapter 3 paragraph 3.