To dream of being prosecuted represents feelings of being singled out for retribution or payback. You may feel that someone is doing all they can to get back at you or make you face consequences. It may also suggest that you feel you have to work very hard to defend yourself or avoid responsibility for something.
To dream of prosecuting something else may reflect your attempt to make someone face responsibility. Trying to force someone else to take blame or repay what they did to you. Noticing every single thing someone you don’t like did so that you can get them back or set a situation straight.
Negatively, the dream may be a sign that you need to try harder to be accepting of others or resist being judgmental. You might be too harsh on yourself or others.